Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(p/rbac): RBAC Pacakge Implementation #506

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

feat(p/rbac): RBAC Pacakge Implementation #506

wants to merge 2 commits into from

Conversation

notJoon
Copy link
Member

@notJoon notJoon commented Feb 6, 2025

Description

Implemented the RBAC package, but need to discussion whether it should be located in p or r.

paritally related with #496

@notJoon notJoon requested a review from onlyhyde February 6, 2025 07:46
@notJoon notJoon self-assigned this Feb 6, 2025
@notJoon notJoon requested a review from mconcat February 6, 2025 07:46
Copy link

sonarqubecloud bot commented Feb 6, 2025

@onlyhyde
Copy link
Member

onlyhyde commented Feb 6, 2025

If you organize RBAC as a package, there is no ledger to manage roles and addresses for roles. How do you think it will be used?

@notJoon
Copy link
Member Author

notJoon commented Feb 6, 2025

If you organize RBAC as a package, there is no ledger to manage roles and addresses for roles. How do you think it will be used?

I considered a structure where p contains only pure implementations, while r contains global variable declarations.

For example:

package xxx

import (
    "gno.land/p/demo/rbac"
)

var Manager = rbac.New()

// ...

If we move the package to the r side, I just need to add the code above directly to the rbac package.

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