Exemplo n.º 1
0
 public MsSqlMessageConsumer(
     MsSqlMessagingGatewayConfiguration msSqlMessagingGatewayConfiguration,
     string topic, IMsSqlMessagingGatewayConnectionFactory connectionFactory)
 {
     _topic = topic ?? throw new ArgumentNullException(nameof(topic));
     _sqlQ  = new MsSqlMessageQueue <Message>(msSqlMessagingGatewayConfiguration, connectionFactory);
 }
Exemplo n.º 2
0
 /// <summary>
 ///     Initializes a new instance of the <see cref="MsSqlMessageQueue{T}" /> class.
 /// </summary>
 /// <param name="configuration"></param>
 public MsSqlMessageQueue(MsSqlMessagingGatewayConfiguration configuration, IMsSqlMessagingGatewayConnectionFactory connectionFactory)
 {
     _configuration     = configuration ?? throw new ArgumentNullException(nameof(configuration));
     _connectionFactory = connectionFactory;
     if (s_logger.IsEnabled(LogLevel.Debug))
     {
         s_logger.LogDebug("MsSqlMessageQueue({ConnectionString}, {QueueStoreTable})", _configuration.ConnectionString, _configuration.QueueStoreTable);
     }
     ContinueOnCapturedContext = false;
 }
Exemplo n.º 3
0
        private Publication _publication; // -- placeholder for future use

        public MsSqlMessageProducer(
            MsSqlMessagingGatewayConfiguration msSqlMessagingGatewayConfiguration,
            IMsSqlMessagingGatewayConnectionFactory connectionFactory,
            Publication publication = null)
        {
            _sqlQ        = new MsSqlMessageQueue <Message>(msSqlMessagingGatewayConfiguration, connectionFactory);
            _publication = publication ?? new Publication()
            {
                MakeChannels = OnMissingChannel.Create
            };
            MaxOutStandingMessages = _publication.MaxOutStandingMessages;
            MaxOutStandingCheckIntervalMilliSeconds = _publication.MaxOutStandingCheckIntervalMilliSeconds;
        }