epugh commented on code in PR #4080:
URL: https://github.com/apache/solr/pull/4080#discussion_r2763656291
##########
solr/core/src/java/org/apache/solr/response/ResponseWritersRegistry.java:
##########
@@ -69,17 +64,68 @@ private ResponseWritersRegistry() {
* <p>Built-in writers are always available and provide essential formats
needed by admin APIs and
* core functionality. They do not depend on core configuration or
ImplicitPlugins.json settings.
*
- * <p>If the requested writer is not available, returns the "standard"
(JSON) writer as a
- * fallback. This ensures requests always get a valid response format.
+ * <p>If the requested writer is not available, returns the JSON writer as a
fallback. This
+ * ensures requests always get a valid response format.
*
* @param writerName the writer name (e.g., "json", "xml", "javabin"), or
null for default
- * @return the response writer, never null (returns "standard"/JSON if not
found)
+ * @return the response writer, never null (returns JSON if not found)
Review Comment:
Maybe would be cleaner if we had "`return
BUILTIN_WRITERS.getOrDefault(writerName,
BUILTIN_WRITERS.get(CommonParams.JSON));`
--
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]