NserviceBus启动事件

发布于 2024-11-30 15:29:19 字数 85 浏览 0 评论 0原文

我想在我的应用程序中使用 Ninject 配置依赖注入,并且我的项目是订阅者类库。 NserviceBus 为初始化内核和模块绑定而生成的第一个事件是什么?

I want to configure Dependency Injection with Ninject in my application, and my project is a Subscriber class library. What is the first event produced by NserviceBus for initialize my kernel and modules bindings?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

始终不够 2024-12-07 15:29:19

您需要做的是在 NServiceBus.Host.exe.config 中定义您的 EndpointConfigurationType

 <appSettings>
    <add key="EndpointConfigurationType" value="<Assembly>", <Namespace>"/>
  </appSettings> 

在此定义一个类之后

 public class EndpointConfiguration : AsA_Server, IWantCustomInitialization, IConfigureThisEndpoint     
 {
   public void Init()
   {
         /do Ninject stuff here
   }
 }

希望这是有意义的。如果您需要更多说明,请告诉我。祝你好运。

What you need to do is in NServiceBus.Host.exe.config define your EndpointConfigurationType

 <appSettings>
    <add key="EndpointConfigurationType" value="<Assembly>", <Namespace>"/>
  </appSettings> 

After this define a class

 public class EndpointConfiguration : AsA_Server, IWantCustomInitialization, IConfigureThisEndpoint     
 {
   public void Init()
   {
         /do Ninject stuff here
   }
 }

Hope this makes sense. Let me know if you need more clarification. Good luck.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文