codelipenghui commented on a change in pull request #13831:
URL: https://github.com/apache/pulsar/pull/13831#discussion_r789520575
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/NamespacesBase.java
##########
@@ -2382,6 +2382,9 @@ protected void
internalSetSchemaValidationEnforced(boolean schemaValidationEnfor
protected boolean internalGetIsAllowAutoUpdateSchema() {
validateNamespacePolicyOperation(namespaceName,
PolicyName.SCHEMA_COMPATIBILITY_STRATEGY,
PolicyOperation.READ);
+ if (getNamespacePolicies(namespaceName).is_allow_auto_update_schema ==
null) {
+ return pulsar().getConfig().isAllowAutoUpdateSchemaEnabled();
+ }
Review comment:
Hmmm, yes. No good choice here. In principle, we should not return the
broker-level configuration. I think we can correct the API in v3 REST API to
make sure returns null if the namespace level doesn't have the
`AllowAutoUpdateSchema`.
--
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]