hi @liangshiwei i have got it working now. Thank you very much for your kind help for the last few days. Much appreciated.
Nick
Hi @wazbek
Thank you for your kind help sir. Much appreciated.
I will try the distributed event bus from your advice.
Thank you so much again :)
Nick
Hi @wazbek,
thank you for your kind suggestion.
i have followed the sample app SignalRTieredDemo and that actually helps avoid the error since the Hub's constructor does not use those 2 parameters. however, i can only send messages out (from user A) but cannot receive such messages (to user B).
i am just wondering how you installed RabbitMQ locally, if you do not mind sharing please?
I have tried both docker image rabbitmq:latest and windows installation via chocolatey but i still have no luck.
sorry to bother you again. your kind response is greatly appreciated.
Nick
hi @liangshiwei
i have emailed you the source
Your help is greatly appreciated
Thanks
Nick
Hi @wazbek,
How are you?
I am (brand) new to ABP and have an issue SignalR-Chat-Hub-Dependency-Cannot-Be-Resolved similar to yours above and my EntityFrameworkCoreModule.cs file already has options.AddDefaultRepositories(includeAllEntities: true);
. However, Autofac still cannot resolve parameter 'Volo.Abp.Identity.IIdentityUserRepository' and 'Microsoft.AspNetCore.Identity.ILookupNormalizer' of constructor 'Void .ctor(Castle.DynamicProxy.IInterceptor[], Volo.Abp.Identity.IIdentityUserRepository, Microsoft.AspNetCore.Identity.ILookupNormalizer)' in the ChatHub.
I am just wondering if you could please give me some advice to solve this?
Besides, my Angular UI has CORS issues as well when it tries to hit the Chat hub on the (Razor) Web project. Could you please kindly share how you could overcome this in your solution (if you do not mind please)?
Thank you.
Nick
Check the docs before asking a question: https://docs.abp.io/en/commercial/latest/
Check the samples, to see the basic tasks: https://docs.abp.io/en/commercial/latest/samples/index
The exact solution to your question may have been answered before, please use the search on the homepage.
Details:
2020-08-31 11:54:33.262 +10:00 [ERR] Error when dispatching 'OnConnectedAsync' on hub. Autofac.Core.DependencyResolutionException: An exception was thrown while activating Castle.Proxies.ChatHubProxy. ---> Autofac.Core.DependencyResolutionException: None of the constructors found with 'Autofac.Core.Activators.Reflection.DefaultConstructorFinder' on type 'Castle.Proxies.ChatHubProxy' can be invoked with the available services and parameters: Cannot resolve parameter 'Volo.Abp.Identity.IIdentityUserRepository identityUserRepository' of constructor 'Void .ctor(Castle.DynamicProxy.IInterceptor[], Volo.Abp.Identity.IIdentityUserRepository, Microsoft.AspNetCore.Identity.ILookupNormalizer)'. at Autofac.Core.Activators.Reflection.ReflectionActivator.GetValidConstructorBindings(ConstructorInfo[] availableConstructors, IComponentContext context, IEnumerable
1 parameters)
at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable1 parameters) at Autofac.Core.Resolving.InstanceLookup.CreateInstance(IEnumerable
1 parameters)
--- End of inner exception stack trace ---
at Autofac.Core.Resolving.InstanceLookup.CreateInstance(IEnumerable1 parameters) at Autofac.Core.Resolving.InstanceLookup.Execute() at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, ResolveRequest request) at Autofac.Core.Resolving.ResolveOperation.Execute(ResolveRequest request) at Autofac.ResolutionExtensions.TryResolveService(IComponentContext context, Service service, IEnumerable
1 parameters, Object& instance)
at Autofac.ResolutionExtensions.ResolveOptionalService(IComponentContext context, Service service, IEnumerable1 parameters) at Autofac.ResolutionExtensions.ResolveOptional(IComponentContext context, Type serviceType, IEnumerable
1 parameters)
at Autofac.ResolutionExtensions.ResolveOptional(IComponentContext context, Type serviceType)
at Autofac.Extensions.DependencyInjection.AutofacServiceProvider.GetService(Type serviceType)
at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetService[T](IServiceProvider provider)
at Microsoft.AspNetCore.SignalR.Internal.DefaultHubActivator1.Create() at Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher
1.OnConnectedAsync(HubConnectionContext connection)
at Microsoft.AspNetCore.SignalR.Internal.DefaultHubDispatcher1.OnConnectedAsync(HubConnectionContext connection) at Microsoft.AspNetCore.SignalR.HubConnectionHandler
1.RunHubAsync(HubConnectionContext connection)
2020-08-31 11:54:33.359 +10:00 [INF] Executed endpoint '/signalr-hubs/chat'
2020-08-31 11:54:33.360 +10:00 [INF] Request finished in 296.7416ms 101 `Your kind help to resolve Volo.Abp.Identity.IIdentityUserRepository and Microsoft.AspNetCore.Identity.ILookupNormalizer (via Autofac) is greatly appreciated, please.
Thanks
Nick