2

I see a way to configure the DefaultHost with BusConfiguration(), but do not see a way to configure the RemoteAppDomainHost programmatically (without using a rhino.esb config file section).

Randy Klingelheber
  • 947
  • 2
  • 9
  • 16

2 Answers2

0
var cashier = new RemoteAppDomainHost(typeof(CashierBootStrapper))
                .Configuration("Cashier.config");
cashier.Start();

See https://github.com/BjRo/LearningRhinoServiceBus

JarrettV
  • 18,845
  • 14
  • 46
  • 43
0

Override BeginStart from your bootstrapper and call UseConfiguration. Here's sample code that is working for me:

public class RemoteAppBootstrapper : AutofacBootStrapper
{
    protected override void OnBeginStart()
    {
        var busConfiguration = new HostConfiguration()
            .Bus( "msmq://localhost/endpoint.a" )
            .ToBusConfiguration();

        UseConfiguration( busConfiguration );

        base.OnBeginStart();
    }
}
Randy Klingelheber
  • 947
  • 2
  • 9
  • 16