public void Setup(BenchmarkContext context) { _actorSystem = ActorSystem.Create("MessageDispatcher" + Counter.GetAndIncrement(), RemoteHocon); _systemAddress = RARP.For(_actorSystem).Provider.DefaultAddress; _inboundMessageDispatcherCounter = context.GetCounter(MessageDispatcherThroughputCounterName); _message = SerializedMessage.CreateBuilder().SetSerializerId(0).SetMessage(ByteString.CopyFromUtf8("foo")).Build(); _dispatcher = new DefaultMessageDispatcher(_actorSystem, RARP.For(_actorSystem).Provider, _actorSystem.Log); _targetActorRef = new BenchmarkActorRef(_inboundMessageDispatcherCounter, RARP.For(_actorSystem).Provider); }
public void Setup(BenchmarkContext context) { _actorSystem = ActorSystem.Create("MessageDispatcher" + Counter.GetAndIncrement(), RemoteHocon); _systemAddress = RARP.For(_actorSystem).Provider.DefaultAddress; _inboundMessageDispatcherCounter = context.GetCounter(MessageDispatcherThroughputCounterName); _message = new SerializedMessage { SerializerId = 0, Message = ByteString.CopyFromUtf8("foo") }; _dispatcher = new DefaultMessageDispatcher(_actorSystem.AsInstanceOf <ExtendedActorSystem>(), RARP.For(_actorSystem).Provider, _actorSystem.Log); _targetActorRef = new BenchmarkActorRef(_inboundMessageDispatcherCounter, RARP.For(_actorSystem).Provider); }
public static Props ReaderProps( Address localAddress, Address remoteAddress, AkkaProtocolTransport transport, RemoteSettings settings, AkkaPduCodec codec, IInboundMessageDispatcher dispatcher, bool inbound, int uid, ConcurrentDictionary<EndpointManager.Link, EndpointManager.ResendState> receiveBuffers, IActorRef reliableDeliverySupervisor = null) { return Props.Create( () => new EndpointReader(localAddress, remoteAddress, transport, settings, codec, dispatcher, inbound, uid, receiveBuffers, reliableDeliverySupervisor)) .WithDispatcher(settings.Dispatcher); }
public EndpointReader( Address localAddress, Address remoteAddress, AkkaProtocolTransport transport, RemoteSettings settings, AkkaPduCodec codec, IInboundMessageDispatcher msgDispatch, bool inbound, int uid, ConcurrentDictionary<EndpointManager.Link, EndpointManager.ResendState> receiveBuffers, IActorRef reliableDeliverySupervisor = null) : base(localAddress, remoteAddress, transport, settings) { _receiveBuffers = receiveBuffers; _msgDispatch = msgDispatch; Inbound = inbound; _uid = uid; _reliableDeliverySupervisor = reliableDeliverySupervisor; _codec = codec; _provider = RARP.For(Context.System).Provider; }