/// <inheritdoc /> private ProxiedTcpServerApplicationBase([NotNull] NetworkAddressInfo serverAddress, [NotNull] NetworkAddressInfo proxyToEndpointAddress, [NotNull] ILog logger, [NotNull] INetworkMessageDispatchingStrategy <TPayloadWriteType, TPayloadReadType> messageHandlingStrategy, [NotNull] PayloadHandlerRegisterationModules <TPayloadReadType, TPayloadWriteType> handlerModulePair, [NotNull] NetworkSerializerServicePair serializers) : base(serverAddress, messageHandlingStrategy, logger) { HandlerModulePair = handlerModulePair ?? throw new ArgumentNullException(nameof(handlerModulePair)); Serializers = serializers ?? throw new ArgumentNullException(nameof(serializers)); ProxyToEndpointAddress = proxyToEndpointAddress ?? throw new ArgumentNullException(nameof(proxyToEndpointAddress)); ServiceContainer = BuildServiceContainer(); }
/// <inheritdoc /> protected ProxiedTcpServerApplicationBase(NetworkAddressInfo listenerAddress, [NotNull] NetworkAddressInfo proxyToEndpointAddress, [NotNull] ILog logger, PayloadHandlerRegisterationModules <TPayloadReadType, TPayloadWriteType> handlerModulePair, NetworkSerializerServicePair serializers) : this(listenerAddress, proxyToEndpointAddress, logger, new InPlaceAsyncLockedNetworkMessageDispatchingStrategy <TPayloadWriteType, TPayloadReadType>(), handlerModulePair, serializers) { }
/// <inheritdoc /> public AuthenticationProxyApplicationBase(NetworkAddressInfo listenerAddress, [NotNull] NetworkAddressInfo proxyToEndpointAddress, [NotNull] ILog logger, PayloadHandlerRegisterationModules <AuthenticationClientPayload, AuthenticationServerPayload> handlerModulePair, NetworkSerializerServicePair serializers) : base(listenerAddress, proxyToEndpointAddress, logger, handlerModulePair, serializers) { }
/// <inheritdoc /> public WotlkGameProxyApplicationBase(NetworkAddressInfo listenerAddress, NetworkAddressInfo proxyToEndpointAddress, [NotNull] ILog logger, PayloadHandlerRegisterationModules <GamePacketPayload, GamePacketPayload> handlerModulePair, NetworkSerializerServicePair serializers) : base(listenerAddress, proxyToEndpointAddress, logger, handlerModulePair, serializers) { }
/// <inheritdoc /> public WotlkToVanillaProxyAppBase(NetworkAddressInfo listenerAddress, NetworkAddressInfo proxyToEndpointAddress, [NotNull] ILog logger, PayloadHandlerRegisterationModules <GamePacketPayload, GamePacketPayload> handlerModulePair, NetworkSerializerServicePair serializers) : base(listenerAddress, proxyToEndpointAddress, logger, handlerModulePair, serializers) { //TODO: Support .NET Core global exception handling AppDomain.CurrentDomain.UnhandledException += (sender, args) => { Exception e = args.ExceptionObject as Exception; Logger.Fatal($"Unhandled Exception: {e.GetType().Name} Message: {e.Message} \n\n Stack: {e.StackTrace}"); }; }