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 domain as an openfeature concept #229

Merged
merged 8 commits into from
Jan 24, 2024
Merged

Conversation

beeme1mr
Copy link
Member

@beeme1mr beeme1mr commented Jan 10, 2024

This PR

  • defines domain as a concept
  • updates references to client name to use domain
  • add domain as client metadata

Related Issues

Fixes #228

Follow-up Tasks

  • Update the readme template
  • Update the openfeature.dev SDK compatibility table

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
specification/glossary.md Outdated Show resolved Hide resolved
specification/sections/01-flag-evaluation.md Outdated Show resolved Hide resolved
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
@dabeeeenster
Copy link
Contributor

Would this allow for multiple clients across multiple (or the same) provider?

@beeme1mr
Copy link
Member Author

Would this allow for multiple clients across multiple (or the same) provider?

Yes, exactly. The functionality already exists in many SDKs.

@toddbaert
Copy link
Member

Would this allow for multiple clients across multiple (or the same) provider?

Yes, exactly. The functionality already exists in many SDKs.

Ya, it exists but is (IMHO) confusingly named, so I like this change.

@federicobond
Copy link
Member

I agree with the motivation, the current wording around named clients is a bit awkward. I don't think the word namespace makes things clear though. A namespace usually denotes a logical grouping of identifiers or symbols.

I propose we survey some examples of APIs solving similar problems to get a better idea of the alternatives.

As a first data point, the Python logging library uses "name" for the parameter to logging.getLogger which returns a logger with a specific configuration defined somewhere else.

@beeme1mr
Copy link
Member Author

@federicobond I thought namespace would be a good fit because it's a logical grouping of clients to a provider. However, I would happily change the proposal if we can find a more appropriate term.

@beeme1mr
Copy link
Member Author

Thanks for the feedback everyone. I've updated the PR to use the term domain. Please take a look when you have a moment.

Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
@beeme1mr
Copy link
Member Author

Thanks for the great reviews and feedback. I'll merge this on Wednesday the 24th unless there's an objection.

Copy link

@dominikhaska dominikhaska left a comment

Choose a reason for hiding this comment

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

Looks good - thank you :)

@beeme1mr beeme1mr merged commit afe1c7e into main Jan 24, 2024
6 checks passed
@beeme1mr beeme1mr deleted the provider-namespace branch January 24, 2024 13:49
github-merge-queue bot pushed a commit to open-feature/js-sdk that referenced this pull request Feb 20, 2024
## This PR

- adds domain as a concept to the server and web SDK
- adds a deprecation warning anywhere client name was exposed to users.
- fixes an issue in the web SDK where context set on a domain before a
provider is registered was not used.

## Addresses

fixes #820
4aa9657

### Notes

This change is based on [this
spec](open-feature/spec#229) change. I tried to
make it a non-breaking change but I may have missed an untested
condition. Please carefully review to make sure I didn't miss anything.

### Follow-up Tasks

- Update the doc readme parser to support "domain".
- Update the NestJS and React SDKS. We should consider making those a
breaking change since they're sub 1.0.

---------

Signed-off-by: Michael Beemer <beeme1mr@users.noreply.github.com>
Signed-off-by: Todd Baert <todd.baert@dynatrace.com>
Co-authored-by: Todd Baert <todd.baert@dynatrace.com>
github-merge-queue bot pushed a commit to open-feature/js-sdk that referenced this pull request Feb 25, 2024
<!-- Please use this template for your pull request. -->
<!-- Please use the sections that you need and delete other sections -->

## This PR
<!-- add the description of the PR here -->

- adds support for domains
- removes named clients

### Related Issues
<!-- add here the GitHub issue that this PR resolves if applicable -->

relates to open-feature/spec#229

---------

Signed-off-by: Lukas Reining <lukas.reining@codecentric.de>
Co-authored-by: Michael Beemer <beeme1mr@users.noreply.github.com>
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.

Redefine named clients as domain