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: strategy variant schema openapi #4232

Merged
merged 4 commits into from
Jul 13, 2023
Merged

Conversation

kwasniew
Copy link
Contributor

@kwasniew kwasniew commented Jul 13, 2023

About the changes

Introducing a new openapi concept for the strategy variant. It differs from the old variant in two ways:

  • overrides are not supported
  • ['name', 'weight', 'weightType', 'stickiness'] are required so weightType and stickiness were added.

I don't know why weightType and stickiness were not required for the old variants but it makes types align with the application services (tested in a separate POC).

Added WIP in description so that people don't have expectations that it's already implemented.

Create and read variant differ by additionalProperties requirement.

Important files

Discussion points

@sonatype-lift
Copy link

sonatype-lift bot commented Jul 13, 2023

Sonatype Lift is retiring

Sonatype 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.
We are extremely grateful and thank you for your support over the years.

📖 Read about the impacts and timeline

@vercel
Copy link

vercel bot commented Jul 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 13, 2023 11:37am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
unleash-docs ⬜️ Ignored (Inspect) Jul 13, 2023 11:37am

Copy link
Contributor

@thomasheartman thomasheartman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is very nice! 💯 I've got a few minor suggestions but no real blockers. What's interesting here, though, is how we add this to the schema. I know you added the [WIP] annotation at the start of every description for these schemas. I don't think there is an unstable property for schemas, so it might be the best we have for now. But maybe we could make it more explicit in case you don't understand what WIP means. Maybe something like: This is an experimental property. It may change or be removed as we work on it. Please don't depend on it yet. or something like that? What do you think?

src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/create-strategy-variant-schema.ts Outdated Show resolved Hide resolved
src/lib/openapi/spec/strategy-variant-schema.ts Outdated Show resolved Hide resolved
Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
Copy link
Contributor

@sjaanus sjaanus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG

@kwasniew kwasniew merged commit ce87806 into main Jul 13, 2023
16 checks passed
@kwasniew kwasniew deleted the strategy-variant-schema-openapi branch July 13, 2023 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

3 participants