Sisk.HttpServer
0.3.0
Prefix Reserved
See the version list below for details.
dotnet add package Sisk.HttpServer --version 0.3.0
NuGet\Install-Package Sisk.HttpServer -Version 0.3.0
<PackageReference Include="Sisk.HttpServer" Version="0.3.0" />
paket add Sisk.HttpServer --version 0.3.0
#r "nuget: Sisk.HttpServer, 0.3.0"
// Install Sisk.HttpServer as a Cake Addin #addin nuget:?package=Sisk.HttpServer&version=0.3.0 // Install Sisk.HttpServer as a Cake Tool #tool nuget:?package=Sisk.HttpServer&version=0.3.0
X-Powered-By: Sisk
Sisk is a powerful micro-framework for building powerful Restful web APIs. It was written using .NET 6 and Microsoft-HTTPAPI/2.0 as their HTTP Engines. Currently, this micro-framework is suitable for building restful APIs, in a structured and object-oriented way. There is no native support for frontend rendering, templates or database connection. You can extend it as you see fit.
Features
- Lightning fast response/second average;
- A routing system, supporting handlers ("Middlewares"), names, parameters and contexts;
- Easy CORS integration;
- Request and response handlers and helpers;
- Multiplatform (credits to .NET 6).
Note: this micro-framework only works for HTTP and not HTTPS. To use it over TLS/HTTPS, use a reverse proxy.
Documentation
Documentation for Sisk aren't ready yet. Use this readme for now.
Installation
Nuget package ins't published yet. Come back soon or you can build it from source.
Example
using Sisk;
internal class Program
{
static void Main(string[] args)
{
Router router = new ();
router.SetRoute(RouteMethod.Get, "/", (req) =>
{
return HttpResponse.CreateOK("Hello, world!");
});
HttpServer server = new (router)
{
ListeningPort = 5555,
Verbose = true
};
Console.WriteLine("Sisk is listening on HTTP localhost:{0}", server.ListeningPort);
server.Start();
while(true) { }
}
}
Benchmark
Used tool: https://github.com/grafana/k6
> cat .\test.js
import http from "k6/http";
export default function () {
let response = http.get("http://localhost:5555/");
};
> k6 run .\test.js --vus 512 --duration 10s
data_received..................: 57 MB 5.7 MB/s
data_sent......................: 26 MB 2.6 MB/s
http_req_blocked...............: avg=21.15µs min=0s med=0s max=55.39ms p(90)=0s p(95)=0s
http_req_connecting............: avg=18.5µs min=0s med=0s max=22.1ms p(90)=0s p(95)=0s
http_req_duration..............: avg=15.58ms min=0s med=14.26ms max=171.71ms p(90)=22.28ms p(95)=26.78ms
{ expected_response:true }...: avg=15.58ms min=0s med=14.26ms max=171.71ms p(90)=22.28ms p(95)=26.78ms
http_req_failed................: 0.00% ✓ 0 ✗ 325652
http_req_receiving.............: avg=40.33µs min=0s med=0s max=65.37ms p(90)=0s p(95)=0s
http_req_sending...............: avg=14.27µs min=0s med=0s max=51.2ms p(90)=0s p(95)=0s
http_req_tls_handshaking.......: avg=0s min=0s med=0s max=0s p(90)=0s p(95)=0s
http_req_waiting...............: avg=15.52ms min=0s med=14.23ms max=168.2ms p(90)=22.2ms p(95)=26.65ms
http_reqs......................: 325652 32515.685439/s
iteration_duration.............: avg=15.69ms min=0s med=14.32ms max=185.77ms p(90)=22.46ms p(95)=27.11ms
iterations.....................: 325652 32515.685439/s
vus............................: 512 min=512 max=512
vus_max........................: 512 min=512 max=512
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net6.0
- Newtonsoft.Json (>= 13.0.1)
NuGet packages (4)
Showing the top 4 NuGet packages that depend on Sisk.HttpServer:
Package | Downloads |
---|---|
Sisk.ServiceProvider
This package includes tools for easily porting your Sisk service. |
|
Sisk.IniConfiguration
This package provides an INI configuration parser for the Sisk Framework and other .NET projects. |
|
Sisk.BasicAuth
This package includes an helper for embeding basic authentication in your applications made with Sisk. |
|
Sisk.SslProxy
This package provides an experimental SSL proxy for the Sisk Framework and other .NET projects. |
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on Sisk.HttpServer:
Repository | Stars |
---|---|
sisk-http/core
Sisk's request and response processor mainframe source code.
|
Version | Downloads | Last updated | |
---|---|---|---|
1.3.0 | 105 | 11/13/2024 | |
1.3.0-rc5 | 85 | 11/10/2024 | |
1.3.0-rc4 | 65 | 11/9/2024 | |
1.3.0-rc2 | 74 | 11/5/2024 | |
1.3.0-rc | 65 | 11/5/2024 | |
1.2.0 | 118 | 10/29/2024 | |
1.1.1 | 341 | 10/17/2024 | |
1.1.0 | 220 | 9/22/2024 | |
1.0.4 | 68 | 10/17/2024 | |
1.0.3 | 128 | 9/13/2024 | |
1.0.2 | 147 | 9/1/2024 | |
1.0.1 | 146 | 8/28/2024 | |
1.0.0 | 157 | 8/16/2024 | |
1.0.0-rc8 | 133 | 8/13/2024 | |
1.0.0-rc7 | 86 | 8/1/2024 | |
1.0.0-rc6 | 68 | 7/24/2024 | |
1.0.0-rc4 | 81 | 7/10/2024 | |
1.0.0-rc3 | 71 | 7/4/2024 | |
1.0.0-rc2 | 92 | 6/24/2024 | |
1.0.0-rc1 | 101 | 6/7/2024 | |
0.16.2 | 544 | 4/28/2024 | |
0.16.2-beta4 | 107 | 4/24/2024 | |
0.16.1 | 177 | 2/26/2024 | |
0.16.0 | 1,721 | 1/9/2024 | |
0.16.0-rc-5 | 255 | 1/3/2024 | |
0.16.0-rc-4 | 128 | 12/21/2023 | |
0.16.0-rc-3 | 139 | 12/7/2023 | |
0.16.0-rc-2 | 141 | 11/25/2023 | |
0.16.0-rc-1 | 120 | 11/13/2023 | |
0.15.3.1 | 110 | 2/19/2024 | |
0.15.3 | 213 | 11/25/2023 | |
0.15.2 | 645 | 10/30/2023 | |
0.15.1 | 202 | 9/30/2023 | |
0.15.0.47 | 231 | 8/30/2023 | |
0.15.0.47-rc | 64 | 8/25/2023 | |
0.15.0.46-beta | 78 | 8/22/2023 | |
0.15.0.42-beta | 160 | 8/16/2023 | |
0.15.0.6-beta | 169 | 8/9/2023 | |
0.15.0-beta | 167 | 7/20/2023 | |
0.14.0.1 | 227 | 7/18/2023 | |
0.14.0 | 187 | 7/17/2023 | |
0.13.1.1 | 194 | 6/10/2023 | |
0.13.1 | 195 | 6/8/2023 | |
0.13.0 | 207 | 5/20/2023 | |
0.12.1 | 181 | 5/2/2023 | |
0.12.0 | 199 | 4/29/2023 | |
0.11.1 | 193 | 4/9/2023 | |
0.11.0 | 251 | 3/30/2023 | |
0.10.1 | 239 | 3/21/2023 | |
0.10.0 | 229 | 3/15/2023 | |
0.9.1 | 268 | 3/2/2023 | |
0.9.0 | 254 | 2/22/2023 | |
0.8.9 | 255 | 2/14/2023 | |
0.8.8 | 274 | 2/8/2023 | |
0.8.6 | 305 | 2/2/2023 | |
0.8.5 | 292 | 2/1/2023 | |
0.8.4 | 310 | 1/31/2023 | |
0.8.3 | 305 | 1/26/2023 | |
0.8.2 | 339 | 1/10/2023 | |
0.8.1 | 318 | 1/7/2023 | |
0.8.0 | 324 | 1/6/2023 | |
0.7.5 | 298 | 12/28/2022 | |
0.7.4 | 329 | 12/27/2022 | |
0.7.3 | 306 | 12/26/2022 | |
0.7.2 | 323 | 12/22/2022 | |
0.7.1 | 313 | 12/21/2022 | |
0.7.0 | 330 | 12/21/2022 | |
0.6.4 | 301 | 12/13/2022 | |
0.6.3 | 323 | 12/11/2022 | |
0.6.2 | 333 | 12/11/2022 | |
0.6.1 | 305 | 12/10/2022 | |
0.6.0 | 318 | 12/9/2022 | |
0.5.0 | 362 | 11/16/2022 | |
0.4.8 | 376 | 10/30/2022 | |
0.4.6 | 390 | 10/27/2022 | |
0.4.1 | 410 | 10/19/2022 | |
0.4.0 | 398 | 10/18/2022 | |
0.3.1 | 424 | 10/15/2022 | |
0.3.0 | 433 | 10/15/2022 |