Exemple #1
0
        public override void CustomizeEndpoint(EndpointConfiguration endpointConfig, TransportSettings transportSettings)
        {
            var transport = endpointConfig.UseTransport <SqlServerTransport>();

            ConfigureConnection(transport, transportSettings);

            if (transportSettings.GetOrDefault <bool>("TransportSettings.EnableDtc"))
            {
                Logger.Error("The EnableDtc setting is no longer supported natively within ServiceControl. If you require distributed transactions, you will have to use a Transport Adapter (https://docs.particular.net/servicecontrol/transport-adapter/)");
            }

            transport.Transactions(TransportTransactionMode.SendsAtomicWithReceive);
        }
Exemple #2
0
        public override void CustomizeEndpoint(EndpointConfiguration endpointConfig, TransportSettings transportSettings)
        {
            var transport = endpointConfig.UseTransport <SqlServerTransport>();

            ConfigureConnection(transport, transportSettings);

            if (transportSettings.GetOrDefault <bool>("TransportSettings.EnableDtc"))
            {
                Logger.Error("The EnableDtc setting is no longer supported natively within ServiceControl. If you require distributed transactions, you will have to use a Transport Adapter (https://docs.particular.net/servicecontrol/transport-adapter/)");
            }

            endpointConfig.GetSettings().Set("SqlServer.DisableDelayedDelivery", true);
            var sendOnlyEndpoint = transport.GetSettings().GetOrDefault <bool>("Endpoint.SendOnly");

            if (!sendOnlyEndpoint)
            {
                transport.NativeDelayedDelivery().DisableTimeoutManagerCompatibility();
            }
            transport.Transactions(TransportTransactionMode.SendsAtomicWithReceive);
        }