VOOZH about

URL: https://www.nuget.org/packages/Fluxera.Extensions.Hosting/

⇱ NuGet Gallery | Fluxera.Extensions.Hosting 10.0.1




👁 Image
Fluxera.Extensions.Hosting 10.0.1

Prefix Reserved
dotnet add package Fluxera.Extensions.Hosting --version 10.0.1
 
 
NuGet\Install-Package Fluxera.Extensions.Hosting -Version 10.0.1
 
 
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="Fluxera.Extensions.Hosting" Version="10.0.1" />
 
 
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Fluxera.Extensions.Hosting" Version="10.0.1" />
 
Directory.Packages.props
<PackageReference Include="Fluxera.Extensions.Hosting" />
 
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 Fluxera.Extensions.Hosting --version 10.0.1
 
 
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Fluxera.Extensions.Hosting, 10.0.1"
 
 
#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 Fluxera.Extensions.Hosting@10.0.1
 
 
#: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=Fluxera.Extensions.Hosting&version=10.0.1
 
Install as a Cake Addin
#tool nuget:?package=Fluxera.Extensions.Hosting&version=10.0.1
 
Install as a Cake Tool
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Fluxera.Extensions.Hosting

A library that extends the Microsoft.Extensions.Hosting library with modular host implementations for various application platforms.

The library uses the generic host implementation and build a modular structure upon it. It is possible to split your application into login modules that can be shared between different types of applications.

Available Hosts

The modular host is available for the following applicattion types:

  • ASP.NET Core
  • Blazor WebAssembly
  • Console / Windows Service
  • WPF
  • MAUI

Usage

Every application needs a host and a startup module class. The application is composed of modules that define dependencies on other modules and optional modules that are loaded as plugins.

public class ConsoleApplicationModule : ConfigureServicesModule
{
	public override void ConfigureServices(IServiceConfigurationContext context)
	{
		context.Services.AddHostedService<ConsoleHostedService>();
		context.Services.AddSingleton<IWeatherService, WeatherService>();
		context.Services.AddOptions<WeatherSettings>().Bind(context.Configuration.GetSection("Weather"));
	}
}

This startup module just configures some services and regiosters them in the service collection. The service confiuration pipelineis split up into three steps: pre-configure-, configure- and post-configure-services. Each methos is executed in every module, before moving to the next method.

If you need to configure the application after the creation of the service provider you can just use the base class ConfigureApplicationModule which provides a similar three step pipeline for initializing the application: pre-configure, configure and post-configure. Additionally this base class provides a methos that is executed on every module when the application shuts down.

In addtition to the two base classes ConfigureServicesModule and ConfigureApplicationModule you are free to use one of the module interfaces to meet you configuration needs.

  • IModule
    • IConfigureServicesModule
      • IPreConfigureServices
      • IConfigureServices
      • IPostConfigureServices
    • IConfigureApplicationModule
      • IPreConfigureApplication
      • IConfigureApplication
      • IPostConfigureApplication
    • IShutdownApplicationModule

You can even just implement the IModule interface on your module class, if you don't need any configuration and application initialization.

public class ConsoleApplicationHost : ConsoleApplicationHost<ConsoleApplicationModule>
{
}

The simplest application host class just inherits from one of the available base classes for the application type you are running.

Each base class provides several methods you can overide to configure additional plugin modules, or a custom logger to use while bootstrapping the host. Please refer to the samples for more information.

public static class Program
{
	public static async Task Main(string[] args)
	{
		await ApplicationHost.RunAsync<ConsoleApplicationHost>(args);

		Console.WriteLine();
		Console.WriteLine("Press any key to quit...");
		Console.ReadKey(true);
	}
}

All what's left to do is to run the host using one of the available static entry-points.

Product Versions Compatible and additional computed target framework versions.
.NET net8.0 net8.0 is compatible.  net8.0-android net8.0-android was computed.  net8.0-browser net8.0-browser was computed.  net8.0-ios net8.0-ios was computed.  net8.0-maccatalyst net8.0-maccatalyst was computed.  net8.0-macos net8.0-macos was computed.  net8.0-tvos net8.0-tvos was computed.  net8.0-windows net8.0-windows was computed.  net9.0 net9.0 is compatible.  net9.0-android net9.0-android was computed.  net9.0-browser net9.0-browser was computed.  net9.0-ios net9.0-ios was computed.  net9.0-maccatalyst net9.0-maccatalyst was computed.  net9.0-macos net9.0-macos was computed.  net9.0-tvos net9.0-tvos was computed.  net9.0-windows net9.0-windows was computed.  net10.0 net10.0 is compatible.  net10.0-android net10.0-android was computed.  net10.0-browser net10.0-browser was computed.  net10.0-ios net10.0-ios was computed.  net10.0-maccatalyst net10.0-maccatalyst was computed.  net10.0-macos net10.0-macos was computed.  net10.0-tvos net10.0-tvos was computed.  net10.0-windows 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 (75)

Showing the top 5 NuGet packages that depend on Fluxera.Extensions.Hosting:

Package Downloads
Fluxera.Extensions.Hosting.Modules.Configuration

A module that enables configuration.

Fluxera.Extensions.Hosting.Modules.OpenTelemetry

A module that enables OpenTelemetry monitoring.

Fluxera.Extensions.Hosting.Modules.AspNetCore

A module that enables ASP.NET Core.

Fluxera.Extensions.Hosting.Modules.Principal

A module that enables a principal accessor.

Fluxera.Extensions.Hosting.AspNetCore

A modular application host for ASP.NET.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
10.0.1 218 4/21/2026
10.0.0 202 4/13/2026
9.2.0 379 7/28/2025
9.0.2 1,430 2/5/2025
9.0.1 1,917 11/16/2024
9.0.0 374 11/14/2024
8.2.4 1,653 11/1/2024
8.2.3 482 7/9/2024
8.2.2 4,861 6/15/2024
8.2.1 1,666 6/2/2024
8.2.0 1,658 5/26/2024
8.1.3 3,994 4/26/2024
8.1.2 502 4/26/2024
8.1.1 468 4/26/2024
8.1.0 1,582 4/24/2024
8.0.7 9,211 4/18/2024
8.0.6 1,861 4/13/2024
8.0.5 496 4/13/2024
8.0.4 1,877 3/19/2024
8.0.3 5,387 2/22/2024
Loading failed