Base solution for your next web application

Activities of "Jorahealth"

Any response? I would reaaly appreciate it if you could come back to me on this one quickly....

This is still not working for us and the app crashes after expriry of the token.

I had not replied earlier as I felt this issue would be addressed, Could you please suggest a solution or work around?

Many Thanks

  • What is your product version? 9.2.0
  • What is your product type (Angular or MVC)? Angular
  • What is product framework type (.net framework or .net core)? .NET CORE

Could we please get help with the following:

We are trying to integrate FCM pushnotification in Xamarin.forms app. It's works sucessfully in our ASP.NET ZERO Android project and sample iOS project but ** not with our ASP.NET ZERO iOS project. In the case of iOS, we are getting an exception, and not able to send notification. Could you please help us resolve this?

In the process we are able to generate the FCM token, but app is crashing when 'Allow pushnotification request permission' popup appears on device.
In "WebRequestExecuter.cs" class it handle the exception in "HandleDefaultException" method. The Exception is =>" An object reference is required for the non-static field, method, or property 'Decisively.Core.Threading.WebRequestExecuter.exception'." And Exception throws from Main.cs class file

Exception Log

at (wrapper managed-to-native) System.Threading.Thread.Abort_internal(System.Threading.InternalThread,object) at System.Threading.Thread.Abort () [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/mcs/class/corlib/System.Threading/Thread.cs:448 at Decisively.AppDelegate+<>c.<SetExitAction>b__3_0 () [0x00001] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.iOS/AppDelegate.cs:89 at Decisively.ViewModels.Base.UserConfigurationManager+<>c.<GetAsync>b__4_2 (System.Exception _) [0x00001] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.Shared/ViewModels/Base/UserConfigurationManager.cs:60 at Decisively.Core.Threading.WebRequestExecuter.HandleDefaultException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00140] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00300] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x00410] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleDefaultException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00117] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00300] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x00410] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleDefaultException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00117] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00300] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x00410] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleDefaultException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00117] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00300] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x00410] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleDefaultException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00117] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.HandleException[TResult] (System.Exception exception, System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback) [0x00300] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x00410] in <5fd16953003141bbb0bdead1209c5472>:0 at Decisively.ViewModels.Base.UserConfigurationManager.GetAsync (System.Func1[TResult] successCallback) [0x000da] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.Shared/ViewModels/Base/UserConfigurationManager.cs:40 at Decisively.ViewModels.Base.UserConfigurationManager.GetIfNeedsAsync () [0x00034] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.Shared/ViewModels/Base/UserConfigurationManager.cs:31 at Decisively.App.OnStart () [0x00051] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.Shared/App.xaml.cs:53 at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.<ThrowAsync>b__7_0 (System.Object state) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/Current/src/Xamarin.iOS/mcs/class/referencesource/mscorlib/system/runtime/compilerservices/AsyncMethodBuilder.cs:1021 at Foundation.NSAsyncSynchronizationContextDispatcher.Apply () [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/14.4.1.3/src/Xamarin.iOS/Foundation/NSAction.cs:178 at (wrapper managed-to-native) UIKit.UIApplication.UIApplicationMain(int,string[],intptr,intptr) at UIKit.UIApplication.Main (System.String[] args, System.IntPtr principal, System.IntPtr delegate) [0x00005] in /Library/Frameworks/Xamarin.iOS.framework/Versions/14.4.1.3/src/Xamarin.iOS/UIKit/UIApplication.cs:86 at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x0000e] in /Library/Frameworks/Xamarin.iOS.fraframework/Versions/14.4.1.3/src/Xamarin.iOS/UIKit/UIApplication.cs:65 at Decisively.Application.Main (System.String[] args) [0x00002] in /Users/aswanipu/Jora/aspnet-core/src/Decisively.Mobile.iOS/Main.cs:15

The process we followed to integrate the iOS app to FCM is as follows: Using Apple Developer account, we created an Id, with this iOS project bundle id we enabled pushnotification. We also created Provisional certificate and and installed in xcode. We are registerd our ASP.NET ZERO Xamarin iOS app in Firebase using bundle id and uploaded AuthKey certificate. From the app side, we enabled RemoteNotification and Background mode in info.plist file and also enabled Pushnotification in Entitlement.plist file. We added GoogleService-info.plist file to project and set the build action as BundleResource.

To check code, I have attached these to a share folderhere (please see attached AppDelegate.cs class file and UserNotificationCenterDelegate.cs file.)

Your help is much appreciated.

Many thanks in advance

Prerequisites

  • What is your product version? 9.2.0
  • What is your product type (Angular or MVC): Angular
  • What is product framework type (.net framework or .net core)? .Net Core

We started migrating to latest version to fix a Refresh token issue, We have noticed that style, layout and structure have changed when we have migrtaed from v8.9.2 to v9.2.0

How could we bring these changes easily to already created entities as the changes dont render correctly with old codes, do we need to manually chnage each line, whats the best way to get the old templates updated?

What is the best way to migrate exisiting entities created in old version to new 9.2.0 version with new style?**

The way the old entity renders!

Hi ismcagdas

I am adding screen shots of the application log ...where it says the refresh token is not valid! I have sent the token to the email as requested but have had no response?? Could you please provide a response for this?

Hi, Any updates on this, I had sent the token via email. Your support is greatly appreciated.

Hi ismcagdas I have sent this to the email....

The Access token validity is for a day, the refresh token 1 year, looks like the access token is not being renewed and the issue is with the refresh token. We reduced the refresh token expiry to 10 mins and then it automatically redirects to the login page on the mobile app.

I am pasting the full log....

Exception Log from Mobile

{Flurl.Http.FlurlHttpException: Call failed with status code 500 (Internal Server Error): POST http://10.0.2.2:22742/api/TokenAuth/RefreshToken at Flurl.Http.FlurlRequest.HandleExceptionAsync (Flurl.Http.HttpCall call, System.Exception ex, System.Threading.CancellationToken token) [0x00105] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x003a1] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x004bb] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.HttpResponseMessageExtensions.ReceiveJson[T] (System.Threading.Tasks.Task1[TResult] response) [0x0006e] in <7be22aadf26d4808b35d54cc18db202b>:0 at Decisively.ApiClient.AccessTokenManager.RefreshTokenAsync () [0x000a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\ApiClient\AccessTokenManager.cs:93 at Decisively.Configuration.UserConfigurationService.RefreshAccessTokenAndSendRequestAgain () [0x0003e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:63 at Decisively.Configuration.UserConfigurationService.GetAuthenticatedUserConfig () [0x00178] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:46 at Decisively.Configuration.UserConfigurationService.GetAsync (System.Boolean isUserLoggedIn) [0x00036] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:27 at Decisively.ViewModels.Base.UserConfigurationManager+<>c__DisplayClass4_0.<GetAsync>b__0 () [0x0002e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\ViewModels\Base\UserConfigurationManager.cs:41 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x002a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\Core\Threading\WebRequestExecuter.cs:53 }


API Error Log

INFO 2020-09-25 14:59:19,169 [94 ] Microsoft.AspNetCore.Hosting.Diagnostics - Request starting HTTP/1.1 POST http://localhost:22742/api/TokenAuth/RefreshToken?refreshToken=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1laWRlbnRpZmllciI6IjEiLCJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXR5L2NsYWltcy9uYW1lIjoiYWRtaW4iLCJBc3BOZXQuSWRlbnRpdHkuU2VjdXJpdHlTdGFtcCI6IktHU0pNNFMyNkc1QzVaU05FRUZKWU5KV1Q1M0JRU1JWIiwiaHR0cDovL3NjaGVtYXMubWljcm9zb2Z0LmNvbS93cy8yMDA4LzA2L2lkZW50aXR5L2NsYWltcy9yb2xlIjoiQWRtaW4iLCJodHRwOi8vd3d3LmFzcG5ldGJvaWxlcnBsYXRlLmNvbS9pZGVudGl0eS9jbGFpbXMvdGVuYW50SWQiOiIxNSIsInN1YiI6IjEiLCJqdGkiOiI3Mjg0NDZlNS00NWMwLTQxMzItOGY3My02OTY5ZWQzYWJjZGEiLCJpYXQiOjE2MDA5NTMwMDMsInRva2VuX3ZhbGlkaXR5X2tleSI6Ijk2ZTNhM2NjLTZmZGItNGU0MS04MzVmLTc3ZmZjNDRhZGUyZSIsInVzZXJfaWRlbnRpZmllciI6IjFAMTUiLCJ0b2tlbl90eXBlIjoiMSIsIm5iZiI6MTYwMDk1MzAwMywiZXhwIjoxNjMyNDg5MDAzLCJpc3MiOiJEZWNpc2l2ZWx5IiwiYXVkIjoiRGVjaXNpdmVseSJ9.IVAwaBWY5IGKkSxHo_pnl4LHlcMFbAvgTW0RkfkIciE application/json 247 INFO 2020-09-25 14:59:19,170 [94 ] uthentication.JwtBearer.JwtBearerHandler - Bearer was not authenticated. Failure message: No SecurityTokenValidator available for token: AIzaSyBd_YpujEtRhFD1cTA9zL9FcWyEV0qACJo INFO 2020-09-25 14:59:19,170 [94 ] ft.AspNetCore.Routing.EndpointMiddleware - Executing endpoint 'Decisively.Web.Controllers.TokenAuthController.RefreshToken (Decisively.Web.Core)' INFO 2020-09-25 14:59:19,191 [94 ] c.Infrastructure.ControllerActionInvoker - Route matched with {action = "RefreshToken", controller = "TokenAuth", area = ""}. Executing controller action with signature System.Threading.Tasks.Task1[Decisively.Authorization.Accounts.Dto.RefreshTokenResult] RefreshToken(System.String) on controller Decisively.Web.Controllers.TokenAuthController (Decisively.Web.Core). ERROR 2020-09-25 14:59:19,271 [9 ] Mvc.ExceptionHandling.AbpExceptionFilter - Refresh token is not valid! System.ComponentModel.DataAnnotations.ValidationException: Refresh token is not valid! ---> System.InvalidOperationException: Navigation property 'Claims' on entity of type 'User' cannot be loaded because the entity is not being tracked. Navigation properties can only be loaded for tracked entities. at Microsoft.EntityFrameworkCore.Internal.EntityFinder1.LoadAsync(INavigation navigation, InternalEntityEntry entry, CancellationToken cancellationToken) at Abp.Domain.Repositories.RepositoryExtensions.EnsureCollectionLoadedAsync[TEntity,TPrimaryKey,TProperty](IRepository2 repository, TEntity entity, Expression1 collectionExpression, CancellationToken cancellationToken) at Abp.Authorization.Users.AbpUserStore2.GetClaimsAsync(TUser user, CancellationToken cancellationToken) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserManager1.GetClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.GenerateClaimsAsync(TUser user) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory2.GenerateClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.CreateAsync(TUser user) at Abp.Authorization.AbpUserClaimsPrincipalFactory2.CreateAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 238 --- End of inner exception stack trace --- at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 250 at lambda_method(Closure , Object ) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.

The token is truncated

Hi @ismcagdas Exception Log from Mobile

{Flurl.Http.FlurlHttpException: Call failed with status code 500 (Internal Server Error): POST http://10.0.2.2:22742/api/TokenAuth/RefreshToken at Flurl.Http.FlurlRequest.HandleExceptionAsync (Flurl.Http.HttpCall call, System.Exception ex, System.Threading.CancellationToken token) [0x00105] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x003a1] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x004bb] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.HttpResponseMessageExtensions.ReceiveJson[T] (System.Threading.Tasks.Task1[TResult] response) [0x0006e] in <7be22aadf26d4808b35d54cc18db202b>:0 at Decisively.ApiClient.AccessTokenManager.RefreshTokenAsync () [0x000a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\ApiClient\AccessTokenManager.cs:93 at Decisively.Configuration.UserConfigurationService.RefreshAccessTokenAndSendRequestAgain () [0x0003e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:63 at Decisively.Configuration.UserConfigurationService.GetAuthenticatedUserConfig () [0x00178] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:46 at Decisively.Configuration.UserConfigurationService.GetAsync (System.Boolean isUserLoggedIn) [0x00036] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:27 at Decisively.ViewModels.Base.UserConfigurationManager+<>c__DisplayClass4_0.<GetAsync>b__0 () [0x0002e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\ViewModels\Base\UserConfigurationManager.cs:41 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x002a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\Core\Threading\WebRequestExecuter.cs:53 }


API Error Log

INFO 2020-09-25 14:59:19,169 [94 ] Microsoft.AspNetCore.Hosting.Diagnostics - Request starting HTTP/1.1 POST http://localhost:22742/api/TokenAuth/RefreshToken?refreshToken=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aX.IVAwaBWY5IGKkSxHo_pnl4LHlcMFbAvgTW0RkfkIciE application/json 247 INFO 2020-09-25 14:59:19,170 [94 ] uthentication.JwtBearer.JwtBearerHandler - Bearer was not authenticated. Failure message: No SecurityTokenValidator available for token: AIzaSyBd_YpujEtRhFD1cTA9zL9FcWyEV0qACJo INFO 2020-09-25 14:59:19,170 [94 ] ft.AspNetCore.Routing.EndpointMiddleware - Executing endpoint 'Decisively.Web.Controllers.TokenAuthController.RefreshToken (Decisively.Web.Core)' INFO 2020-09-25 14:59:19,191 [94 ] c.Infrastructure.ControllerActionInvoker - Route matched with {action = "RefreshToken", controller = "TokenAuth", area = ""}. Executing controller action with signature System.Threading.Tasks.Task1[Decisively.Authorization.Accounts.Dto.RefreshTokenResult] RefreshToken(System.String) on controller Decisively.Web.Controllers.TokenAuthController (Decisively.Web.Core). ERROR 2020-09-25 14:59:19,271 [9 ] Mvc.ExceptionHandling.AbpExceptionFilter - Refresh token is not valid! System.ComponentModel.DataAnnotations.ValidationException: Refresh token is not valid! ---> System.InvalidOperationException: Navigation property 'Claims' on entity of type 'User' cannot be loaded because the entity is not being tracked. Navigation properties can only be loaded for tracked entities. at Microsoft.EntityFrameworkCore.Internal.EntityFinder1.LoadAsync(INavigation navigation, InternalEntityEntry entry, CancellationToken cancellationToken) at Abp.Domain.Repositories.RepositoryExtensions.EnsureCollectionLoadedAsync[TEntity,TPrimaryKey,TProperty](IRepository2 repository, TEntity entity, Expression1 collectionExpression, CancellationToken cancellationToken) at Abp.Authorization.Users.AbpUserStore2.GetClaimsAsync(TUser user, CancellationToken cancellationToken) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserManager1.GetClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.GenerateClaimsAsync(TUser user) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory2.GenerateClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.CreateAsync(TUser user) at Abp.Authorization.AbpUserClaimsPrincipalFactory2.CreateAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 238 --- End of inner exception stack trace --- at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 250 at lambda_method(Closure , Object ) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Awaited|12_0(ControllerActionInvoker invoker, ValueTask`1 actionResultValueTask) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.

Exception Log from Mobile

{Flurl.Http.FlurlHttpException: Call failed with status code 500 (Internal Server Error): POST http://10.0.2.2:22742/api/TokenAuth/RefreshToken at Flurl.Http.FlurlRequest.HandleExceptionAsync (Flurl.Http.HttpCall call, System.Exception ex, System.Threading.CancellationToken token) [0x00105] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x003a1] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.FlurlRequest.SendAsync (System.Net.Http.HttpMethod verb, System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken, System.Net.Http.HttpCompletionOption completionOption) [0x004bb] in <7be22aadf26d4808b35d54cc18db202b>:0 at Flurl.Http.HttpResponseMessageExtensions.ReceiveJson[T] (System.Threading.Tasks.Task1[TResult] response) [0x0006e] in &lt;7be22aadf26d4808b35d54cc18db202b&gt;:0 at Decisively.ApiClient.AccessTokenManager.RefreshTokenAsync () [0x000a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\ApiClient\AccessTokenManager.cs:93 at Decisively.Configuration.UserConfigurationService.RefreshAccessTokenAndSendRequestAgain () [0x0003e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:63 at Decisively.Configuration.UserConfigurationService.GetAuthenticatedUserConfig () [0x00178] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:46 at Decisively.Configuration.UserConfigurationService.GetAsync (System.Boolean isUserLoggedIn) [0x00036] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Application.Client\Configuration\UserConfigurationService.cs:27 at Decisively.ViewModels.Base.UserConfigurationManager+&lt;&gt;c__DisplayClass4_0.&lt;GetAsync&gt;b__0 () [0x0002e] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\ViewModels\Base\UserConfigurationManager.cs:41 at Decisively.Core.Threading.WebRequestExecuter.Execute[TResult] (System.Func1[TResult] func, System.Func2[T,TResult] successCallback, System.Func2[T,TResult] failCallback, System.Action finallyCallback) [0x002a1] in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Mobile.Shared\Core\Threading\WebRequestExecuter.cs:53 }


API Error Log

INFO 2020-09-25 14:59:19,169 [94 ] Microsoft.AspNetCore.Hosting.Diagnostics - Request starting HTTP/1.1 POST http://localhost:22742/api/TokenAuth/RefreshToken?refreshToken=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJodHRwOi8vc2NoZW1hcy54bWxzb2FwLm9yZy93cy8yMDA1LzA1L2lkZW50aXeSJ9.IVAwaBWY5IGKkSxHo_pnl4LHlcMFbAvgTW0RkfkIciE application/json 247 INFO 2020-09-25 14:59:19,170 [94 ] uthentication.JwtBearer.JwtBearerHandler - Bearer was not authenticated. Failure message: No SecurityTokenValidator available for token: AIzaSyBd_YpujEtRhFD1cTA9zL9FcWyEV0qACJo INFO 2020-09-25 14:59:19,170 [94 ] ft.AspNetCore.Routing.EndpointMiddleware - Executing endpoint 'Decisively.Web.Controllers.TokenAuthController.RefreshToken (Decisively.Web.Core)' INFO 2020-09-25 14:59:19,191 [94 ] c.Infrastructure.ControllerActionInvoker - Route matched with {action = "RefreshToken", controller = "TokenAuth", area = ""}. Executing controller action with signature System.Threading.Tasks.Task1[Decisively.Authorization.Accounts.Dto.RefreshTokenResult] RefreshToken(System.String) on controller Decisively.Web.Controllers.TokenAuthController (Decisively.Web.Core). ERROR 2020-09-25 14:59:19,271 [9 ] Mvc.ExceptionHandling.AbpExceptionFilter - Refresh token is not valid! System.ComponentModel.DataAnnotations.ValidationException: Refresh token is not valid! ---> System.InvalidOperationException: Navigation property 'Claims' on entity of type 'User' cannot be loaded because the entity is not being tracked. Navigation properties can only be loaded for tracked entities. at Microsoft.EntityFrameworkCore.Internal.EntityFinder1.LoadAsync(INavigation navigation, InternalEntityEntry entry, CancellationToken cancellationToken) at Abp.Domain.Repositories.RepositoryExtensions.EnsureCollectionLoadedAsync[TEntity,TPrimaryKey,TProperty](IRepository2 repository, TEntity entity, Expression1 collectionExpression, CancellationToken cancellationToken) at Abp.Authorization.Users.AbpUserStore2.GetClaimsAsync(TUser user, CancellationToken cancellationToken) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserManager1.GetClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.GenerateClaimsAsync(TUser user) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory2.GenerateClaimsAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Microsoft.AspNetCore.Identity.UserClaimsPrincipalFactory1.CreateAsync(TUser user) at Abp.Authorization.AbpUserClaimsPrincipalFactory2.CreateAsync(TUser user) at Abp.Domain.Uow.UnitOfWorkInterceptor.InternalInterceptAsynchronous[TResult](IInvocation invocation) at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 238 --- End of inner exception stack trace --- at Decisively.Web.Controllers.TokenAuthController.RefreshToken(String refreshToken) in C:\Decisively_8.9.2\Solution\Decisively\aspnet-core\src\Decisively.Web.Core\Controllers\TokenAuthController.cs:line 250 at lambda_method(Closure , Object ) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.

Showing 11 to 20 of 43 entries