sia-digital / pibox

PiBox is a service hosting framework that allows .net devs to decorate their services with behaviours or functionality (think of plugins) while only using minimal configuration.
https://sia-digital.gitbook.io/pibox/
MIT License
6 stars 3 forks source link
api aspnetcore dotnet dotnet-core dotnet-standard dotnet8 framework lib library logging metrics microservice net80 performance pibox plugins security tests tracing web

PiBox

Framework MIT License Nuget Nuget

PiBox is a service hosting framework that allows .net devs to decorate their services with behaviours or functionality (think of plugins) while only using minimal configuration.

"PiBox" because we want to support unlimited plugins within the api out of the box!

Features

Prerequisites

Before you begin, ensure you have met the following requirements:

Get started

To start using PiBox components/plugins, you have to:

  1. Install/add the PluginWebHost via nuget package PiBox.Hosting.WebHost
  2. Install/add the source generator plugin via nuget package PiBox.Hosting.Generator
  3. Rewrite the Entrypoint Program.cs to have following code:
using PiBox.Hosting.WebHost;
PluginWebHostBuilder.RunDefault(PiBox.Generated.PiBoxPluginTypes.All);
  1. Install/add your plugins via nuget packages prefixed with PiBox

Documentation

You can find a comprehensive documentation here

Or check the individual README files in each plugins directory

Building PiBox

To build PiBox, follow these steps:

dotnet build ./PiBox.sln

To format and style check the solution run:

dotnet format ./PiBox.sln

Testing PiBox

We are using these frameworks for unit testing

To run unit tests for PiBox, follow these steps:

dotnet test ./PiBox.sln

Contributing to PiBox

To contribute to PiBox, follow these steps:

  1. Check the issues if your idea or problem already exists
  2. Open a new issue if necessary to explain your idea or problem with as much details as possible

To contribute code along your issue please follow the these steps:

  1. Clone this repository.
  2. Create a branch: git checkout -b <branch_name>.
  3. Check our used tools and frameworks to ensure you are using the same tools which are already in place.
  4. Check if your changes are in line with our style settings from .editorconfig and run dotnet format.
  5. Make your changes and commit them: git commit -m '<commit_message>'
  6. Push to the original branch: git push origin PiBox/<branch_name>
  7. Create the pull request.

Development decisions

Disabled Compiler Errors

Code Reason Link
1701 Assembly Referencing 1701
1702 Assembly Referencing 1702
1591 Disable XML Comments 1591