Lussatite.FeatureManagement 0.2.0

.NET Standard 2.0
There is a newer version of this package available.
See the version list below for details.
dotnet add package Lussatite.FeatureManagement --version 0.2.0
NuGet\Install-Package Lussatite.FeatureManagement -Version 0.2.0
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="Lussatite.FeatureManagement" Version="0.2.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Lussatite.FeatureManagement --version 0.2.0
#r "nuget: Lussatite.FeatureManagement, 0.2.0"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install Lussatite.FeatureManagement as a Cake Addin
#addin nuget:?package=Lussatite.FeatureManagement&version=0.2.0

// Install Lussatite.FeatureManagement as a Cake Tool
#tool nuget:?package=Lussatite.FeatureManagement&version=0.2.0

Lussatite.FeatureManagement

A light implementation of Microsoft.FeatureManagement interfaces.

Quickstart

  1. Take a dependency on Lussatite.FeatureManagement and Lussatite.FeatureManagement.LazyCache.

  2. Define a set of string constants for the names of your features. Look at the various static TestFeatures.cs files for ideas.

  3. Create a value provider by implementing ISessionManager or use one or more of the Lussatite.FeatureManagement.SessionManagers.* packages. Note that Lussaite.FeatureManagement does not write back to the session manager (unlike the Microsoft.FeatureManagement implementation).

  4. Wire-up the following in your IoC/DI container:

    • Session manager classes will need to be injected into the feature manager manually, since order does matter.
    • LussatiteLazyCacheFeatureManager as IFeatureManagerSnapshot (usually per-request / scoped lifetime).
  5. Inject IFeatureManagerSnapshot into your controller or service classes.

  6. await _feature.IsEnabledAsync(string feature) to obtain the status of the feature flag.

Packages

Lussatite.FeatureManagement:

Target: .NET Standard 2.0

  • LussatiteFeatureManager: A basic implementation of IFeatureManager.
  • This does not implement the Task<bool> IsEnabledAsync<TContext>(string feature, TContext context) method.
  • This does not make any calls back to the ISessionManager Task SetAsync(string featureName, bool enabled) method.

Lussatite.FeatureManagement.LazyCache:

Target: .NET Standard 2.0

  • LussatiteLazyCacheFeatureManager: A caching IFeatureManagerSnapshot implementation that uses LazyCache.
  • This does not implement the Task<bool> IsEnabledAsync<TContext>(string feature, TContext context) method.
  • This does not make any calls back to the ISessionManager Task SetAsync(string featureName, bool enabled) method.

Lussatite.FeatureManagement.SessionManagers.Core:

Target: .NET Core 3.1 (also compatible with .NET 5+)

  • ConfigurationValueSessionManager: A read-only ISessionManager implementation that uses IConfiguration to obtain its values.
  • SqlSessionManager: A read-only ISessionManager implementation that uses the user-provided DbCommand to obtain its values.

Lussatite.FeatureManagement.SessionManagers.Framework:

Target: .NET Framework 4.8

  • ConfigurationValueSessionManager: A read-only ISessionManager implementation that uses the static class ConfigurationManager to obtain its values.
  • SqlSessionManager: A read-only ISessionManager implementation that uses the user-provided DbCommand to obtain its values.

Build Status

Build-Test

References

Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows
.NET Core netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard2.0 netstandard2.1
.NET Framework net461 net462 net463 net47 net471 net472 net48 net481
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen40 tizen60
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on Lussatite.FeatureManagement:

Package Downloads
RimDev.AspNetCore.FeatureFlags

A library for strongly typed feature flags in .NET Standard 2.0.

Lussatite.FeatureManagement.SessionManagers

A set of ISessionManager implementations for .NET Standard 2.0 which return boolean null/true/false values.

Lussatite.FeatureManagement.SessionManagers.Framework

A set of ISessionManager implementations for .NET Framework 4.8 which return boolean null/true/false values.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.6.3 2,218 6/29/2022
1.6.2 1,256 6/28/2022
1.6.1 631 6/28/2022
1.6.0 1,030 6/15/2022
1.5.0 630 6/9/2022
1.4.1 871 5/24/2022
1.4.0 353 5/24/2022
1.3.1 360 5/23/2022
1.3.0 355 5/22/2022
1.2.0 221 5/20/2022
1.1.0 213 5/19/2022
1.0.0 233 5/16/2022
0.2.1 235 5/15/2022
0.2.0 997 5/14/2022
0.1.1 249 5/12/2022
0.1.0 243 5/11/2022