abhishekrb19 commented on code in PR #18329:
URL: https://github.com/apache/druid/pull/18329#discussion_r2298554612
##########
processing/src/main/java/org/apache/druid/query/QueryContexts.java:
##########
@@ -137,6 +137,9 @@ public class QueryContexts
public static final String NATIVE_QUERY_SQL_PLANNING_MODE_COUPLED =
"COUPLED";
public static final String NATIVE_QUERY_SQL_PLANNING_MODE_DECOUPLED =
"DECOUPLED";
+ public static final String REALTIME_SEGMENTS_ONLY = "realtimeSegmentsOnly";
Review Comment:
On the naming, what do you think of something like `queryRealtimeDataOnly`?
##########
server/src/main/java/org/apache/druid/client/CachingClusteredClient.java:
##########
@@ -473,6 +473,9 @@ private Set<SegmentServerSelector> computeSegmentsToQuery(
}
for (PartitionChunk<ServerSelector> chunk : filteredChunks) {
ServerSelector server = chunk.getObject();
+ if (query.context().isRealtimeSegmentsOnly() &&
!server.isRealtimeSegment()) {
Review Comment:
Evaluate and assign `query.context().isRealtimeSegmentsOnly()` once outside
the for loops for reuse
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]