public static long parseTimestamp(String value)
    {
        try {
            return parseLong(value);
        }
        catch (NumberFormatException e) {
            // Sometimes Pinot returns float point string in a field that we expect timestamp.
            // This can happen because of JsonParser, Pinot Query Engine, etc.
            // In this case we may still go through by reading a float value
            try {
                return parseDouble(value).longValue();
            }
            catch (Exception ignoredEx) {
                return TimestampUtils.toMillisSinceEpoch(value);
            }
        }
    }
@Test(expectedExceptions = IllegalArgumentException.class)
    public void testParseTimestampWithException()
    {
        parseTimestamp("some string");
        fail("Should throw exception for parsing wrong timestamp");
    }