Skip to content

Commit

Permalink
chore: update sdk readmes (#936)
Browse files Browse the repository at this point in the history
The PR was automatically generated via the update-sdk-docs GitHub
workflow.

Signed-off-by: OpenFeature Bot <[email protected]>
  • Loading branch information
openfeaturebot authored Feb 3, 2025
1 parent 7587e9d commit 6470077
Show file tree
Hide file tree
Showing 14 changed files with 83 additions and 60 deletions.
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 Wed Jan 22 2025 08:09:31 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
23 changes: 14 additions & 9 deletions docs/reference/technologies/client/swift.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@ 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 Wed Jan 22 2025 08:09:31 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">

<a href="https://github.com/open-feature/spec/releases/tag/v0.7.0">
<img alt="Specification" src="https://img.shields.io/static/v1?label=specification&message=v0.7.0&color=yellow&style=for-the-badge" />
<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/swift-sdk/releases/tag/0.2.1">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v0.2.1&color=blue&style=for-the-badge" />
<a href="https://github.com/open-feature/swift-sdk/releases/tag/0.3.0">
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v0.3.0&color=blue&style=for-the-badge" />
</a>


Expand Down Expand Up @@ -58,7 +58,7 @@ First, ensure you have your GitHub account added as an option (+ > Add Source Co
If you manage dependencies through SPM, in the dependencies section of Package.swift add:

```swift
.package(url: "[email protected]:open-feature/swift-sdk.git", from: "0.2.1")
.package(url: "[email protected]:open-feature/swift-sdk.git", from: "0.3.0")
```

and in the target dependencies section add:
Expand All @@ -84,11 +84,12 @@ Task {

## Features

| Status | Features | Description |
| ------ | ------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
| Status | Features | Description |
| ------ | ------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
|| [Providers](#providers) | Integrate with a commercial, open source, or in-house feature management tool. |
|| [Targeting](#targeting) | Contextually-aware flag evaluation using [evaluation context](/docs/reference/concepts/evaluation-context). |
|| [Hooks](#hooks) | Add functionality to various stages of the flag evaluation life-cycle. |
|| [Tracking](#tracking) | Associate user actions with feature flag evaluations. |
|| [Logging](#logging) | Integrate with popular logging packages. |
|| [Named clients](#named-clients) | Utilize multiple providers in a single application. |
|| [Eventing](#eventing) | React to state changes in the provider or flag management system. |
Expand Down Expand Up @@ -147,6 +148,10 @@ _ = client.getValue(
defaultValue: false,
options: FlagEvaluationOptions(hooks: [ExampleHook()]))
```
### Tracking

Tracking is not yet available in the iOS SDK.

### Logging

Logging customization is not yet available in the iOS SDK.
Expand Down Expand Up @@ -236,7 +241,7 @@ class BooleanHook: Hook {
// do something
}

func finallyAfter<HookValue>(ctx: HookContext<HookValue>, hints: [String: Any]) {
func finally<HookValue>(ctx: HookContext<HookValue>, hints: [String: Any]) {
// do something
}
}
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/client/web/angular.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 Wed Jan 22 2025 08:09:32 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/client/web/index.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 Wed Jan 22 2025 08:09:31 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
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 Wed Jan 22 2025 08:09:31 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
70 changes: 44 additions & 26 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 Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

[![Specification](https://img.shields.io/static/v1?label=specification&message=v0.7.0&color=yellow&style=for-the-badge)](https://github.com/open-feature/spec/releases/tag/v0.7.0)
[
![Release](https://img.shields.io/static/v1?label=release&message=v2.2.0&color=blue&style=for-the-badge)
](https://github.com/open-feature/dotnet-sdk/releases/tag/v2.2.0)
![Release](https://img.shields.io/static/v1?label=release&message=v2.3.0&color=blue&style=for-the-badge)
](https://github.com/open-feature/dotnet-sdk/releases/tag/v2.3.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 @@ -154,6 +154,19 @@ var value = await client.GetBooleanValueAsync("boolFlag", false, context, new Fl

The .NET SDK uses Microsoft.Extensions.Logging. See the [manual](https://learn.microsoft.com/en-us/dotnet/core/extensions/logging?tabs=command-line) for complete documentation.

#### Logging Hook

The .NET SDK includes a LoggingHook, which logs detailed information at key points during flag evaluation, using Microsoft.Extensions.Logging structured logging API. This hook can be particularly helpful for troubleshooting and debugging; simply attach it at the global, client or invocation level and ensure your log level is set to "debug".

```csharp
using var loggerFactory = LoggerFactory.Create(builder => builder.AddConsole());
var logger = loggerFactory.CreateLogger("Program");

var client = Api.Instance.GetClient();
client.AddHooks(new LoggingHook(logger));
```
See [hooks](#hooks) for more information on configuring hooks.

### Domains

Clients can be assigned to a domain.
Expand Down Expand Up @@ -380,37 +393,42 @@ builder.Services.AddOpenFeature(featureBuilder => {
You can register a custom provider, such as `InMemoryProvider`, with OpenFeature using the `AddProvider` method. This approach allows you to dynamically resolve services or configurations during registration.

```csharp
services.AddOpenFeature()
.AddProvider(provider =>
services.AddOpenFeature(builder =>
{
builder.AddProvider(provider =>
{
// Resolve services or configurations as needed
var variants = new Dictionary<string, bool> { { "on", true } };
var flags = new Dictionary<string, Flag>
{
// Resolve services or configurations as needed
var configuration = provider.GetRequiredService<IConfiguration>();
var flags = new Dictionary<string, Flag>
{
{ "feature-key", new Flag<bool>(configuration.GetValue<bool>("FeatureFlags:Key")) }
};

// Register a custom provider, such as InMemoryProvider
return new InMemoryProvider(flags);
});
{ "feature-key", new Flag<bool>(variants, "on") }
};

// Register a custom provider, such as InMemoryProvider
return new InMemoryProvider(flags);
});
});
```

#### Adding a Domain-Scoped Provider

You can also register a domain-scoped custom provider, enabling configurations specific to each domain:

```csharp
services.AddOpenFeature()
.AddProvider("my-domain", (provider, domain) =>
services.AddOpenFeature(builder =>
{
builder.AddProvider("my-domain", (provider, domain) =>
{
// Resolve services or configurations as needed for the domain
var variants = new Dictionary<string, bool> { { "on", true } };
var flags = new Dictionary<string, Flag>
{
// Resolve services or configurations as needed for the domain
var flags = new Dictionary<string, Flag>
{
{ $"{domain}-feature-key", new Flag<bool>(true) }
};

// Register a domain-scoped custom provider such as InMemoryProvider
return new InMemoryProvider(flags);
});
{ $"{domain}-feature-key", new Flag<bool>(variants, "on") }
};

// Register a domain-scoped custom provider such as InMemoryProvider
return new InMemoryProvider(flags);
});
});
```

2 changes: 1 addition & 1 deletion 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 Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion 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 Wed Jan 22 2025 08:09:29 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/server/javascript/index.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 Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/server/javascript/nestjs.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 Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

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

Last updated at Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

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

Last updated at Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:39 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand All @@ -20,8 +20,8 @@ Last updated at Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)



<a href="https://github.com/open-feature/python-sdk/releases/tag/v0.7.4">
<img alt="Latest version" src="https://img.shields.io/static/v1?label=release&message=v0.7.4&color=blue&style=for-the-badge" />
<a href="https://github.com/open-feature/python-sdk/releases/tag/v0.7.5">
<img alt="Latest version" src="https://img.shields.io/static/v1?label=release&message=v0.7.5&color=blue&style=for-the-badge" />
</a>


Expand Down Expand Up @@ -54,13 +54,13 @@ Last updated at Wed Jan 22 2025 08:09:30 GMT+0000 (Coordinated Universal Time)
#### Pip install

```bash
pip install openfeature-sdk==0.7.4
pip install openfeature-sdk==0.7.5
```

#### requirements.txt

```bash
openfeature-sdk==0.7.4
openfeature-sdk==0.7.5
```

```python
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/technologies/server/ruby.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This content has been automatically generated from ruby-sdk.
Edits should be made here: https://github.com/open-feature/ruby-sdk
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs

Last updated at Wed Jan 22 2025 08:09:32 GMT+0000 (Coordinated Universal Time)
Last updated at Mon Feb 03 2025 08:09:40 GMT+0000 (Coordinated Universal Time)
-->

<p align="center" class="github-badges">
Expand Down
20 changes: 10 additions & 10 deletions src/datasets/sdks/sdk-compatibility.json
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@
"path": "/docs/reference/technologies/server/dotnet",
"category": "Server",
"release": {
"href": "https://github.com/open-feature/dotnet-sdk/releases/tag/v2.2.0",
"version": "2.2.0",
"href": "https://github.com/open-feature/dotnet-sdk/releases/tag/v2.3.0",
"version": "2.3.0",
"stable": true
},
"spec": {
Expand Down Expand Up @@ -228,8 +228,8 @@
"path": "/docs/reference/technologies/server/python",
"category": "Server",
"release": {
"href": "https://github.com/open-feature/python-sdk/releases/tag/v0.7.4",
"version": "0.7.4",
"href": "https://github.com/open-feature/python-sdk/releases/tag/v0.7.5",
"version": "0.7.5",
"stable": false
},
"spec": {
Expand Down Expand Up @@ -444,13 +444,13 @@
"path": "/docs/reference/technologies/client/swift",
"category": "Client",
"release": {
"href": "https://github.com/open-feature/swift-sdk/releases/tag/0.2.1",
"version": "0.2.1",
"href": "https://github.com/open-feature/swift-sdk/releases/tag/0.3.0",
"version": "0.3.0",
"stable": false
},
"spec": {
"href": "https://github.com/open-feature/spec/releases/tag/v0.7.0",
"version": "0.7.0"
"href": "https://github.com/open-feature/spec/releases/tag/v0.8.0",
"version": "0.8.0"
},
"features": {
"Providers": {
Expand Down Expand Up @@ -478,8 +478,8 @@
"path": "/docs/reference/technologies/client/swift#eventing"
},
"Tracking": {
"status": "",
"path": "/docs/reference/technologies/client/swift"
"status": "",
"path": "/docs/reference/technologies/client/swift#tracking"
},
"Shutdown": {
"status": "",
Expand Down

0 comments on commit 6470077

Please sign in to comment.