Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/reference/technologies/client/kotlin.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This content has been automatically generated from kotlin-sdk.
Edits should be made here: https://github.com/open-feature/kotlin-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:29 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/client/swift.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This content has been automatically generated from swift-sdk.
Edits should be made here: https://github.com/open-feature/swift-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:29 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
6 changes: 3 additions & 3 deletions docs/reference/technologies/client/web/angular.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ This content has been automatically generated from js-sdk.
Edits should be made here: https://github.com/open-feature/js-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:29 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
<a href="https://github.com/open-feature/spec/releases/tag/v0.8.0">
<img alt="Specification" src="https://img.shields.io/static/v1?label=specification&message=v0.8.0&color=yellow&style=for-the-badge" />
</a>

<a href="https://github.com/open-feature/js-sdk/releases/tag/angular-sdk-v0.0.17">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v0.0.17&color=blue&style=for-the-badge" />
<a href="https://github.com/open-feature/js-sdk/releases/tag/angular-sdk-v0.0.19">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v0.0.19&color=blue&style=for-the-badge" />
</a>

<br/>
Expand Down
64 changes: 61 additions & 3 deletions docs/reference/technologies/client/web/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ This content has been automatically generated from js-sdk.
Edits should be made here: https://github.com/open-feature/js-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:28 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
<a href="https://github.com/open-feature/spec/releases/tag/v0.8.0">
<img alt="Specification" src="https://img.shields.io/static/v1?label=specification&message=v0.8.0&color=yellow&style=for-the-badge" />
</a>

<a href="https://github.com/open-feature/js-sdk/releases/tag/web-sdk-v1.6.2">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.6.2&color=blue&style=for-the-badge" />
<a href="https://github.com/open-feature/js-sdk/releases/tag/web-sdk-v1.7.0">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.7.0&color=blue&style=for-the-badge" />
</a>

<br/>
Expand Down Expand Up @@ -106,6 +106,7 @@ See [here](https://open-feature.github.io/js-sdk/modules/_openfeature_web_sdk.ht
| ✅ | [Tracking](#tracking) | Associate user actions with feature flag evaluations, particularly for A/B testing. |
| ✅ | [Shutdown](#shutdown) | Gracefully clean up a provider during application shutdown. |
| ✅ | [Extending](#extending) | Extend OpenFeature with custom providers and hooks. |
| ✅ | [Multi-Provider](#multi-provider) | Combine multiple providers with configurable evaluation strategies. |

<sub>Implemented: ✅ | In-progress: ⚠️ | Not implemented yet: ❌</sub>

Expand Down Expand Up @@ -142,6 +143,63 @@ Once the provider has been registered, the status can be tracked using [events](
In some situations, it may be beneficial to register multiple providers in the same application.
This is possible using [domains](#domains), which is covered in more detail below.

#### Multi-Provider

The Multi-Provider allows you to use multiple underlying providers as sources of flag data for the OpenFeature web SDK. When a flag is being evaluated, the Multi-Provider will consult each underlying provider it is managing in order to determine the final result. Different evaluation strategies can be defined to control which providers get evaluated and which result is used.

The Multi-Provider is a powerful tool for performing migrations between flag providers, or combining multiple providers into a single feature flagging interface. For example:

- **Migration**: When migrating between two providers, you can run both in parallel under a unified flagging interface. As flags are added to the new provider, the Multi-Provider will automatically find and return them, falling back to the old provider if the new provider does not have the flag.
- **Multiple Data Sources**: The Multi-Provider allows you to seamlessly combine many sources of flagging data, such as environment variables, local files, database values and SaaS hosted feature management systems.

```ts
import { MultiProvider } from '@openfeature/web-sdk';

const multiProvider = new MultiProvider([
{ provider: new ProviderA() },
{ provider: new ProviderB() }
]);

await OpenFeature.setProviderAndWait(multiProvider);

const client = OpenFeature.getClient();
console.log(client.getBooleanDetails("my-flag", false));
```

By default, the Multi-Provider will evaluate all underlying providers in order and return the first successful result. If a provider indicates it does not have a flag (FLAG_NOT_FOUND error code), then it will be skipped and the next provider will be evaluated.

##### Evaluation Strategies

The Multi-Provider comes with three strategies out of the box:

- **FirstMatchStrategy** (default): Evaluates all providers in order and returns the first successful result. Providers that indicate FLAG_NOT_FOUND error will be skipped and the next provider will be evaluated.
- **FirstSuccessfulStrategy**: Evaluates all providers in order and returns the first successful result. Any error will cause that provider to be skipped.
- **ComparisonStrategy**: Evaluates all providers sequentially. If every provider returns a successful result with the same value, then that result is returned. Otherwise, the result returned by the configured "fallback provider" will be used.

```ts
import { MultiProvider, FirstSuccessfulStrategy } from '@openfeature/web-sdk';

const multiProvider = new MultiProvider(
[
{ provider: new ProviderA() },
{ provider: new ProviderB() }
],
new FirstSuccessfulStrategy()
);
```

##### Tracking Support

The Multi-Provider supports tracking events across multiple providers, allowing you to send analytics events to all configured providers simultaneously:

```ts
// Tracked events will be sent to all providers by default
client.track('user-conversion', {
value: 99.99,
currency: 'USD'
});
```

### Flag evaluation flow

When a new provider is added to OpenFeature client the following process happens:
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/client/web/react.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This content has been automatically generated from js-sdk.
Edits should be made here: https://github.com/open-feature/js-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:28 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/server/dart.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This content has been automatically generated from dart-server-sdk.
Edits should be made here: https://github.com/open-feature/dart-server-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:29 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
21 changes: 9 additions & 12 deletions docs/reference/technologies/server/dotnet.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ This content has been automatically generated from dotnet-sdk.
Edits should be made here: https://github.com/open-feature/dotnet-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:28 GMT+0000 (Coordinated Universal Time)
-->

[![Specification](https://img.shields.io/static/v1?label=specification&message=v0.8.0&color=yellow&style=for-the-badge)](https://github.com/open-feature/spec/releases/tag/v0.8.0)
[
![Release](https://img.shields.io/static/v1?label=release&message=v2.8.1&color=blue&style=for-the-badge)
](https://github.com/open-feature/dotnet-sdk/releases/tag/v2.8.1)
![Release](https://img.shields.io/static/v1?label=release&message=v2.9.0&color=blue&style=for-the-badge)
](https://github.com/open-feature/dotnet-sdk/releases/tag/v2.9.0)

[![Slack](https://img.shields.io/badge/slack-%40cncf%2Fopenfeature-brightgreen?style=flat&logo=slack)](https://cloud-native.slack.com/archives/C0344AANLA1)
[![Codecov](https://codecov.io/gh/open-feature/dotnet-sdk/branch/main/graph/badge.svg?token=MONAVJBXUJ)](https://codecov.io/gh/open-feature/dotnet-sdk)
Expand Down Expand Up @@ -442,10 +442,12 @@ Built a new hook? [Let us know](https://github.com/open-feature/openfeature.dev/
### Multi-Provider

> [!NOTE]
> The Multi-Provider feature is currently experimental. Hooks and events are not supported at the moment.
> The Multi-Provider feature is currently experimental.

The Multi-Provider enables the use of multiple underlying feature flag providers simultaneously, allowing different providers to be used for different flag keys or based on specific evaluation strategies.

The Multi-Provider supports provider hooks and executes them in accordance with the OpenFeature specification. Each provider's hooks are executed with context isolation, ensuring that context modifications by one provider's hooks do not affect other providers.

#### Basic Usage

```csharp
Expand Down Expand Up @@ -523,23 +525,20 @@ The Multi-Provider supports two evaluation modes:

#### Limitations

- **Hooks are not supported**: Multi-Provider does not currently support hook registration or execution
- **Events are not supported**: Provider events are not propagated from underlying providers
- **Experimental status**: The API may change in future releases
- **Experimental status**: The API may change in future releases

For a complete example, see the [AspNetCore sample](https://github.com/open-feature/dotnet-sdk/blob/main/samples/AspNetCore/README.md) which demonstrates Multi-Provider usage.

### Dependency Injection

> [!NOTE]
> The OpenFeature.DependencyInjection and OpenFeature.Hosting packages are currently experimental. They streamline the integration of OpenFeature within .NET applications, allowing for seamless configuration and lifecycle management of feature flag providers using dependency injection and hosting services.
> The OpenFeature.Hosting package is currently experimental. The Hosting package streamlines the integration of OpenFeature within .NET applications, allowing for seamless configuration and lifecycle management of feature flag providers using dependency injection and hosting services.

#### Installation

To set up dependency injection and hosting capabilities for OpenFeature, install the following packages:
To set up dependency injection and hosting capabilities for OpenFeature, install the following package:

```sh
dotnet add package OpenFeature.DependencyInjection
dotnet add package OpenFeature.Hosting
```

Expand All @@ -552,7 +551,6 @@ For a basic configuration, you can use the InMemoryProvider. This provider is si
```csharp
builder.Services.AddOpenFeature(featureBuilder => {
featureBuilder
.AddHostedFeatureLifecycle() // From Hosting package
.AddInMemoryProvider();
});
```
Expand All @@ -574,7 +572,6 @@ builder.Services.AddOpenFeature(featureBuilder => {
```csharp
builder.Services.AddOpenFeature(featureBuilder => {
featureBuilder
.AddHostedFeatureLifecycle()
.AddContext((contextBuilder, serviceProvider) => { /* Custom context configuration */ })
.AddHook((serviceProvider) => new LoggingHook( /* Custom configuration */ ))
.AddHook(new MetricsHook())
Expand Down
10 changes: 8 additions & 2 deletions docs/reference/technologies/server/go.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This content has been automatically generated from go-sdk.
Edits should be made here: https://github.com/open-feature/go-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:45 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:28 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down Expand Up @@ -114,7 +114,8 @@ openfeature.SetProviderAndWait(MyProvider{})
```

In some situations, it may be beneficial to register multiple providers in the same application.
This is possible using [domains](#domains), which is covered in more details below.
This is possible using [domains](#domains), which is covered in more details below, or the included [multiprovider](#multi-provider-implementation)
implementation.

### Targeting

Expand Down Expand Up @@ -326,6 +327,11 @@ tCtx := openfeature.MergeTransactionContext(ctx, openfeature.EvaluationContext{}
client.BooleanValue(tCtx, ....)
```

### Multi-Provider Implementation

Included with this SDK is an _experimental_ multi-provider that can be used to query multiple feature flag providers simultaneously.
More information can be found in the [multi package's README](https://github.com/open-feature/go-sdk/blob/main/openfeature/multi/README.md).

## Extending

### Develop a provider
Expand Down
10 changes: 5 additions & 5 deletions docs/reference/technologies/server/java.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ This content has been automatically generated from java-sdk.
Edits should be made here: https://github.com/open-feature/java-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Mon Oct 06 2025 08:10:44 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Oct 27 2025 08:11:27 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand All @@ -18,8 +18,8 @@ Last updated at Mon Oct 06 2025 08:10:44 GMT+0000 (Coordinated Universal Time)
</a>


<a href="https://github.com/open-feature/java-sdk/releases/tag/v1.18.1">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.18.1&color=blue&style=for-the-badge" />
<a href="https://github.com/open-feature/java-sdk/releases/tag/v1.18.2">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.18.2&color=blue&style=for-the-badge" />
</a>


Expand Down Expand Up @@ -54,7 +54,7 @@ Note that this library is intended to be used in server-side contexts and has no
<dependency>
<groupId>dev.openfeature</groupId>
<artifactId>sdk</artifactId>
<version>1.18.1</version>
<version>1.18.2</version>
</dependency>
```

Expand All @@ -77,7 +77,7 @@ If you would like snapshot builds, this is the relevant repository information:

```groovy
dependencies {
implementation 'dev.openfeature:sdk:1.18.1'
implementation 'dev.openfeature:sdk:1.18.2'
}
```

Expand Down
Loading