/// <summary> /// Initializes a new instance of the <see cref="RestMsMessageConsumer"/> class. /// </summary> /// <param name="configuration">The configuration of the RestMS broker</param> /// <param name="queueName">Name of the queue.</param> /// <param name="routingKey">The routing key.</param> public RestMsMessageConsumer(RestMSMessagingGatewayConfiguration configuration, string queueName, string routingKey) : base(configuration) { _queueName = queueName; _routingKey = routingKey; _feed = new Feed(this); _domain = new Domain(this); }
public RestMsMessageProducerSendTests() { var configuration = new RestMSMessagingGatewayConfiguration { Feed = new Feed { Name = "test", Type = "Default"}, RestMS = new RestMsSpecification { Uri = new Uri("http://localhost:3416/restms/domain/default"), Id = "dh37fgj492je", User ="******", Key ="wBgvhp1lZTr4Tb6K6+5OQa1bL9fxK7j8wBsepjqVNiQ=", Timeout=2000} }; _messageProducer = new RestMsMessageProducer(configuration); _messageConsumer = new RestMsMessageConsumer(configuration, QueueName, Topic); _message = new Message(new MessageHeader(Guid.NewGuid(), Topic, MessageType.MT_COMMAND), new MessageBody("test content")); }
/// <summary> /// Initializes a new instance of the <see cref="T:System.Object" /> class. /// <param name="configuration">The configuration to use with RestMS.</param> /// </summary> public RestMSMessageGateway(RestMSMessagingGatewayConfiguration configuration) { Configuration = configuration; _timeout = Configuration.RestMS.Timeout; }
/// <summary> /// Initializes a new instance of the <see cref="RestMsMessageProducer"/> class. /// <param name="configuration">The configuration of the RestMS broker we need to contact</param> /// </summary> public RestMsMessageProducer(RestMSMessagingGatewayConfiguration configuration) : base(configuration) { _feed = new Feed(this); _domain = new Domain(this); }
/// <summary> /// Initializes a new instance of the <see cref="RestMsMessageConsumer"/> class. /// </summary> /// <param name="configuration">The configuration of the RestMS broker</param> /// <param name="queueName">Name of the queue.</param> /// <param name="routingKey">The routing key.</param> public RestMsMessageConsumer(RestMSMessagingGatewayConfiguration configuration, string queueName, string routingKey) : this(configuration, queueName, routingKey, LogProvider.For <RestMsMessageConsumer>()) { }
/// <summary> /// Initializes a new instance of the <see cref="RestMsMessageProducer"/> class. /// </summary> public RestMsMessageProducer(RestMSMessagingGatewayConfiguration configuration) : this(configuration, LogProvider.For <RestMsMessageProducer>()) { }
/// <summary> /// Initializes a new instance of the <see cref="T:System.Object" /> class. /// Use this if you need to provide the logger, for example for testing /// </summary> /// <param name="configuration">The configuration to use with RestMS.</param> /// <param name="logger">The logger.</param> public RestMSMessageGateway(RestMSMessagingGatewayConfiguration configuration, ILog logger) { Configuration = configuration; Logger = logger; _timeout = Configuration.RestMS.Timeout; }
/// <summary> /// Initializes a new instance of the <see cref="T:System.Object" /> class. /// <param name="configuration">The configuration to use with RestMS.</param> /// </summary> public RestMSMessageGateway(RestMSMessagingGatewayConfiguration configuration) : this(configuration, LogProvider.For <RestMSMessageGateway>()) { }