-
Notifications
You must be signed in to change notification settings - Fork 69
Description
I'm trying to use SignalR.Orleans in my cluster but when ever i add this line i get a Cannot access a disposed object.
Object name: 'IServiceProvider'.
//this line
siloBuilder.AddMongoDBGrainStorage(SignalROrleansConstants.SIGNALR_ORLEANS_STORAGE_PROVIDER);
//stacktrace
at Microsoft.Extensions.DependencyInjection.ServiceLookup.ThrowHelper.ThrowObjectDisposedException()
at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider)
at Orleans.GrainReferences.GrainReferenceActivatorProvider.TryGet(GrainType grainType, GrainInterfaceType interfaceType, IGrainReferenceActivator& activator)
at Orleans.GrainReferences.GrainReferenceActivator.CreateActivator(GrainType grainType, GrainInterfaceType interfaceType)
at Orleans.GrainReferences.GrainReferenceActivator.CreateReference(GrainId grainId, GrainInterfaceType interfaceType)
at Orleans.GrainFactory.GetGrain(Type interfaceType, IdSpan grainKey, String grainClassNamePrefix)
at Orleans.GrainFactory.GetGrain[TGrainInterface](Int64 primaryKey, String grainClassNamePrefix)
at Orleans.Runtime.InternalClusterClient.GetGrain[TGrainInterface](Int64 primaryKey, String grainClassNamePrefix)
at Orleans.GrainFactoryExtensions.GetServerDirectoryGrain(IGrainFactory factory)
at SignalR.Orleans.OrleansHubLifetimeManager`1.Dispose()
at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.DisposeAsync()
--- End of stack trace from previous location ---
at Microsoft.Extensions.Hosting.Internal.Host.<g__DisposeAsync|16_0>d.MoveNext()
at Microsoft.Extensions.Hosting.Internal.Host.d__16.MoveNext()
at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.d__4.MoveNext()
at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Run(IHost host)
at Program.