You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "klsince (via GitHub)" <gi...@apache.org> on 2024/02/29 19:14:00 UTC

Re: [PR] Adding record reader config/context param to record transformer [pinot]

klsince commented on code in PR #12520:
URL: https://github.com/apache/pinot/pull/12520#discussion_r1508078762


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/recordtransformer/RecordTransformer.java:
##########
@@ -43,4 +44,15 @@ default boolean isNoOp() {
    */
   @Nullable
   GenericRow transform(GenericRow record);
+
+  /**
+   * Transforms a record based on some custom rules using record reader context.
+   * @param record Record to transform
+   * @return Transformed record, or {@code null} if the record does not follow certain rules.
+   */
+  @Nullable
+  default GenericRow transformUsingRecordReaderContext(GenericRow record,

Review Comment:
   just call it `transform(record, config)`, as it's easy to tell them apart by param list.
   
   I'd suggest to pass in RecordReaderConfig (the interface), and make RecordReaderFileConfig implement RecordReaderConfig (which is an empty interface right now)



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org