An exception was thrown while activating Castle.Proxies.NoticeApp ServiceProxy.

具体问题如下:

 

 An exception was thrown while activating Castle.Proxies.XXXApp

ServiceProxy.

Autofac.Core.DependencyResolutionException: An exception was thrown while activating Castle.Proxies.XXXAppServiceProxy.

 ---> Autofac.Core.DependencyResolutionException: None of the constructors found

 with 'Volo.Abp.Autofac.AbpAutofacConstructorFinder' on type 'Castle.Proxies.Not

iceAppServiceProxy' can be invoked with the available services and parameters:

Cannot resolve parameter

'Volo.Abp.Domain.Repositories.IRepository`2[SJ.ABP.XXXCenter.XXXs.XXX,System.Guid] repository' of constructor 'Void .ctor(Castle.DynamicProxy.IInterceptor[],

 Volo.Abp.Domain.Repositories.IRepository`2[SJ.ABP.XXXCenter.XXXs.XXX,System.Guid])'.

 

   at Autofac.Core.Activators.Reflection.ReflectionActivator.GetAllBindings(Cons

tructorBinder[] availableConstructors, IComponentContext context, IEnumerable`1

parameters)

   at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IC

omponentContext context, IEnumerable`1 parameters)

   at Autofac.Core.Activators.Reflection.ReflectionActivator.<ConfigurePipeline>

b__11_0(ResolveRequestContext ctxt, Action`1 next)

   at Autofac.Core.Resolving.Middleware.DisposalTrackingMiddleware.Execute(Resol

veRequestContext context, Action`1 next)

   at Autofac.Builder.RegistrationBuilder`3.<>c__DisplayClass41_0.<PropertiesAut

owired>b__0(ResolveRequestContext ctxt, Action`1 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, Action`1 next)

   at Autofac.Builder.RegistrationBuilder`3.<>c__DisplayClass35_0.<OnPreparing>b

__0(ResolveRequestContext ctxt, Action`1 next)

   at Autofac.Core.Resolving.Middleware.CoreEventMiddleware.Execute(ResolveReque

stContext context, Action`1 next)

   at Autofac.Core.Resolving.Middleware.SharingMiddleware.Execute(ResolveRequest

Context context, Action`1 next)

   at Autofac.Core.Resolving.Middleware.CircularDependencyDetectorMiddleware.Exe

cute(ResolveRequestContext context, Action`1 next)

   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifeti

meScope currentOperationScope, ResolveRequest request)

   at Autofac.Core.Resolving.ResolveOperation.ExecuteOperation(ResolveRequest re

quest)

   at Autofac.ResolutionExtensions.TryResolveService(IComponentContext context,

Service service, IEnumerable`1 parameters, Object& instance)

   at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Ser

vice service, IEnumerable`1 parameters)

   at Microsoft.AspNetCore.Mvc.Controllers.ServiceBasedControllerActivator.Creat

e(ControllerContext actionContext)

   at Microsoft.AspNetCore.Mvc.Controllers.ControllerFactoryProvider.<>c__Displa

yClass5_0.<CreateControllerFactory>g__CreateController|0(ControllerContext contr

ollerContext)

   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State

& next, Scope& scope, Object& state, Boolean& isCompleted)

   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeInne

rFilterAsync()

--- End of stack trace from previous location ---

   at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.<InvokeNextExcepti

onFilterAsync>g__Awaited|25_0(ResourceInvoker invoker, Task lastTask, State next

, Scope scope, Object state, Boolean isCompleted)

[21:43:28 ERR] ---------- Exception Data ----------

ActivatorChain = Castle.Proxies.XXXAppServiceProxy

 

 

 

解决方案:

如下图,缺少数据库对应表的映射,把相应的表增加进来就好了;

 

 

 

posted @   二维一加零  阅读(3030)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· DeepSeek “源神”启动!「GitHub 热点速览」
· 微软正式发布.NET 10 Preview 1:开启下一代开发框架新篇章
· C# 集成 DeepSeek 模型实现 AI 私有化(本地部署与 API 调用教程)
· DeepSeek R1 简明指南:架构、训练、本地部署及硬件要求
· NetPad:一个.NET开源、跨平台的C#编辑器
点击右上角即可分享
微信分享提示