diff --git a/src/fiskaltrust.Launcher.Common/Extensions/LoggerConfigurationExtensions.cs b/src/fiskaltrust.Launcher.Common/Extensions/LoggerConfigurationExtensions.cs index 03c739d9..5f13253c 100644 --- a/src/fiskaltrust.Launcher.Common/Extensions/LoggerConfigurationExtensions.cs +++ b/src/fiskaltrust.Launcher.Common/Extensions/LoggerConfigurationExtensions.cs @@ -25,7 +25,7 @@ public static LoggerConfiguration AddLoggingConfiguration(this LoggerConfigurati .MinimumLevel.Override("Microsoft.AspNetCore.HttpLogging.HttpLoggingMiddleware", aspLogging ? LogEventLevel.Information : LogEventLevel.Warning) .MinimumLevel.Override("System", LogEventLevel.Warning) .MinimumLevel.Override("Grpc", LogEventLevel.Warning) - .MinimumLevel.Override("ProtoBuf", LogEventLevel.Warning); + .MinimumLevel.Override("ProtoBuf", LogEventLevel.Error); return loggerConfiguration; } diff --git a/src/fiskaltrust.Launcher/Services/HostingService.cs b/src/fiskaltrust.Launcher/Services/HostingService.cs index 7380cc4d..af28d402 100644 --- a/src/fiskaltrust.Launcher/Services/HostingService.cs +++ b/src/fiskaltrust.Launcher/Services/HostingService.cs @@ -19,6 +19,7 @@ using System.Runtime.Versioning; using Microsoft.AspNetCore.Server.HttpSys; using System.Text.Json; +using fiskaltrust.ifPOS.v0; namespace fiskaltrust.Launcher.Services { @@ -249,6 +250,12 @@ private WebApplication CreateGrpcHost(WebApplicationBuilder builder, Uri uri, _logger.LogWarning($"{nameof(_launcherConfiguration.UseHttpSysBinding)} is not supported for grpc."); } + ProtoBuf.Meta.RuntimeTypeModel.Default.Add(typeof(IAsyncResult), true); + ProtoBuf.Meta.RuntimeTypeModel.Default.Add(typeof(AsyncCallback), true); + ProtoBuf.Meta.RuntimeTypeModel.Default.Add(typeof(Stream), true); + ProtoBuf.Meta.RuntimeTypeModel.Default.GetSchema(typeof(IPOS)); + ProtoBuf.Meta.RuntimeTypeModel.Default.Add(typeof(IPOS), true).AddSubType(1, typeof(ifPOS.v1.IPOS)); + builder.WebHost.BindKestrel(uri, listenOptions => ConfigureTls(listenOptions), false, HttpProtocols.Http2); builder.Services.AddCodeFirstGrpc(options => options.EnableDetailedErrors = true); builder.Services.AddSingleton(instance);