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

Implement value semantics for CosmosClientOptions #4965

Open
AndriySvyryd opened this issue Jan 14, 2025 · 0 comments
Open

Implement value semantics for CosmosClientOptions #4965

AndriySvyryd opened this issue Jan 14, 2025 · 0 comments
Labels
customer-reported Issue created by a customer needs-investigation

Comments

@AndriySvyryd
Copy link

When the options are provided by the user it would be useful to be able to compare them to each other to be able to return an existing CosmosClient instance if the options used to create it are equivalent.

Describe the solution you'd like
Override Equals and GetHashCode. Using reference equality for options of reference type would be acceptable.

Describe alternatives you've considered
Currently EF accomplishes this by wrapping all the options: https://github.com/dotnet/efcore/blob/38dc78fcc3bfff413cb9ad8a7080dc13a1ca8ee4/src/EFCore.Cosmos/Infrastructure/Internal/CosmosDbOptionExtension.cs#L642

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
customer-reported Issue created by a customer needs-investigation
Projects
None yet
Development

No branches or pull requests

1 participant