diff --git a/frameworks/CSharp/embedio/Benchmarks/Benchmarks.csproj b/frameworks/CSharp/embedio/Benchmarks/Benchmarks.csproj
index 19e73c8b7c4..0015577d97e 100644
--- a/frameworks/CSharp/embedio/Benchmarks/Benchmarks.csproj
+++ b/frameworks/CSharp/embedio/Benchmarks/Benchmarks.csproj
@@ -1,23 +1,23 @@
-
+
-
- net5.0
- 9.0
-
+
+ net9.0
+ 13.0
+
EmbedIO Benchmarks
Test suite to be executed with TechEmpower FrameworkBenchmarks.
-
- Benchmarks.Program
+
+ Benchmarks.Program
Exe
-
+
true
false
-
+
-
+
-
+
-
-
\ No newline at end of file
+
+
diff --git a/frameworks/CSharp/embedio/Benchmarks/Program.cs b/frameworks/CSharp/embedio/Benchmarks/Program.cs
index db1f8734c3e..f554daee530 100644
--- a/frameworks/CSharp/embedio/Benchmarks/Program.cs
+++ b/frameworks/CSharp/embedio/Benchmarks/Program.cs
@@ -1,10 +1,12 @@
-using EmbedIO;
-using Swan.Logging;
-using System;
+using System;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
+using EmbedIO;
+
+using Swan.Logging;
+
namespace Benchmarks
{
@@ -21,7 +23,7 @@ public class JsonResult
public static class Program
{
- private static readonly ManualResetEvent _WaitEvent = new ManualResetEvent(false);
+ private static readonly ManualResetEvent WaitEvent = new(false);
public static async Task Main(string[] args)
{
@@ -60,12 +62,12 @@ public static async Task Main(string[] args)
{
AppDomain.CurrentDomain.ProcessExit += (_, __) =>
{
- _WaitEvent.Set();
+ WaitEvent.Set();
};
await server.RunAsync();
- _WaitEvent.WaitOne();
+ WaitEvent.WaitOne();
return 0;
}
diff --git a/frameworks/CSharp/embedio/README.md b/frameworks/CSharp/embedio/README.md
index f04d7d2ecd9..afa7412870f 100644
--- a/frameworks/CSharp/embedio/README.md
+++ b/frameworks/CSharp/embedio/README.md
@@ -6,17 +6,17 @@ See the [project website](https://github.com/unosquare/embedio) for more informa
**Language**
-* C# 9.0
+* C# 13.0
**Platforms**
-* .NET 5
+* .NET 9
**Web Servers**
* [EmbedIO](https://github.com/unosquare/embedio)
-## Paths & Source for Tests
+## Paths \& Source for Tests
* [Plaintext](Benchmarks/Program.cs): "/plaintext"
* [JSON](Benchmarks/Program.cs): "/json"
diff --git a/frameworks/CSharp/embedio/embedio.dockerfile b/frameworks/CSharp/embedio/embedio.dockerfile
index 675c16d8841..35e05ff1fc4 100644
--- a/frameworks/CSharp/embedio/embedio.dockerfile
+++ b/frameworks/CSharp/embedio/embedio.dockerfile
@@ -1,4 +1,4 @@
-FROM mcr.microsoft.com/dotnet/sdk:5.0-alpine AS build
+FROM mcr.microsoft.com/dotnet/sdk:9.0-alpine AS build
WORKDIR /source
# copy csproj and restore as distinct layers
@@ -7,10 +7,10 @@ RUN dotnet restore -r linux-musl-x64
# copy and publish app and libraries
COPY Benchmarks/ .
-RUN dotnet publish -c release -o /app -r linux-musl-x64
+RUN dotnet publish -c release -o /app -r linux-musl-x64 --no-restore --self-contained
# final stage/image
-FROM mcr.microsoft.com/dotnet/runtime-deps:5.0-alpine
+FROM mcr.microsoft.com/dotnet/runtime-deps:9.0-alpine
WORKDIR /app
COPY --from=build /app .
diff --git a/frameworks/CSharp/genhttp/Benchmarks/Benchmarks.csproj b/frameworks/CSharp/genhttp/Benchmarks/Benchmarks.csproj
index 529f7add6ca..1189d0c151c 100644
--- a/frameworks/CSharp/genhttp/Benchmarks/Benchmarks.csproj
+++ b/frameworks/CSharp/genhttp/Benchmarks/Benchmarks.csproj
@@ -26,11 +26,11 @@
-
-
+
+
-
-
+
+
diff --git a/frameworks/CSharp/netcoreserver/Benchmarks/Benchmarks.csproj b/frameworks/CSharp/netcoreserver/Benchmarks/Benchmarks.csproj
index 6d372b01ee3..8315e4a6e83 100644
--- a/frameworks/CSharp/netcoreserver/Benchmarks/Benchmarks.csproj
+++ b/frameworks/CSharp/netcoreserver/Benchmarks/Benchmarks.csproj
@@ -1,24 +1,24 @@
-
+
-
- net5.0
- 9.0
-
+
+ net9.0
+ 13.0
+
EmbedIO Benchmarks
Test suite to be executed with TechEmpower FrameworkBenchmarks.
-
- Benchmarks.Program
+
+ Benchmarks.Program
Exe
-
+
true
false
-
+
-
+
-
-
+
+
-
-
\ No newline at end of file
+
+
diff --git a/frameworks/CSharp/netcoreserver/Benchmarks/HttpBenchmarkSession.cs b/frameworks/CSharp/netcoreserver/Benchmarks/HttpBenchmarkSession.cs
index 25e58bd5aa1..bb99ce8f2c1 100644
--- a/frameworks/CSharp/netcoreserver/Benchmarks/HttpBenchmarkSession.cs
+++ b/frameworks/CSharp/netcoreserver/Benchmarks/HttpBenchmarkSession.cs
@@ -27,7 +27,7 @@ protected override void OnReceivedRequest(HttpRequest request)
}
else
{
- SendResponseAsync(Response.MakeErrorResponse("Not found", 404));
+ SendResponseAsync(Response.MakeErrorResponse(404, "Not found"));
}
}
diff --git a/frameworks/CSharp/netcoreserver/Benchmarks/Program.cs b/frameworks/CSharp/netcoreserver/Benchmarks/Program.cs
index 411569ffb2f..3a821463b10 100644
--- a/frameworks/CSharp/netcoreserver/Benchmarks/Program.cs
+++ b/frameworks/CSharp/netcoreserver/Benchmarks/Program.cs
@@ -8,7 +8,7 @@ namespace Benchmarks
public static class Program
{
- private static readonly ManualResetEvent _WaitEvent = new ManualResetEvent(false);
+ private static readonly ManualResetEvent WaitEvent = new(false);
public static int Main(string[] args)
{
@@ -18,12 +18,12 @@ public static int Main(string[] args)
{
AppDomain.CurrentDomain.ProcessExit += (_, __) =>
{
- _WaitEvent.Set();
+ WaitEvent.Set();
};
server.Start();
- _WaitEvent.WaitOne();
+ WaitEvent.WaitOne();
return 0;
}
diff --git a/frameworks/CSharp/netcoreserver/README.md b/frameworks/CSharp/netcoreserver/README.md
index 985758c2bc9..31c1e995dcd 100644
--- a/frameworks/CSharp/netcoreserver/README.md
+++ b/frameworks/CSharp/netcoreserver/README.md
@@ -6,17 +6,17 @@ See the [project website](https://github.com/chronoxor/NetCoreServer) for more i
**Language**
-* C# 9.0
+* C# 13.0
**Platforms**
-* .NET 5
+* .NET 9
**Web Servers**
* [NetCoreServer](https://github.com/chronoxor/NetCoreServer)
-## Paths & Source for Tests
+## Paths \& Source for Tests
* [Plaintext](Benchmarks/HttpBenchmarkSession.cs): "/plaintext"
* [JSON](Benchmarks/HttpBenchmarkSession.cs): "/json"
diff --git a/frameworks/CSharp/netcoreserver/netcoreserver.dockerfile b/frameworks/CSharp/netcoreserver/netcoreserver.dockerfile
index 675c16d8841..35e05ff1fc4 100644
--- a/frameworks/CSharp/netcoreserver/netcoreserver.dockerfile
+++ b/frameworks/CSharp/netcoreserver/netcoreserver.dockerfile
@@ -1,4 +1,4 @@
-FROM mcr.microsoft.com/dotnet/sdk:5.0-alpine AS build
+FROM mcr.microsoft.com/dotnet/sdk:9.0-alpine AS build
WORKDIR /source
# copy csproj and restore as distinct layers
@@ -7,10 +7,10 @@ RUN dotnet restore -r linux-musl-x64
# copy and publish app and libraries
COPY Benchmarks/ .
-RUN dotnet publish -c release -o /app -r linux-musl-x64
+RUN dotnet publish -c release -o /app -r linux-musl-x64 --no-restore --self-contained
# final stage/image
-FROM mcr.microsoft.com/dotnet/runtime-deps:5.0-alpine
+FROM mcr.microsoft.com/dotnet/runtime-deps:9.0-alpine
WORKDIR /app
COPY --from=build /app .
diff --git a/frameworks/CSharp/wiredio/Benchmarks/Benchmarks.csproj b/frameworks/CSharp/wiredio/Benchmarks/Benchmarks.csproj
index 627c09fb8c8..79545ba35b3 100644
--- a/frameworks/CSharp/wiredio/Benchmarks/Benchmarks.csproj
+++ b/frameworks/CSharp/wiredio/Benchmarks/Benchmarks.csproj
@@ -13,7 +13,7 @@
linux-musl-x64
true
-
+
diff --git a/frameworks/CSharp/wiredio/Benchmarks/Program.cs b/frameworks/CSharp/wiredio/Benchmarks/Program.cs
index 8a41b222386..96330876bb5 100644
--- a/frameworks/CSharp/wiredio/Benchmarks/Program.cs
+++ b/frameworks/CSharp/wiredio/Benchmarks/Program.cs
@@ -29,4 +29,4 @@ await builder
.Type("application/json");
})
.Build()
- .RunAsync();
\ No newline at end of file
+ .RunAsync();