[
https://issues.apache.org/jira/browse/SOLR-18072?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Houston Putman resolved SOLR-18072.
-----------------------------------
Fix Version/s: 10.1
Assignee: Houston Putman
Resolution: Done
> Refactor CollectionApiCommands to be able to easily pass in more context
> ------------------------------------------------------------------------
>
> Key: SOLR-18072
> URL: https://issues.apache.org/jira/browse/SOLR-18072
> Project: Solr
> Issue Type: Improvement
> Reporter: Houston Putman
> Assignee: Houston Putman
> Priority: Major
> Labels: pull-request-available
> Fix For: 10.1
>
> Time Spent: 5h 20m
> Remaining Estimate: 0h
>
> Currently the method signature for these classes is:
> {{public void call(ClusterState state, ZkNodeProps message, NamedList<Object>
> results)}}
> There's not a lot of additional information that can be passed through. It
> would be great to eventually have these calls be typed instead of having
> generic ZkNodeProps messages (and when we move to exclusively use the v2 API
> this should be pretty easy to do). But in the meantime, trying to add
> information being sent to these commands is very hard because every single
> command needs to be updated.
> Instead if we pass in an {{AdminCmdContext}} that contains information
> relevant to the command request, then we can easily expand it in the future
> without having to refactor everything.
> {{public void call(AdminCmdContext context, ZkNodeProps message,
> NamedList<Object> results)}}
> In the first pass, the context would include things like {{operation}} and
> {{asyncId}} that are currently included in the ZkNodeProps, but are generic
> so can be formalized in the context class. It will also include the
> ClusterState, since that is what it is replacing in the method signature.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]