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

[Improvement] [AUTHZ] Spec json files should be auto generated, rather than edit manually #4715

Closed
3 of 4 tasks
packyan opened this issue Apr 16, 2023 · 1 comment
Closed
3 of 4 tasks

Comments

@packyan
Copy link
Contributor

packyan commented Apr 16, 2023

Code of Conduct

Search before asking

  • I have searched in the issues and found no similar issues.

What would you like to be improved?

In #4658, this pr edit the table_command_spec.json, but this file should be generated by JsonSpecFileGenerator.scala, rather than edited this file manually.

The json automatically created using this PR is inconsistent with the manually modified json, which will cause trouble for developers on other branches

We should first fix this bug, and than every build use JsonSpecFileGenerator generated spec json, rather than those in resource dir.

How should we improve?

No response

Are you willing to submit PR?

  • Yes. I would be willing to submit a PR with guidance from the Kyuubi community to improve.
  • No. I cannot submit a PR at this time.
@bowenliang123
Copy link
Contributor

Hi the spec json file should not be regenerated in each build. It's done by design.
The Authz plugin should only depends on the generated spec json file in runtime, so the committed spec json file should be static, packaged in plugin, checked in CI builds.

So it's good to enforce checks on generated spec json file, but not to regenerate them in builds.

bowenliang123 pushed a commit that referenced this issue Apr 20, 2023
### _Why are the changes needed?_

to close #4715

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.readthedocs.io/en/master/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #4717 from packyan/imporve_authz_spec_json_should_be_generated_in_each_build.

Closes #4717

88e70da [Deng An] Update JsonSpecFileGenerator.scala
d195a6d [Deng An] Merge branch 'master' into imporve_authz_spec_json_should_be_generated_in_each_build
a078c8c [packyan] add ut for check or generate spec json files.

Lead-authored-by: packyan <packyande@gmail.com>
Co-authored-by: Deng An <36296995+packyan@users.noreply.github.com>
Co-authored-by: Deng An <packy@Dengs-MBP.lan>
Signed-off-by: liangbowen <liangbowen@gf.com.cn>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants