You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by "cryptoe (via GitHub)" <gi...@apache.org> on 2024/02/01 16:08:54 UTC
Re: [PR] Addressing shapeshifting issues with window functions (druid)
cryptoe commented on code in PR #15807:
URL: https://github.com/apache/druid/pull/15807#discussion_r1474718123
##########
processing/src/main/java/org/apache/druid/frame/segment/FrameSegment.java:
##########
@@ -77,4 +80,15 @@ public void close()
{
// Nothing to close.
}
+
+ @SuppressWarnings("unchecked")
+ @Nullable
+ @Override
+ public <T> T as(@Nonnull Class<T> clazz)
+ {
+ if (CloseableShapeshifter.class.equals(clazz)) {
Review Comment:
This code is breaking a code path where default method is called with StorageAdaptor.class
```
default <T> T as(@Nonnull Class<T> clazz)
{
if (clazz.equals(QueryableIndex.class)) {
return (T) asQueryableIndex();
} else if (clazz.equals(StorageAdapter.class)) {
return (T) asStorageAdapter();
}
return null;
}
}
```
Is that okay ?
--
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