Jackie-Jiang commented on a change in pull request #6046: URL: https://github.com/apache/incubator-pinot/pull/6046#discussion_r496431862
########## File path: pinot-spi/src/main/java/org/apache/pinot/spi/data/readers/RecordExtractor.java ########## @@ -46,4 +48,16 @@ * @return The output GenericRow */ GenericRow extract(T from, GenericRow to); + + /** + * Converts a field of the given input record. The field value will be converted to either a single value + * (string, number, bytebuffer), multi value (Object[]) or a Map. + * + * Natively Pinot only understands single values and multi values. + * Map is useful only if some ingestion transform functions operates on it in the transformation layer. + * + * @param value the field value to be converted + * @return The converted field value + */ + Object convert(@Nullable V value); Review comment: I prefer handling `null` explicitly before calling the method for readability and slightly better performance (save a method call), while this is personal preference so either way is fine ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org