Question is solved. Approach with both dependent modules works fine.
Thank you.
Guys, I mentioned two issues. Second is fixed but the First one remains unfixed. Please read carefully.
I have updates for you. I have found that "AbpBootstrapper" works fine only if start module depends on the base "AbpEntityFrameworkCoreModule". All attempts to use higher modules like "AbpZeroCoreModule" or "DemoEntityFrameworkCore" or "DemoApplicationModule" failed with different exception messages. This means that my console app is unable to use my application infrastructure, services, not even my entity framework model.
This is the example of exception when i try to add dependency on the "AbpZeroCoreModule":
[DependsOn(typeof(AbpZeroCoreModule), typeof(AbpEntityFrameworkCoreModule))] public class MyConsoleModule : AbpModule
Value cannot be null. (Parameter 'value') at Abp.Zero.Configuration.AbpZeroEntityTypes.set_Tenant(Type value) at Abp.Zero.AbpZeroCommonModule.FillMissingEntityTypes() at Abp.Zero.AbpZeroCommonModule.Initialize() at Abp.Modules.AbpModuleManager.<>c.<StartModules>b__15_1(AbpModuleInfo module) at System.Collections.Generic.List1.ForEach(Action1 action) at Abp.Modules.AbpModuleManager.StartModules() at Abp.AbpBootstrapper.Initialize() at Pangea.Hub.Api.Grpc.Server.Console.Program.CreateHostBuilder(String[] args) in D:\Projects\A_Pangea\Sources\PangeaHub\Hub\Pangea.Hub.Api.Grpc.Server.Console\Program.cs:line 24
Here is the exception:
Castle.MicroKernel.Handlers.HandlerException: 'Can't create component 'Abp.BackgroundJobs.BackgroundJobStore' as it has dependencies to be satisfied.
'Abp.BackgroundJobs.BackgroundJobStore' is waiting for the following dependencies:
I have a Console application which creates an AbpBootstrapper instance and initializes it:
using (var bootstrapper = AbpBootstrapper.Create<MyModule>())
{
bootstrapper.Initialize();
}
MyModule is placed in a Class Library, derived from AbpModule and depends on a DemoApplicationModule:
[DependsOn(typeof(DemoApplicationModule))]
public class MyModule : AbpModule
{
public override void PreInitialize()
{
}
public override void Initialize()
{
IocManager.RegisterAssemblyByConvention(typeof(MyModule).GetAssembly());
}
}
DemoApplicationModule is the module from Demo.Application project.
This is all.
Issues with upgrades have been fixed by downloading latest sources from the Zero customer portal.
Hello guys, having the same task and the same issue. Link on ConsoleAppDemo returns 404. Do you have another link?