You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2022/09/07 18:53:42 UTC

[GitHub] [druid] clintropolis commented on a diff in pull request #13022: Avoid ClassCastException when getting values from `QueryContext`

clintropolis commented on code in PR #13022:
URL: https://github.com/apache/druid/pull/13022#discussion_r965172651


##########
processing/src/main/java/org/apache/druid/query/Query.java:
##########
@@ -124,22 +124,130 @@ default QueryContext getQueryContext()
     return null;
   }
 
-  <ContextType> ContextType getContextValue(String key);

Review Comment:
   hmm, actually I guess this is an `@ExtensionPoint`, we should probably leave the old methods here to not be backwards incompatible



##########
processing/src/main/java/org/apache/druid/query/QueryContexts.java:
##########
@@ -604,18 +644,31 @@ private QueryContexts()
   {
   }
 
-  static <T, E extends Enum<E>> E parseEnum(Query<T> query, String key, Class<E> clazz, E defaultValue)

Review Comment:
   this class is also marked `@PublicApi` and so we should ideally leave the signatures in place



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

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


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