You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 29, 2022. It is now read-only.
Copy file name to clipboardExpand all lines: docs/changelog.md
+10Lines changed: 10 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,16 @@
2
2
3
3
All notable changes to this library will be documented in this file.
4
4
5
+
## [4.2.0] - will be drafted
6
+
7
+
### Added
8
+
9
+
- Options that can allow configuring behaviour of re-queueing messages. New properties `RequeueTimeoutMilliseconds` and `RequeueAttempts` added to `RabbitMqExchangeOptions`.
10
+
11
+
### Changed
12
+
13
+
-**Breaking!** Now all `Send` or `SendAsync` methods of `IProducingService` (and `IQueueService`) with delay parameter use milliseconds instead of seconds.
Copy file name to clipboardExpand all lines: docs/exchange-configuration.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,6 +42,8 @@ And the `appsettings.json` file will be like this.
42
42
"AutoDelete": false,
43
43
"DeadLetterExchange": "default.dlx.exchange",
44
44
"RequeueFailedMessages": true,
45
+
"RequeueTimeoutMilliseconds": 200,
46
+
"RequeueAttempts": 2,
45
47
"Arguments": { "key": "value" },
46
48
"Queues": [
47
49
{
@@ -65,6 +67,8 @@ Exchanges can be configured with properties:
65
67
-`AutoDelete` - an option for exchange auto deleting. The default value is `false`.
66
68
-`Arguments` - a dictionary of additional arguments. The default value is `null`.
67
69
-`RequeueFailedMessages` - an option that specifies behaviour of re-queueing failed messages with certain delay through the dead-letter-exchange. The default value is `true`. The mechanism of sending delayed messages is covered in the [documentation](message-production.md).
70
+
-`RequeueTimeoutMilliseconds` - timeout in milliseconds after which the message will be re-queued. The default value is 200.
71
+
-`RequeueAttempts` - a number of attempts which queueing service will try to re-queue a message. The default value is 2.
68
72
-`DeadLetterExchange` - a value for dead-letter-exchange. The default value for the dead-letter-exchange name is `"default.dlx.exchange"`.
69
73
-`Queues` - a collection of queues bound to the exchange.
The message handling process is organized as follows:
306
+
The message handling process organized as follows:
307
307
308
308
-`IQueueMessage` receives a message and delegates it to `IMessageHandlingService`.
309
309
-`IMessageHandlingService` gets a message (as a byte array) and decodes it to the UTF8 string. It also checks if there are any message handlers in a combined collection of `IMessageHandler`, `IAsyncMessageHandler`, `INonCyclicMessageHandler` and `IAsyncNonCyclicMessageHandler` instances and forwards a message to them.
310
310
- All subscribed message handlers (`IMessageHandler`, `IAsyncMessageHandler`, `INonCyclicMessageHandler`, `IAsyncNonCyclicMessageHandler`) process the given message in a given or a default order.
311
311
-`IMessageHandlingService` acknowledges the message by its `DeliveryTag`.
312
-
- If any exception occurs `IMessageHandlingService` acknowledges the message anyway and checks if the message has to be re-send. If exchange option `RequeueFailedMessages` is set `true` then `IMessageHandlingService` adds a header `"requeued"` to the message and sends it again with delay in 60 seconds. Mechanism of sending delayed messages covered in the message production [documentation](message-production.md).
312
+
- If any exception occurs `IMessageHandlingService` acknowledges the message anyway and checks if the message has to be re-send. If exchange option `RequeueFailedMessages` is set `true` then `IMessageHandlingService` adds a header `"re-queue-attempts"` to the message and sends it again with delay in value of `RequeueTimeoutMilliseconds` (default is 200 milliseconds). The number of attempts is configurable and re-delivery will be made that many times as the value of `RequeueAttempts` property. Mechanism of sending delayed messages covered in the message production [documentation](message-production.md).
313
313
- If any exception occurs within handling the message that has been already re-sent that message will not be re-send again (re-send happens only once).
**Prerequisites.**Let's say that producer want to send a message to the exchange **"Exchange B"** with a routing key **"routing.key"**, and a delay in **30 seconds**.
119
+
**Prerequisites.**Let's say that producer want to send a message to the exchange **"Exchange B"** with a routing key **"routing.key"**, and a delay in **30 milliseconds**.
Copy file name to clipboardExpand all lines: readme.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -65,7 +65,7 @@ _queueService.Send(
65
65
@object: messageObject,
66
66
exchangeName: "exchange.name",
67
67
routingKey: "routing.key",
68
-
secondsDelay: 10);
68
+
millisecondsDelay: 10);
69
69
```
70
70
71
71
The mechanism of sending delayed messages described in the [documentation](./docs/message-production.md). Dive into it for more detailed information.
@@ -283,14 +283,14 @@ When the message collection is full to the size of `PrefetchCount` they are pass
283
283
284
284
## Advanced usage and nuances
285
285
286
-
RabbitMQ client implemented in this library (class which implements `IQueueService`) opens two connections to the RabbitMQ server. One connection is used for message production and the other one is for message consumption.
286
+
RabbitMQ client implemented in this library (class which implements `IQueueService`) opens two connections to the RabbitMQ server. One connection is used for message production, and the other one is for message consumption.
287
287
This behavior covered in the [advanced usage documentation file](./docs/advanced-usage.md), dive into it deeply if you want to control the client behavior tighter.
288
288
289
-
There is also an [example project](./examples/Examples.AdvancedConfiguration) that demonstrates an advances usage of the RabbitMQ client.
289
+
There is also an [example project](./examples/Examples.AdvancedConfiguration) that demonstrates an advanced usage of the RabbitMQ client.
290
290
291
291
## Changelog
292
292
293
-
All notable changes are being tracked in the [changelog](./docs/changelog.md) file.
293
+
All notable changes covered in the [changelog](./docs/changelog.md) file.
0 commit comments