public static String toTimeAsString(final long timeMilli) {
        if (timeMilli < 1) {
            return "0ms";
        }
        final StringBuilder stringBuilder = new StringBuilder();
        scanTimeUnits(timeMilli, stringBuilder);

        return stringBuilder.toString();
    }
@Test
    public void testToTimeAsString() {
        assertEquals("600ms", ConnectorConfigGeneratorUtils.toTimeAsString(TimeUtils.toMilliSeconds("600ms")));
        assertEquals("0ms", ConnectorConfigGeneratorUtils.toTimeAsString(TimeUtils.toMilliSeconds("0ms")));
        assertEquals("1s", ConnectorConfigGeneratorUtils.toTimeAsString(TimeUtils.toMilliSeconds("1000ms")));
        assertEquals("1m600ms", ConnectorConfigGeneratorUtils.toTimeAsString(TimeUtils.toMilliSeconds("1m600ms")));
        assertEquals("1m1s100ms", ConnectorConfigGeneratorUtils.toTimeAsString(TimeUtils.toMilliSeconds("1m1100ms")));
        assertEquals("5m10s300ms", ConnectorConfigGeneratorUtils.toTimeAsString(310300));
        assertEquals("5s500ms", ConnectorConfigGeneratorUtils.toTimeAsString(5500));
        assertEquals("1h50m", ConnectorConfigGeneratorUtils.toTimeAsString(6600000));
        assertEquals("2d3h4m", ConnectorConfigGeneratorUtils.toTimeAsString(Duration.parse("P2DT3H4M").toMillis()));
        assertEquals("2d4m", ConnectorConfigGeneratorUtils.toTimeAsString(Duration.parse("P2DT4M").toMillis()));
    }