xiangfu0 commented on code in PR #12763:
URL: https://github.com/apache/pinot/pull/12763#discussion_r1609756632


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/defaultcolumn/BaseDefaultColumnHandler.java:
##########
@@ -582,20 +582,39 @@ private void createDerivedColumnV1Indices(String column, 
FunctionEvaluator funct
       int numDocs = _segmentMetadata.getTotalDocs();
       Object[] outputValues = new Object[numDocs];
       PinotDataType outputValueType = null;
+      int loggedErrorCount = 0;
+      long lastLoggedTime = System.currentTimeMillis();
+
+      FieldSpec fieldSpec = _schema.getFieldSpecFor(column);
+      Object defaultNullValue = fieldSpec.getDefaultNullValue();
       for (int i = 0; i < numDocs; i++) {
         for (int j = 0; j < numArguments; j++) {
           inputValues[j] = valueReaders.get(j).getValue(i);
         }
-        Object outputValue = functionEvaluator.evaluate(inputValues);
-        outputValues[i] = outputValue;
+        try {
+          Object outputValue = functionEvaluator.evaluate(inputValues);
+          outputValues[i] = outputValue;
+        } catch (Exception e) {
+          if (!errorOnFailure) {
+            // Try to not flush the logger, sample every 1000 errors or 10 
seconds

Review Comment:
   done.



-- 
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-unsubscr...@pinot.apache.org

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

Reply via email to