LakshSingla commented on code in PR #16572:
URL: https://github.com/apache/druid/pull/16572#discussion_r1647501428


##########
extensions-core/multi-stage-query/src/main/java/org/apache/druid/msq/querykit/results/ExportResultsFrameProcessor.java:
##########
@@ -167,9 +175,23 @@ private void exportFrame(final Frame frame)
               for (int j = 0; j < exportRowSignature.size(); j++) {
                 String columnName = exportRowSignature.getColumnName(j);
                 BaseObjectColumnValueSelector<?> selector = 
selectors.get(outputColumnNameToFrameColumnNumberMap.getInt(columnName));
-                exportWriter.writeRowField(columnName, selector.getObject());
+                if (resultsContext == null) {
+                  throw 
DruidException.forPersona(DruidException.Persona.OPERATOR)
+                                      
.ofCategory(DruidException.Category.RUNTIME_FAILURE)
+                                      .build("Received null resultsContext 
from controller. This might be due to an upgrade.");

Review Comment:
   We should add a remedy for the user in this case, something like - please 
ensure the controller and the worker are on the same version before retrying 
the query
   ```suggestion
                                         .build("Received null resultsContext 
from the controller. This is due to a version mismatch between the controller 
and the worker. Please ensure that the worker and the controller are on the 
same version before retrying the query.");
   ```



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

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@druid.apache.org
For additional commands, e-mail: commits-h...@druid.apache.org

Reply via email to