NSB7 startup error - Interface maps for generic interfaces on arrays cannot be retrived

sagas
nhibernate
nservicebus

(Gursharan Singh) #1

Hello,

We are upgrading an endpoint from NSB5 to NSB7. This endpoint has a Saga. We are using NHibernate persistence.

I get following exception when attempting to start the endpoint. The saga data does have many arrays in it.

System.ArgumentException: Interface maps for generic interfaces on arrays cannot be retrived.
   at System.RuntimeType.GetInterfaceMap(Type ifaceType)
   at NHibernate.Mapping.ByCode.TypeExtensions.<GetPropertyFromInterfaces>d__11.MoveNext()
   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)
   at NHibernate.Mapping.ByCode.SimpleModelInspector.NHibernate.Mapping.ByCode.IModelInspector.IsPersistentId(MemberInfo member)
   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source, Func`2 predicate)
   at NHibernate.Mapping.ByCode.SimpleModelInspector.MatchComponentPattern(Type subject)
   at NHibernate.Mapping.ByCode.ModelMapper.MapProperties(Type propertiesContainerType, IEnumerable`1 propertiesToMap, IPropertyContainerMapper propertiesContainer, PropertyPath path)
   at NHibernate.Mapping.ByCode.ModelMapper.MapRootClass(Type type, HbmMapping mapping)
   at NHibernate.Mapping.ByCode.ModelMapper.CompileMappingFor(IEnumerable`1 types)
   at NServiceBus.SagaPersisters.NHibernate.AutoPersistence.SagaModelMapper.Compile()
   at NServiceBus.SagaPersisters.NHibernate.AutoPersistence.SagaModelMapper.AddMappings(Configuration configuration, SagaMetadataCollection allSagaMetadata, IEnumerable`1 types, Func`2 tableNamingConvention)
   at System.Collections.Generic.List`1.ForEach(Action`1 action)
   at NServiceBus.Features.NHibernateStorageSession.Setup(FeatureConfigurationContext context)
   at NServiceBus.Features.FeatureActivator.ActivateFeature(FeatureInfo featureInfo, List`1 featuresToActivate, IConfigureComponents container, PipelineSettings pipelineSettings, RoutingComponent routing, ReceiveConfiguration receiveConfiguration)
   at NServiceBus.Features.FeatureActivator.SetupFeatures(IConfigureComponents container, PipelineSettings pipelineSettings, RoutingComponent routing, ReceiveConfiguration receiveConfiguration)
   at NServiceBus.InitializableEndpoint.<Initialize>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NServiceBus.Endpoint.<Start>d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()
   at Visa.Zaphod.MercuryInterface.Listener.NsbService.<AsyncStart>d__3.MoveNext() in C:\VisaOneTrack\Visa.Zaphod.MercuryInterface\NsbServer.MercuryInterface.Listener\NServicebus.cs:line 25
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Visa.Zaphod.MercuryInterface.Listener.NsbService.Start() in C:\VisaOneTrack\Visa.Zaphod.MercuryInterface\NsbServer.MercuryInterface.Listener\NServicebus.cs:line 13
   at Visa.Zaphod.MercuryInterface.Listener.Program.<>c.<Main>b__0_3(NsbService svc) in C:\VisaOneTrack\Visa.Zaphod.MercuryInterface\NsbServer.MercuryInterface.Listener\Program.cs:line 15
   at Topshelf.ServiceConfiguratorExtensions.<>c__DisplayClass2_0`1.<WhenStarted>b__0(T service, HostControl control)
   at Topshelf.Builders.DelegateServiceBuilder`1.DelegateServiceHandle.Start(HostControl hostControl)
   at Topshelf.Hosts.ConsoleRunHost.Run()

(Szymon Pobiega) #2

Hi

Could you include some bits of the saga data source code so that we can reproduce it?

Szymon


(Gursharan Singh) #3

Hi Szymon, I am a bit pressed for time to create a repro project. If you could send me a email then I can reply to you with source code. Thanks


(Szymon Pobiega) #4

Hi

Please send it to the support e-mail address and we’ll pick it up.

Szymon


(Gursharan Singh) #5

Thanks. I have sent an email to support.