[ 
https://issues.apache.org/jira/browse/SOLR-18512?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18125591#comment-18125591
 ] 

ASF subversion and git services commented on SOLR-18512:
--------------------------------------------------------

Commit eb1b0cb7a7552a810c9e0db8318e0e83bf23cb24 in solr's branch 
refs/heads/branch_10x from Serhiy Bzhezytskyy
[ https://gitbox.apache.org/repos/asf?p=solr.git;h=eb1b0cb7a75 ]

SOLR-18512: Port ConfigTool to picocli (#5039)

Co-authored-by: Jan Høydahl <[email protected]>
(cherry picked from commit adbbb8f49a1b612638af886ecd3e9dbcf93fee7e)


> Port ConfigTool to PicoCli
> --------------------------
>
>                 Key: SOLR-18512
>                 URL: https://issues.apache.org/jira/browse/SOLR-18512
>             Project: Solr
>          Issue Type: Improvement
>          Components: cli
>            Reporter: Jan Høydahl
>            Priority: Major
>              Labels: newdev, pull-request-available
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> Port {{ConfigTool}} to picocli, adding the picocli code path alongside the 
> existing commons-cli one.
> *Covers:* {{bin/solr config}}
> The command invokes the Config API against the collection named by {{\-c}} / 
> {{\-\-name}}, with {{\-\-action}} selecting one of {{set-property}}, 
> {{unset-property}}, {{set-user-property}} or {{unset-user-property}} (default 
> {{set-property}}), and {{\-\-property}} / {{\-\-value}} carrying the payload. 
> There are no sub-commands.
> Consider modelling {{\-\-action}} as a picocli enum so the valid values are 
> validated and documented by the framework rather than by hand.
> *Acceptance criteria*
> * {{bin/solr config}} and all its options work with {{SOLR_PICOCLI=true}}, 
> and the commons-cli path is left behaviourally unchanged.
> * {{ConfigTool}} is registered in {{SolrCLI}}'s picocli {{subcommands}} list 
> and {{ToolBase.callTool()}} is implemented, replacing the 
> {{UnsupportedOperationException}} stub.
> * Shared options reuse the existing mixins ({{ConnectionOptions}}, 
> {{CredentialsOptions}}, {{HelpMixin}}) rather than redeclaring them.
> * An {{ConfigToolPicocliTest}} subclasses the existing test and overrides 
> only the {{runTool}} hook, so the inherited assertions run through both 
> parsers.
> * {{./gradlew :solr:solr-ref-guide:generateCliDocs}} is re-run and the 
> generated {{cli/solr-config.adoc}} page is committed, so 
> {{checkCliDocsUpToDate}} passes.
> *AI assistance:* a coding-agent prompt template encoding the patterns already 
> established by the ported tools is available at 
> [https://gist.github.com/janhoy/a3fe0dbcaadf24b3493558946cc549d9] — name 
> {{ConfigTool}} in its Assignment line up front and the rest of the prompt 
> adapts. Please review agent output as carefully as hand-written code.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to