Open nayanranjane opened 10 months ago
hi
using one abp commertial here are sample steps to reproduce the issue services.AddApplication
I have legacy code which is using all the abp commertial version of 4.2 and I have created this as a shared project now I am using this shared project in .net 5 project which is working fine but when I try to use the same shared code in .net core 7 Project I am getting above error for backgroundJobs please advice
I can't reproduce the problem based on the information you provided.
Just want to know can we use entire abp.comertial version project which is in 4.2 can we use this all volo libraries in .net core 7
hi
All abp 4.2 packages target is net5.0
. I think you can't use it in net 7.
2024-09-05 17:53:19.067 +03:00 [ERR] An exception was thrown while activating Volo.Abp.BackgroundJobs.BackgroundJobStore. Autofac.Core.DependencyResolutionException: An exception was thrown while activating Volo.Abp.BackgroundJobs.BackgroundJobStore. ---> Autofac.Core.DependencyResolutionException: None of the constructors found on type 'Volo.Abp.BackgroundJobs.BackgroundJobStore' can be invoked with the available services and parameters: Cannot resolve parameter 'Volo.Abp.BackgroundJobs.IBackgroundJobRepository backgroundJobRepository' of constructor 'Void .ctor(Volo.Abp.BackgroundJobs.IBackgroundJobRepository, Volo.Abp.ObjectMapping.IObjectMapper`1[Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainModule])'.
See https://autofac.rtfd.io/help/no-constructors-bindable for more info.
at Autofac.Core.Activators.Reflection.ReflectionActivator.<>cDisplayClass14_0.1 next) at Autofac.Core.Resolving.Middleware.DisposalTrackingMiddleware.Execute(ResolveRequestContext context, Action
1 next)
at Autofac.Builder.RegistrationBuilder`3.<>cDisplayClass41_0.1 next) at Autofac.Builder.RegistrationBuilder
3.<>c__DisplayClass39_0.1 next) at Autofac.Core.Resolving.Middleware.CoreEventMiddleware.Execute(ResolveRequestContext context, Action
1 next)
at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action1 next) --- End of inner exception stack trace --- at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action
1 next)
at Autofac.Core.Resolving.Middleware.SharingMiddleware.Execute(ResolveRequestContext context, Action1 next) at Autofac.Core.Resolving.Middleware.CircularDependencyDetectorMiddleware.Execute(ResolveRequestContext context, Action
1 next)
at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, ResolveRequest& request)
at Autofac.Core.Resolving.ResolveOperation.ExecuteOperation(ResolveRequest& request)
at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider)
at Volo.Abp.BackgroundJobs.BackgroundJobWorker.DoWorkAsync(PeriodicBackgroundWorkerContext workerContext)
at Volo.Abp.BackgroundJobs.BackgroundJobWorker.DoWorkAsync(PeriodicBackgroundWorkerContext workerContext)
at Volo.Abp.BackgroundWorkers.AsyncPeriodicBackgroundWorkerBase.DoWorkAsync(CancellationToken cancellationToken)
2024-09-05 17:53:19.067 +03:00 [ERR] ---------- Exception Data ----------
ActivatorChain = Volo.Abp.BackgroundJobs.BackgroundJobStore
same error .. abp 8.2.0
@maliming @nayanranjane
hi @CodeOutput
Please create a new issue and share the details.
Thanks
An exception was thrown while activating Volo.Abp.BackgroundJobs.BackgroundJobStore -> Volo.Abp.ObjectMapping.DefaultObjectMapperb10(MethodInfo extensionMethod)
at System.Linq.Enumerable.WhereSelectArrayIterator 1()
at System.Lazy
1[[Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainModule, Volo.Abp.BackgroundJobs.Domain, Version=4.2.1.0, Culture=neutral, PublicKeyToken=null]] -> Volo.Abp.AutoMapper.AutoMapperAutoObjectMappingProvider
1[[Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainModule, Volo.Abp.BackgroundJobs.Domain, Version=4.2.1.0, Culture=neutral, PublicKeyToken=null]] -> ?:Volo.Abp.AutoMapper.IMapperAccessor -> ?:Volo.Abp.AutoMapper.MapperAccessor. Autofac.Core.DependencyResolutionException: An exception was thrown while activating Volo.Abp.BackgroundJobs.BackgroundJobStore -> Volo.Abp.ObjectMapping.DefaultObjectMapper1[[Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainModule, Volo.Abp.BackgroundJobs.Domain, Version=4.2.1.0, Culture=neutral, PublicKeyToken=null]] -> Volo.Abp.AutoMapper.AutoMapperAutoObjectMappingProvider
1[[Volo.Abp.BackgroundJobs.AbpBackgroundJobsDomainModule, Volo.Abp.BackgroundJobs.Domain, Version=4.2.1.0, Culture=neutral, PublicKeyToken=null]] -> ?:Volo.Abp.AutoMapper.IMapperAccessor -> ?:Volo.Abp.AutoMapper.MapperAccessor. ---> System.ArgumentException: GenericArguments[0], 'System.Guid', on 'T MaxIntegerT' violates the constraint of type 'T'. ---> System.Security.VerificationException: Method System.Linq.Enumerable.MaxInteger: type argument 'System.Guid' violates the constraint of type parameter 'T'. at System.RuntimeMethodHandle.GetStubIfNeeded(RuntimeMethodHandleInternal method, RuntimeType declaringType, RuntimeType[] methodInstantiation) at System.Reflection.RuntimeMethodInfo.MakeGenericMethod(Type[] methodInstantiation) --- End of inner exception stack trace --- at System.RuntimeType.ValidateGenericArguments(MemberInfo definition, RuntimeType[] genericArguments, Exception e) at System.Reflection.RuntimeMethodInfo.MakeGenericMethod(Type[] methodInstantiation) at AutoMapper.TypeDetails.<>cDisplayClass28_1.2.MoveNext() at System.Linq.Enumerable.ConcatIterator
1.MoveNext() at System.Linq.Enumerable.SelectManyIterator[TSource,TCollection,TResult](IEnumerable1 source, Func
2 collectionSelector, Func3 resultSelector)+MoveNext() at System.Linq.Enumerable.WhereSelectEnumerableIterator
2.MoveNext() at System.Collections.Generic.HashSet1.UnionWith(IEnumerable
1 other) at System.Linq.Enumerable.UnionIterator1.FillSet() at System.Linq.Enumerable.UnionIterator
1.ToArray() at AutoMapper.TypeDetails.BuildPublicNoArgExtensionMethods(IEnumerable1 sourceExtensionMethodSearch) at AutoMapper.TypeDetails..ctor(Type type, ProfileMap config) at AutoMapper.ProfileMap.TypeDetailsFactory(Type type) at AutoMapper.Internal.LockingConcurrentDictionary
2.<>cDisplayClass2_1.<.ctor>b1.ViaFactory(LazyThreadSafetyMode mode) at System.Lazy
1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor) at System.Lazy1.CreateValue() at AutoMapper.Internal.LockingConcurrentDictionary
2.GetOrAdd(TKey key) at AutoMapper.ProfileMap.CreateTypeDetails(Type type) at AutoMapper.TypeMapFactory.CreateTypeMap(Type sourceType, Type destinationType, ProfileMap options, Boolean isReverseMap) at AutoMapper.ProfileMap.BuildTypeMap(IConfigurationProvider configurationProvider, ITypeMapConfiguration config) at AutoMapper.ProfileMap.Register(IConfigurationProvider configurationProvider) at AutoMapper.MapperConfiguration.Seal() at AutoMapper.MapperConfiguration..ctor(MapperConfigurationExpression configurationExpression) at AutoMapper.MapperConfiguration..ctor(Action1 configure) at Volo.Abp.AutoMapper.AbpAutoMapperModule.CreateMappings(IServiceProvider serviceProvider) at Autofac.Extensions.DependencyInjection.AutofacRegistration.<>c__DisplayClass3_0.<Register>b__0(IComponentContext context, IEnumerable
1 parameters) at Autofac.Core.Activators.Delegate.DelegateActivator.ActivateInstance(IComponentContext context, IEnumerable1 parameters) at Autofac.Core.Activators.Delegate.DelegateActivator.<ConfigurePipeline>b__2_0(ResolveRequestContext ctxt, Action
1 next) at Autofac.Core.Resolving.Middleware.DisposalTrackingMiddleware.Execute(ResolveRequestContext context, Action1 next) at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action
1 next) --- End of inner exception stack trace --- at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action1 next) at Autofac.Core.Resolving.Middleware.SharingMiddleware.Execute(ResolveRequestContext context, Action
1 next) at Autofac.Core.Resolving.Middleware.CircularDependencyDetectorMiddleware.Execute(ResolveRequestContext context, Action1 next) at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, ResolveRequest request) at Autofac.Core.Resolving.ResolveOperation.ExecuteOperation(ResolveRequest request) at Autofac.Core.Resolving.ResolveOperation.Execute(ResolveRequest request) at Autofac.Core.Lifetime.LifetimeScope.ResolveComponent(ResolveRequest request) at Autofac.ResolutionExtensions.TryResolveService(IComponentContext context, Service service, IEnumerable
1 parameters, Object& instance) at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Service service, IEnumerable1 parameters) at Autofac.ResolutionExtensions.Resolve(IComponentContext context, Type serviceType, IEnumerable
1 parameters) at Autofac.ResolutionExtensions.Resolve(IComponentContext context, Type serviceType) at Autofac.Extensions.DependencyInjection.AutofacServiceProvider.GetRequiredService(Type serviceType) at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider) at Volo.Abp.BackgroundJobs.BackgroundJobWorker.DoWorkAsync(PeriodicBackgroundWorkerContext workerContext) at Volo.Abp.BackgroundWorkers.AsyncPeriodicBackgroundWorkerBase.DoWorkAsync()