paul-rogers commented on PR #13022:
URL: https://github.com/apache/druid/pull/13022#issuecomment-1242733933
Here's a follow-on idea. Modifying a context map can perhaps be left to
working directly with the map, since it is mostly just calling `put()` along
with a few other items. So, perhaps we can just focus on reading the context.
Maybe we define:
```java
interface Query<...> {
default QueryContext getQueryContext() { return new
QueryContext(getContext()); }
```
Then, `QueryContext` has all the many accessor methods mentioned above. That
is, `QueryContext` is a transient facade on top of the map.
With this approach, all the myriad `getFoo` and `parseFoo` method in
`QueryContexts` can move to `QueryContext`.
What do you think? If this will work, I can perhaps modify the PR I
mentioned to include this approach.
--
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]