OSDir


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GitHub] jihoonson commented on a change in pull request #5958: Part 2 of changes for SQL Compatible Null Handling


jihoonson commented on a change in pull request #5958: Part 2 of changes for SQL Compatible Null Handling
URL: https://github.com/apache/incubator-druid/pull/5958#discussion_r201193939
 
 

 ##########
 File path: extensions-core/lookups-cached-single/src/main/java/io/druid/server/lookup/LoadingLookup.java
 ##########
 @@ -62,15 +63,19 @@ public LoadingLookup(
 
 
   @Override
-  public String apply(final String key)
+  public String apply(@Nullable final String key)
   {
-    if (key == null) {
+    String keyEquivalent = NullHandling.nullToEmptyIfNeeded(key);
 
 Review comment:
   I thought this kind of null value conversion is needed only when retrieving values from the storage layer (like in `ColumnValueSelector`), so that we expect `key` is already converted to some default value if needed. But, apparently it seems not. Would you explain why this is needed after retrieving values?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@xxxxxxxxxxxxxxxx


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: dev-help@xxxxxxxxxxxxxxxx