当我尝试从测试项目发送消息时出现错误,这是异常消息
在 Rhino.ServiceBus.Impl.MessageOwnersSelector.GetEndpointForMessageBatch(Object[] messages) at Rhino.ServiceBus.Impl.DefaultServiceBus.Send(Object[] messages) at C2C.Infraestructura.Aspect 找不到 C2C.RhinoUtil.EventServiceBus 的消息所有者.EventDispatcherAspect.Intercept(IInvocation invocation) in f:\Proyectos\C2C\Desarrollo\Trunk\C2C.Infraestructura\Aspect\EventDispatcherAspect.cs:line 44
这是我的测试 app.config 的配置(这就像一个将消息发送到中央应用程序的客户端)
<rhino.esb>
<bus threadCount="1" numberOfRetries="5" endpoint="rhino.queues://localhost:50002/RhinoServiceBusTest" name="client" />
<messages>
<add name="messagges" endpoint="rhino.queues://localhost:50001/RhinoServiceBusBackend" />
</messages>
<assemblies>
<add assembly="Rhino.ServiceBus.RhinoQueues" />
</assemblies>
这是我的后端配置
<rhino.esb>
<bus threadCount="1" numberOfRetries="5" endpoint="rhino.queues://localhost:50001/RhinoServiceBusBackend" name="backend" />
<assemblies>
<add assembly="Rhino.ServiceBus.RhinoQueues" />
</assemblies>
这是我发送消息的代码的一部分
QueueUtil.PrepareQueue("client");
var host = new DefaultHost();
host.Start<ClientBootStrapper>();
//Console.WriteLine("Client 1: Hit enter to send message");
//Console.ReadLine();
var bus = host.Bus as IServiceBus;
var eventSB = new EventServiceBus();
eventSB.Nombre = methodName;
eventSB.Service = invocation.TargetType.FullName;
eventSB.Data = (arguments as BusinessEntity).UnProxy(); ;
try
{
bus.Send(eventSB);
}
catch (Exception)
{
throw;
}
基本上我拦截了所有交易并尝试通知另一个后端应用程序,但是
从我创建的测试方法