gerlowskija commented on code in PR #4178:
URL: https://github.com/apache/solr/pull/4178#discussion_r3880803499
##########
solr/core/src/java/org/apache/solr/packagemanager/PackageManager.java:
##########
@@ -152,20 +150,9 @@ public void uninstall(String packageName, String version)
// Delete the package by calling the Package API and remove the Jar
printGreen("Executing Package API to remove this package...");
- PackagePayload.DelVersion del = new PackagePayload.DelVersion();
- del.version = version;
- del.pkg = packageName;
-
- V2Request req =
- new V2Request.Builder(PackageUtils.PACKAGE_PATH)
- .forceV2(true)
- .withMethod(SolrRequest.METHOD.POST)
- .withPayload(Collections.singletonMap("delete", del))
- .build();
-
try {
- V2Response resp = req.process(solrClient);
- printGreen("Response: " + resp.jsonStr());
+ new PackageApi.DeletePackageVersion(packageName,
version).process(solrClient);
+ printGreen("Package version deleted from Package API.");
Review Comment:
There's still a `printGreen` call, but the data that gets printed out is
different. The new message doesn't include any details from the response at
all. If an error response still triggers a stacktrace in the CLI, maybe that's
sufficient and there's no actual loss in the data conveyed. But just wanted to
double-check we weren't losing anything here 🤷
If you're confident there's no information-loss, that works for me.
--
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]