Ends in:
1 DAY
22 HRS
44 MIN
59 SEC
Ends in:
1 D
22 H
44 M
59 S
Open Closed

No 'Access-Control-Allow-Origin' header for Angular Application after input login details and click login. with Backend Deployed on windows server. #3465


User avatar
0
vipulbuoyancy created
  • ABP Framework version: v5.2.2
  • UI type: Angular
  • DB provider: EF Core
  • Tiered (MVC) or Identity Server Separated (Angular): no
  • Exception message and stack trace:
  • Steps to reproduce the issue:"

Hello,

I have deployed the abp .NET api application on windows server IIS. and abp Angular Application on Linux server using nginx and When I try to run and login in web. I input credentials username and password and click login button I show error

10.9.100.101/:1 Access to XMLHttpRequest at 'https://api.ubxcloud.net/api/abp/application-configuration' from origin 'http://10.9.100.101' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

Thanks


31 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    HI

    The appsettings.json has CorsOrigins settings, Did you add http://10.9.100.101 into it?

  • User Avatar
    0
    vipulbuoyancy created

    Hello

    I already added corsorigins in appsettings.json

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Thanks, Please share the logs of the backend app.

  • User Avatar
    0
    vipulbuoyancy created

    Hello @maliming

    2022-07-25 22:25:49.525 -07:00 [INF] Hosting environment: Production
    2022-07-25 22:25:49.525 -07:00 [INF] Content root path: C:\inetpub\wwwroot
    2022-07-25 22:25:49.559 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular Health Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.&lt;SendAsync&gt;g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-25 22:25:51.030 -07:00 [INF] CORS policy execution failed.
    2022-07-25 22:25:51.030 -07:00 [INF] Request origin http://10.9.100.101 does not have permission to access the resource.
    2022-07-25 22:25:51.450 -07:00 [INF] CORS policy execution successful.
    2022-07-25 22:25:51.746 -07:00 [INF] Invoking IdentityServer endpoint: IdentityServer4.Endpoints.DiscoveryEndpoint for /.well-known/openid-configuration
    2022-07-25 22:25:52.209 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/.well-known/openid-configuration - - - 200 - application/json;+charset=UTF-8 2786.4676ms
    2022-07-25 22:25:52.487 -07:00 [INF] Request starting HTTP/2 GET https://api.ubxcloud.net/.well-known/openid-configuration/jwks - -
    2022-07-25 22:25:52.491 -07:00 [INF] CORS policy execution failed.
    2022-07-25 22:25:52.491 -07:00 [INF] Request origin http://10.9.100.101 does not have permission to access the resource.
    2022-07-25 22:25:52.499 -07:00 [INF] CORS policy execution successful.
    2022-07-25 22:25:52.514 -07:00 [INF] Invoking IdentityServer endpoint: IdentityServer4.Endpoints.DiscoveryKeyEndpoint for /.well-known/openid-configuration/jwks
    2022-07-25 22:25:52.527 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/.well-known/openid-configuration/jwks - - - 200 - application/json;+charset=UTF-8 39.7694ms
    2022-07-25 22:25:52.847 -07:00 [INF] Request starting HTTP/2 GET https://api.ubxcloud.net/api/abp/application-configuration - -
    2022-07-25 22:25:52.848 -07:00 [INF] CORS policy execution failed.
    2022-07-25 22:25:52.848 -07:00 [INF] Request origin http://10.9.100.101 does not have permission to access the resource.
    2022-07-25 22:25:52.852 -07:00 [INF] No CORS policy found for the specified request.
    2022-07-25 22:25:52.896 -07:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc)'
    2022-07-25 22:25:52.914 -07:00 [INF] Route matched with {area = "abp", action = "Get", controller = "AbpApplicationConfiguration", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationDto] GetAsync() on controller Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController (Volo.Abp.AspNetCore.Mvc).
    2022-07-25 22:25:53.589 -07:00 [INF] Executing ObjectResult, writing value of type 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationDto'.
    2022-07-25 22:25:53.626 -07:00 [INF] Executed action Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc) in 706.6509ms
    2022-07-25 22:25:53.626 -07:00 [INF] Executed endpoint 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc)'
    2022-07-25 22:25:54.193 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/api/abp/application-configuration - - - 200 - application/json;+charset=utf-8 1345.9654ms
    2022-07-25 22:25:59.852 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-25 22:25:59.852 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-25 22:25:59.855 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular Health Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.&lt;SendAsync&gt;g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-25 22:25:59.860 -07:00 [INF] Notification is sent on same window time.
    
  • User Avatar
    0
    vipulbuoyancy created

    Hi @maliming,

    After taking a closer look, I have found that same api is returning the 200 Ok response before login, But after login it started throwing 500 error.

    Please have a look at attached image of headers. We can see that allow cors origin is not adding in header after login. Please help me.

    before login:

    after login:

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you try these changes?

    https://github.com/abpframework/abp/pull/13167/files

  • User Avatar
    0
    vipulbuoyancy created

    Should I update the latest version? Or just pull this specific commit?

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Update to the latest version or add the code below to your project:

    services.ConfigureApplicationCookie(options =>
    {
        options.ForwardDefaultSelector = ctx =>
        {
            string authorization = ctx.Request.Headers.Authorization;
            if (!authorization.IsNullOrWhiteSpace() && authorization.StartsWith("Bearer ", StringComparison.OrdinalIgnoreCase))
            {
                return "Bearer";
            }
    
            return null;
        };
    });
    
  • User Avatar
    0
    vipulbuoyancy created

    Hi,

    I have tried by adding the given code in host project, but getting the same error.

    Thanks.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)

    https://support.abp.io/QA/Questions/3448#answer-5f70c8df-651b-08ba-ec76-3a053289a6f4

    But after login it started throwing 500 error.

    What's the error detail?

  • User Avatar
    0
    vipulbuoyancy created

    Hi,

    https://support.abp.io/QA/Questions/3448#answer-5f70c8df-651b-08ba-ec76-3a053289a6f4

    This is fixed and it is working fine.

    Now, I am getting 500 Internal server error from the api (https://api.ubxcloud.net/api/abp/application-configuration) once I an logged in with the admin user.

    Thanks.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    500 Internal server

    Do you get new error logs?

  • User Avatar
    0
    vipulbuoyancy created

    Hello

    2022-07-26 03:02:19.234 -07:00 [INF] Notification is sent on same window time.
    2022-07-26 03:02:29.231 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:29.231 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:29.234 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular Health Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.&lt;SendAsync&gt;g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-26 03:02:29.235 -07:00 [INF] Notification is sent on same window time.
    2022-07-26 03:02:39.243 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:39.243 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:39.246 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular Health Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.&lt;ConnectAsync&gt;g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-26 03:02:39.247 -07:00 [INF] Notification is sent on same window time.
    2022-07-26 03:02:49.246 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:49.246 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 03:02:49.249 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular Health Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.&lt;SendAsync&gt;g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-26 03:02:49.250 -07:00 [INF] Notification is sent on same window time.
    

    Thanks

  • User Avatar
    0
    vipulbuoyancy created

    Hi,

    Do we need to host public application as well?

    Thanks

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    The logs your shared is not a application-configuration request.

  • User Avatar
    0
    vipulbuoyancy created

    hi

    2022-07-26 05:42:04.462 -07:00 [INF] Using the default authentication scheme Identity.Application for IdentityServer
    2022-07-26 05:42:04.994 -07:00 [INF] Initialized all ABP modules.
    2022-07-26 05:42:05.038 -07:00 [INF] Request starting HTTP/2 GET https://api.ubxcloud.net/api/abp/application-configuration - -
    2022-07-26 05:42:05.090 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 05:42:05.091 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 05:42:05.205 -07:00 [INF] Application started. Press Ctrl+C to shut down.
    2022-07-26 05:42:05.205 -07:00 [INF] Hosting environment: Production
    2022-07-26 05:42:05.205 -07:00 [INF] Content root path: C:\inetpub\wwwroot
    2022-07-26 05:42:05.257 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular_Health_Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.<ConnectAsync>g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.&lt;SendAsync&gt;g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-26 05:42:09.351 -07:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc)'
    2022-07-26 05:42:09.368 -07:00 [INF] Route matched with {area = "abp", action = "Get", controller = "AbpApplicationConfiguration", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationDto] GetAsync() on controller Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController (Volo.Abp.AspNetCore.Mvc).
    2022-07-26 05:42:10.137 -07:00 [INF] Executing ObjectResult, writing value of type 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.ApplicationConfigurationDto'.
    2022-07-26 05:42:10.194 -07:00 [INF] Executed action Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc) in 820.4837ms
    2022-07-26 05:42:10.195 -07:00 [INF] Executed endpoint 'Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations.AbpApplicationConfigurationController.GetAsync (Volo.Abp.AspNetCore.Mvc)'
    2022-07-26 05:42:12.248 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/api/abp/application-configuration - - - 200 - application/json;+charset=utf-8 7210.4039ms
    2022-07-26 05:42:12.266 -07:00 [INF] Request starting HTTP/2 GET https://api.ubxcloud.net/favicon.ico - -
    2022-07-26 05:42:12.284 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/favicon.ico - - - 302 - - 18.2481ms
    2022-07-26 05:42:13.022 -07:00 [INF] Request starting HTTP/2 GET https://api.ubxcloud.net/Error?httpStatusCode=404 - -
    2022-07-26 05:42:13.035 -07:00 [INF] Executing endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)'
    2022-07-26 05:42:13.052 -07:00 [INF] Route matched with {action = "Index", controller = "Error", area = "", page = ""}. Executing controller action with signature System.Threading.Tasks.Task`1[Microsoft.AspNetCore.Mvc.IActionResult] Index(Int32) on controller Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared).
    2022-07-26 05:42:13.087 -07:00 [INF] Executing ViewResult, running view ~/Views/Error/404.cshtml.
    2022-07-26 05:42:13.297 -07:00 [INF] Bundling __bundles/Lepton.Global.9AB45A4E53E8B50BAD5438EFEDDC5CD3.css (12 files)
    2022-07-26 05:42:13.389 -07:00 [INF]   > Minified /libs/abp/core/abp.css (1331 bytes -> 868 bytes)
    2022-07-26 05:42:13.431 -07:00 [INF]   > Minified /libs/@fortawesome/fontawesome-free/css/all.css (78193 bytes -> 53572 bytes)
    2022-07-26 05:42:13.450 -07:00 [INF]   > Minified /libs/@fortawesome/fontawesome-free/css/v4-shims.css (43484 bytes -> 33344 bytes)
    2022-07-26 05:42:13.472 -07:00 [INF]   > Minified /libs/malihu-custom-scrollbar-plugin/jquery.mCustomScrollbar.css (54850 bytes -> 43189 bytes)
    2022-07-26 05:42:13.555 -07:00 [INF]   > Minified /libs/datatables.net-bs5/css/dataTables.bootstrap5.css (13102 bytes -> 11190 bytes)
    2022-07-26 05:42:13.556 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/datatables/datatables-styles.css (464 bytes -> 379 bytes)
    2022-07-26 05:42:13.740 -07:00 [INF]   > Minified /global-styles.css (26 bytes -> 0 bytes)
    2022-07-26 05:42:13.741 -07:00 [INF] Bundled __bundles/Lepton.Global.9AB45A4E53E8B50BAD5438EFEDDC5CD3.css (499989 bytes)
    2022-07-26 05:42:13.981 -07:00 [INF] Bundling __bundles/Lepton.Global.9A9449B4A1BEC7DF689B1E3C3552F66F.js (34 files)
    2022-07-26 05:42:14.254 -07:00 [INF]   > Minified /libs/abp/core/abp.js (23299 bytes -> 9291 bytes)
    2022-07-26 05:42:14.383 -07:00 [INF]   > Minified /libs/jquery/jquery.js (271751 bytes -> 87726 bytes)
    2022-07-26 05:42:14.402 -07:00 [INF]   > Minified /libs/abp/jquery/abp.jquery.js (13253 bytes -> 5592 bytes)
    2022-07-26 05:42:14.405 -07:00 [INF]   > Minified /libs/bootstrap/js/bootstrap.enable.tooltips.everywhere.js (198 bytes -> 136 bytes)
    2022-07-26 05:42:14.406 -07:00 [INF]   > Minified /libs/bootstrap/js/bootstrap.enable.popovers.everywhere.js (195 bytes -> 136 bytes)
    2022-07-26 05:42:14.423 -07:00 [INF]   > Minified /libs/jquery-validation/jquery.validate.js (48695 bytes -> 23293 bytes)
    2022-07-26 05:42:14.428 -07:00 [INF]   > Minified /libs/jquery-validation-unobtrusive/jquery.validate.unobtrusive.js (19798 bytes -> 5604 bytes)
    2022-07-26 05:42:14.512 -07:00 [INF]   > Minified /libs/datatables.net/js/jquery.dataTables.js (469222 bytes -> 87545 bytes)
    2022-07-26 05:42:14.514 -07:00 [INF]   > Minified /libs/datatables.net-bs5/js/dataTables.bootstrap5.js (4850 bytes -> 2056 bytes)
    2022-07-26 05:42:14.522 -07:00 [INF]   > Minified /libs/abp/luxon/abp.luxon.js (1361 bytes -> 606 bytes)
    2022-07-26 05:42:14.525 -07:00 [INF]   > Minified /libs/timeago/jquery.timeago.js (7404 bytes -> 4107 bytes)
    2022-07-26 05:42:14.528 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/ui-extensions.js (10589 bytes -> 3026 bytes)
    2022-07-26 05:42:14.530 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/jquery/jquery-extensions.js (6610 bytes -> 2461 bytes)
    2022-07-26 05:42:14.532 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/jquery-form/jquery-form-extensions.js (3605 bytes -> 1588 bytes)
    2022-07-26 05:42:14.534 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/jquery/widget-manager.js (4790 bytes -> 1752 bytes)
    2022-07-26 05:42:14.536 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/bootstrap/dom-event-handlers.js (8710 bytes -> 4078 bytes)
    2022-07-26 05:42:14.537 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/bootstrap/modal-manager.js (6823 bytes -> 1887 bytes)
    2022-07-26 05:42:14.541 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/datatables/datatables-extensions.js (20337 bytes -> 6225 bytes)
    2022-07-26 05:42:14.542 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/sweetalert2/abp-sweetalert2.js (3213 bytes -> 1505 bytes)
    2022-07-26 05:42:14.543 -07:00 [INF]   > Minified /libs/abp/aspnetcore-mvc-ui-theme-shared/toastr/abp-toastr.js (951 bytes -> 342 bytes)
    2022-07-26 05:42:14.543 -07:00 [INF]   > Minified /Pages/Abp/MultiTenancy/tenant-switch.js (414 bytes -> 243 bytes)
    2022-07-26 05:42:14.546 -07:00 [INF]   > Minified /client-proxies/account-proxy.js (11411 bytes -> 7353 bytes)
    2022-07-26 05:42:14.553 -07:00 [INF]   > Minified /Pages/Account/LinkUsers/account-link-user-global.js (4774 bytes -> 2221 bytes)
    2022-07-26 05:42:14.555 -07:00 [INF]   > Minified /Themes/Lepton/Global/scripts/app.js (5718 bytes -> 3529 bytes)
    2022-07-26 05:42:14.556 -07:00 [INF] Bundled __bundles/Lepton.Global.9A9449B4A1BEC7DF689B1E3C3552F66F.js (733044 bytes)
    2022-07-26 05:42:14.566 -07:00 [INF] Executed ViewResult - view ~/Views/Error/404.cshtml executed in 1482.3014ms.
    2022-07-26 05:42:14.566 -07:00 [INF] Executed action Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared) in 1514.2692ms
    2022-07-26 05:42:14.566 -07:00 [INF] Executed endpoint 'Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Controllers.ErrorController.Index (Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared)'
    2022-07-26 05:42:14.568 -07:00 [INF] Request finished HTTP/2 GET https://api.ubxcloud.net/Error?httpStatusCode=404 - - - 404 - text/html;+charset=utf-8 1546.9434ms
    2022-07-26 05:42:15.548 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 05:42:15.548 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 05:42:15.551 -07:00 [ERR] GetHealthReport threw an exception when trying to get report from https://api.ubxcloud.net/health-status configured with name UBX_Client_Angular_Health_Status.
    System.Net.Http.HttpRequestException: No such host is known. (api.ubxcloud.net:443)
     ---> System.Net.Sockets.SocketException (11001): No such host is known.
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
       at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource.GetResult(Int16 token)
       at System.Net.Sockets.Socket.&lt;ConnectAsync&gt;g__WaitForConnectWithCancellation|277_0(AwaitableSocketAsyncEventArgs saea, ValueTask connectTask, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       --- End of inner exception stack trace ---
       at System.Net.Http.HttpConnectionPool.ConnectToTcpHostAsync(String host, Int32 port, HttpRequestMessage initialRequest, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.AddHttp11ConnectionAsync(HttpRequestMessage request)
       at System.Threading.Tasks.TaskCompletionSourceWithCancellation`1.WaitWithCancellationAsync(CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.GetHttp11ConnectionAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at System.Net.Http.HttpConnectionPool.SendWithVersionDetectionAndRetryAsync(HttpRequestMessage request, Boolean async, Boolean doRequestAuth, CancellationToken cancellationToken)
       at System.Net.Http.RedirectHandler.SendAsync(HttpRequestMessage request, Boolean async, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at Microsoft.Extensions.Http.Logging.LoggingScopeHttpMessageHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
       at System.Net.Http.HttpClient.<SendAsync>g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
       at HealthChecks.UI.Core.HostedService.HealthCheckReportCollector.GetHealthReportAsync(HealthCheckConfiguration configuration) in /_/src/HealthChecks.UI/Core/HostedService/HealthCheckReportCollector.cs:line 96
    2022-07-26 05:42:15.557 -07:00 [INF] Notification is sent on same window time.
    2022-07-26 05:42:25.591 -07:00 [INF] Start processing HTTP request GET "https://api.ubxcloud.net/health-status"
    2022-07-26 05:42:25.591 -07:00 [INF] Sending HTTP request GET "https://api.ubxcloud.net/health-status"`
    

    Thanks

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you set the environment to Production and test the app locally instead of IIS?

  • User Avatar
    0
    vipulbuoyancy created

    Hi

    I have tested on local by setting environment to production and it is working fine on local.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you share a simple project? liming.ma@volosoft.com I will test it on IIS

  • User Avatar
    0
    vipulbuoyancy created

    Hi

    Do we need https for angular project as well?

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    I'm not familiar with angular, but you can give it a try.

  • User Avatar
    0
    vipulbuoyancy created

    Hi

    I have mailed you the sample project.

    Thanks

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    I will check it asap. : )

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    I tested and it works correctly on my IIS. I think there may be a problem with your IIS environment.

  • User Avatar
    0
    vipulbuoyancy created

    Hi Maliming,

    Thank you for your reply. Did you checked login from the angular application? Swagger is working fine for me as well.

    Thank you.

Made with ❤️ on ABP v9.1.0-preview. Updated on December 02, 2024, 12:35