server cleanup

This commit is contained in:
hamid
2026-06-16 01:46:53 +03:30
parent 69bbd28bb0
commit 5b4c0d183f
205 changed files with 641 additions and 628 deletions
@@ -0,0 +1,39 @@
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Http;
using Microsoft.Extensions.DependencyInjection;
using Baya.Web.Plugins.Grpc.Services;
namespace Baya.Web.Plugins.Grpc;
public static class GrpcPluginStartup
{
public static IServiceCollection ConfigureGrpcPluginServices(this IServiceCollection services)
{
services.AddGrpc();
services.AddGrpcReflection();
return services;
}
public static void ConfigureGrpcPipeline(this WebApplication app)
{
app.MapGrpcService<UserGrpcServices>();
app.MapGrpcService<OrderGrpcServices>();
app.MapGrpcReflectionService();
app.MapGet("/GrpcUser", async context =>
{
await context.Response.WriteAsync(
"Communication with this gRPC endpoint must be made through a gRPC client.");
});
app.MapGet("/GrpcUserOrder", async context =>
{
await context.Response.WriteAsync(
"Communication with this gRPC endpoint must be made through a gRPC client.");
});
}
}