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: add ownership to Task #15453

Open
3 tasks
flaneur2020 opened this issue May 9, 2024 · 1 comment · May be fixed by #15458
Open
3 tasks

feat: add ownership to Task #15453

flaneur2020 opened this issue May 9, 2024 · 1 comment · May be fixed by #15458

Comments

@flaneur2020
Copy link
Member

flaneur2020 commented May 9, 2024

Summary

to query the task histories, we need ask cloudcontrol rpc service.

there're two possible ways:

  1. maintain the ownership in the cloudcontrol rpc service while the ownership get changed

    whenever GRANT OWNERSHIP to another role in databend, we can also tell the change about task ownership cloudcontrol rpc service by a seperated rpc call likes alter_task_ownership() or alter_task().

    thus we can query the task history by passing the current effective roles on the rpc get_task_histories.

  2. not maintain the ownership in the cloudcontrol service

    on querying the task histories, databend-query can get ALL the task ids by its own metadata storage about ownerships, then it can pass a task_ids to get_task_histories to filter out the needed task histories.

@flaneur2020
Copy link
Member Author

in my personal view, i'd prefer the 1st approach above.

it has redundant storage about the ownership info, but sometimes redundant metadata may help different services to get the whole picture about the state.

@TCeason TCeason linked a pull request May 10, 2024 that will close this issue
11 tasks
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 a pull request may close this issue.

1 participant