以下是我尝试处理消息时收到的错误消息片段。有什么我想念的吗。
2013-02-28 09:17:35,362 [Worker.5] INFO NServiceBus.Unicast.UnicastBus [(null)] <(null)> - Received message AIS.TestApp.Messaging.GDataStatusResponse, AIS.TestApp.GCommon, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null with ID 7e7f5048-9f17-4d27-8499-42e92520ed42\32912973 from sender gca-gdata-service
2013-02-28 09:17:35,394 [Worker.5] ERROR NServiceBus.Unicast.UnicastBus [(null)]
<(null)> - ResponseHandler Failed handling message.
System.NullReferenceException: Object reference not set to an instance of an object.
at NServiceBus.Unicast.UnicastBus.<>c__DisplayClass10`1.<GetAction>b__f(Object o) in d:\BuildAgent-03\work\d692fe98ef9a76ca\src\unicast\NServiceBus.Unicast\UnicastBus.cs:line 909
at NServiceBus.ObjectBuilder.Common.CommonObjectBuilder.NServiceBus.ObjectBuilder.IBuilder.BuildAndDispatch(Type typeToBuild, Action`1 action) in d:\BuildAgent-03\work\d692fe98ef9a76ca\src\impl\ObjectBuilder.Common\ObjectBuilder.Common\C
ommonObjectBuilder.cs:line 117
这就是我在 IWantToRunAtStartup 的 Run 方法中初始化我的总线的方式
Configure.With()
.Log4Net()
.DefaultBuilder()
.XmlSerializer(NServiceBusCommon.XmlSerializerNamespace)
.MsmqTransport()
.UnicastBus()
.CreateBus()
.Start();
下面是我试图处理请求的代码
public class ResponseHandler : IHandleMessages<GDataStatusResponse>,
IHandleMessages<GDataReply>
{
public void Handle(GDataStatusResponse message)
{
....
}
}
如果您需要任何进一步的信息,请告诉我。
谢谢尼山特