Closed mansai closed 3 years ago
Interesting. I haven't tried using AutoWrapper in combination of APIs and SignalR. Have you tried setting IsApiOnly
to false
and set the WrapWhenApiPathStartsWith
options?
app.UseApiResponseAndExceptionWrapper
is error
I custom a OptionBase:IgnorePath
app.UseApiResponseAndExceptionWrapper
Add code: WrapperBase.cs at line 63
var path = context.Request.Path.Value; if (_options.IgnorePath!=null && _options.IgnorePath== path) { await awm.WrapIgnoreAsync(context, bodyAsText); }
If you've added a custom option to ignore a specific path, you can just return instead of calling WrapIgnoreAsync
Is that so?
if (_options.IgnorePath!=null && _options.IgnorePath== path) { return; }
With the ExcludePath
option comes with the latest version, I think this should resolved your issue. See; https://vmsdurano.com/autowrapper-4-5-0-released/
Failed to start the connection: Error: None of the transports
public void Configure(IApplicationBuilder app, IWebHostEnvironment env) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); app.UseSwagger(); app.UseSwaggerUI(c => c.SwaggerEndpoint("/swagger/v1/swagger.json", "Solution1.WebAPI v1")); }