-
-
Notifications
You must be signed in to change notification settings - Fork 658
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
Group schema updates #4258
Group schema updates #4258
Conversation
Sonatype Lift is retiringSonatype Lift will be retiring on Sep 12, 2023, with its analysis stopping on Aug 12, 2023. We understand that this news may come as a disappointment, and Sonatype is committed to helping you transition off it seamlessly. If you’d like to retain your data, please export your issues from the web console. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good! Got a few small suggestions, but nothing preventing this from going in 💯
@@ -7,49 +7,67 @@ export const groupSchema = { | |||
type: 'object', | |||
additionalProperties: true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a response schema, right? In that case, this should be false
additionalProperties: true, | |
additionalProperties: false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one is shared for request and response schema. Once I get to the create schemas I may split those two. But for now I only wanted to add examples/descriptions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it. That's fine, but we should definitely split them in a follow-up, then. The ID property probably does nothing when you create it, for instance.
type: 'number', | ||
description: 'The group id', | ||
type: 'integer', | ||
example: 1, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not blocking and not really important on response schemas, but what's the minimum ID we use? We could indicate that here 💁🏼
example: 1, | |
example: 1, | |
minimum: 1, // or 0? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In my DB it's 1 but it's a DB implementation detail so not sure if it adds much value
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, and because it's not something you can set yourself, it doesn't matter much. I'd set it to 0
so that people can used unsigned integers if they want to, but I'll leave it up to you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually 0 should never occur because postgres starts counting from 1 at least on my machine. But I don't want to make too many assumptions here
Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
About the changes
OpenAPI schemas for group, groups and group user
Important files
Discussion points