Skip to content

[ISSUE #10498] Update ACL documentation to include required 5.x properties#10499

Open
SummCoder wants to merge 1 commit into
apache:developfrom
SummCoder:doc-update-acl-5x-config
Open

[ISSUE #10498] Update ACL documentation to include required 5.x properties#10499
SummCoder wants to merge 1 commit into
apache:developfrom
SummCoder:doc-update-acl-5x-config

Conversation

@SummCoder

Copy link
Copy Markdown
Contributor

Which Issue(s) This PR Fixes

Fixes #10498

Brief Description

The current ACL documentation (both English and Chinese) only lists
aclEnable=true as the required broker property. In RocketMQ 5.x,
this is insufficient — the new authentication/authorization framework
introduced in 5.x requires five additional properties to function.

Code evidence for each property:

Property Source Effect when omitted
authenticationEnabled AbstractAuthenticationStrategy.java:54 Authentication is skipped entirely
authorizationEnabled AbstractAuthorizationStrategy.java:54 Authorization is skipped entirely
migrateAuthFromV1Enabled AuthMigrator.java:72 plain_acl.yml is not loaded
authenticationMetadataProvider AuthenticationFactory.java:80-81 Returns null → "authenticationMetadataProvider is not configured"
authorizationMetadataProvider AuthorizationFactory (same pattern) Same as above for authorization

Without these, users experience either:

  • ACL silently allowing all traffic (authentication/authorization skipped), or
  • "authenticationMetadataProvider is not configured" error on startup

How Did You Test This Change?

  1. Built the project with mvn -Prelease-all -DskipTests clean install -U
  2. Deployed a fresh RocketMQ 5.5.0 broker with the complete property set
  3. Verified ACL authentication works: valid credentials accepted,
    invalid credentials correctly rejected with "User not found"
  4. Verified mqadmin commands work with default tools.yml credentials
    matching the ACL account
  5. Confirmed omission of any single property causes the documented
    failure mode (silent bypass or configuration error)

In RocketMQ 5.x, enabling ACL requires more than just 'aclEnable=true'.
The following properties are also required:
- authenticationEnabled
- authorizationEnabled
- migrateAuthFromV1Enabled
- authenticationMetadataProvider
- authorizationMetadataProvider

Without these, ACL either silently allows all traffic or throws
'authenticationMetadataProvider is not configured'.

@RockteMQ-AI RockteMQ-AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review by github-manager-bot

Summary

Updates ACL documentation to include required 5.x properties (admin, default.group.perm, etc.) that are mandatory in RocketMQ 5.x but were missing from the docs.

LGTM. Important documentation gap filled — users deploying ACL on 5.x need these properties. 👍


Automated review by github-manager-bot

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 48.05%. Comparing base (91cb333) to head (f41e0cc).
⚠️ Report is 5 commits behind head on develop.

Additional details and impacted files
@@              Coverage Diff              @@
##             develop   #10499      +/-   ##
=============================================
- Coverage      48.13%   48.05%   -0.08%     
+ Complexity     13355    13330      -25     
=============================================
  Files           1377     1377              
  Lines         100707   100707              
  Branches       13010    13010              
=============================================
- Hits           48477    48399      -78     
- Misses         46296    46365      +69     
- Partials        5934     5943       +9     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SummCoder SummCoder changed the title [Doc] Update ACL documentation to include required 5.x properties [ISSUE #10498] Update ACL documentation to include required 5.x properties Jun 15, 2026

@majialoong majialoong left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch! I left a few comments.

Comment thread docs/cn/acl/user_guide.md
## RocketMQ 5.x 需要额外配置以下ACL属性
authenticationEnabled=true
authorizationEnabled=true
migrateAuthFromV1Enabled=true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think migrateAuthFromV1Enabled is not necessary here, since it is only required when migrating from ACL v1 to ACL v2.

Comment thread docs/cn/acl/user_guide.md
migrateAuthFromV1Enabled=true
authenticationMetadataProvider=org.apache.rocketmq.auth.authentication.provider.LocalAuthenticationMetadataProvider
authorizationMetadataProvider=org.apache.rocketmq.auth.authorization.provider.LocalAuthorizationMetadataProvider
listenPort=10911

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we should also add the default authentication and authorization providers here for completeness:

authenticationProvider=org.apache.rocketmq.auth.authentication.provider.DefaultAuthenticationProvider
authorizationProvider=org.apache.rocketmq.auth.authorization.provider.DefaultAuthorizationProvider

## RocketMQ 5.x requires the following additional ACL properties
authenticationEnabled=true
authorizationEnabled=true
migrateAuthFromV1Enabled=true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Doc] ACL documentation is missing required 5.x configuration properties

5 participants