Skip to content

[chore](auth) Fix mislabeled log strings and remove debug main in authorization plugin path#65739

Open
arpitjain099 wants to merge 1 commit into
apache:masterfrom
arpitjain099:chore/authz-plugin-cleanup
Open

[chore](auth) Fix mislabeled log strings and remove debug main in authorization plugin path#65739
arpitjain099 wants to merge 1 commit into
apache:masterfrom
arpitjain099:chore/authz-plugin-cleanup

Conversation

@arpitjain099

Copy link
Copy Markdown
Contributor

What problem does this PR solve?

Small tidy-ups I noticed while reading through the authorization plugin path (AccessControllerManager and the Ranger controller) for the OpenFGA work.

Two things:

  • In AccessControllerManager.loadAccessControllerPlugins() the two log/exception strings for the classpath loader say "Authentication Plugin Factories", but this method loads AccessControllerFactory instances (authorization). The directory loader a few lines down already logs "Access Controller Plugin Factory", so this just makes the classpath branch consistent and stops the messages from pointing a reader at the wrong subsystem. The class javadoc also called the manager the entry point of "privilege authentication"; corrected to "authorization".
  • RangerDorisAccessController still carries a leftover public static void main marked "For test only" that constructs a controller and prints to stdout. It is dead code (nothing references it, and it is not a real test) so I removed it.

No behavior change, log wording and a dead method only.

Release note

None

Check List (For Author)

  • Test

    • No need to test or manual test. Explain why:
      • This is a refactor/code format and no logic has been changed.
  • Behavior changed:

    • No.
  • Does this need documentation?

    • No.

I'll keep looking at where I can help Doris support different authentication and authorization systems as I go.

…horization plugin path

Signed-off-by: Arpit Jain <arpitjain099@gmail.com>
@hello-stephen

Copy link
Copy Markdown
Contributor

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

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.

2 participants