Cosmos.CrossCuttingConcerns.Preferences.Flagsmith 0.1.3

dotnet add package Cosmos.CrossCuttingConcerns.Preferences.Flagsmith --version 0.1.3
                    
NuGet\Install-Package Cosmos.CrossCuttingConcerns.Preferences.Flagsmith -Version 0.1.3
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Cosmos.CrossCuttingConcerns.Preferences.Flagsmith" Version="0.1.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Cosmos.CrossCuttingConcerns.Preferences.Flagsmith" Version="0.1.3" />
                    
Directory.Packages.props
<PackageReference Include="Cosmos.CrossCuttingConcerns.Preferences.Flagsmith" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Cosmos.CrossCuttingConcerns.Preferences.Flagsmith --version 0.1.3
                    
#r "nuget: Cosmos.CrossCuttingConcerns.Preferences.Flagsmith, 0.1.3"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Cosmos.CrossCuttingConcerns.Preferences.Flagsmith@0.1.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Cosmos.CrossCuttingConcerns.Preferences.Flagsmith&version=0.1.3
                    
Install as a Cake Addin
#tool nuget:?package=Cosmos.CrossCuttingConcerns.Preferences.Flagsmith&version=0.1.3
                    
Install as a Cake Tool

Cosmos.CrossCuttingConcerns.Preferences.Flagsmith

Implementación Flagsmith de Cosmos.CrossCuttingConcerns.Preferences. Los microservicios de Cosmos dependen del paquete de abstracciones; este paquete sólo se referencia en el composition root.

Registro

// Program.cs (composition root)
using Cosmos.CrossCuttingConcerns.Preferences.Flagsmith;

builder.Services.AddFlagsmithPreferences(
    environmentKey: builder.Configuration["Flagsmith:EnvironmentKey"]!,
    apiUrl:         builder.Configuration["Flagsmith:ApiUrl"]!);

Ajustes operativos opcionales (con defaults razonables):

builder.Services.AddFlagsmithPreferences(
    environmentKey: key,
    apiUrl:         url,
    enableLocalEvaluation:             true,   // default true
    environmentRefreshIntervalSeconds: 60,     // default 60
    requestTimeoutSeconds:             5);     // default 5

Comportamiento

  • Local evaluation activado por defecto: el SDK hace pull periódico del entorno y evalúa flags en memoria. Mantiene baja la cuenta de requests contra Flagsmith.
  • Identity / Tenant: el provider usa Cosmos.MultiTenancy.TenantResolver.TenantId como identifier de Flagsmith. La resolución del tenant es responsabilidad del host (hoy default "CosmosTenant"; se reemplaza con JwtTenantResolver u otros).
  • Conversión: T = boolIsFeatureEnabled. Para el resto, GetFeatureValue + Convert.ChangeType (primitivos) / Enum.Parse (enums) / Nullable<T> desenvuelto.
  • Fallback: si el cliente Flagsmith falla o la conversión no aplica, el provider devuelve el defaultValue y loguea un warning estructurado.

Requisitos

  • net10.0
  • Cosmos.MultiTenancy.TenantResolver registrado en DI (viene embebido en Cosmos.EventSourcing.CritterStack).

Deuda técnica conocida

Este paquete declara Cosmos.EventSourcing.CritterStack como dependencia únicamente para arrastrar Cosmos.MultiTenancy. Cuando Cosmos.MultiTenancy se publique como NuGet independiente, se migrará a esa dependencia directa.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.