Skip to content

Commit dea506d

Browse files
committed
Merge branch 'master' of github.com:/sonus21/rqueue into spring-boot-auto-startup-delay
2 parents 7f8f337 + 0511a8c commit dea506d

1 file changed

Lines changed: 25 additions & 25 deletions

File tree

docs/migrations.md

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,31 @@ This guide outlines the configuration changes required when upgrading between ma
1111

1212
---
1313

14+
## Upgrading from 3.x to 4.x
15+
16+
RQueue 4.x switched from Jackson 2.x (`com.fasterxml.jackson`) to Jackson 3.x
17+
(`tools.jackson`). Jackson 3.x defaults to **alphabetical** JSON property ordering,
18+
while Jackson 2.x used **declaration order**. Messages enqueued by 3.x and messages
19+
enqueued by 4.x therefore have different byte representations in Redis.
20+
21+
The processing queue uses byte-exact lookups (ZSCORE/ZREM) to move or acknowledge
22+
messages. If stored bytes do not match the re-serialised bytes, the lookup silently
23+
fails and the message is repeatedly re-delivered via the visibility-timeout rescue path.
24+
25+
**If you are upgrading with messages still present in Redis**, set the following
26+
property to keep using declaration order (matching what 3.x stored):
27+
28+
```properties
29+
rqueue.serialization.property.order=DECLARATION
30+
```
31+
32+
{: .warning}
33+
After upgrading, changing `rqueue.serialization.property.order` away from
34+
its current value while messages are present in the processing queue will cause those
35+
messages to be unexpectedly retried. Drain the processing queue before switching values.
36+
37+
---
38+
1439
## Upgrading from 2.9.0 to 2.10+
1540

1641
Starting with version **2.10**, several configuration keys were renamed for consistency with the
@@ -73,28 +98,3 @@ ZCARD rqueue-processing::<queueName>
7398
7499
If all commands return **0**, your queues are empty and you can proceed with the
75100
migration without additional configuration.
76-
77-
---
78-
79-
## Upgrading from 3.x to 4.x
80-
81-
RQueue 4.x switched from Jackson 2.x (`com.fasterxml.jackson`) to Jackson 3.x
82-
(`tools.jackson`). Jackson 3.x defaults to **alphabetical** JSON property ordering,
83-
while Jackson 2.x used **declaration order**. Messages enqueued by 3.x and messages
84-
enqueued by 4.x therefore have different byte representations in Redis.
85-
86-
The processing queue uses byte-exact lookups (ZSCORE/ZREM) to move or acknowledge
87-
messages. If stored bytes do not match the re-serialised bytes, the lookup silently
88-
fails and the message is repeatedly re-delivered via the visibility-timeout rescue path.
89-
90-
**If you are upgrading with messages still present in Redis**, set the following
91-
property to keep using declaration order (matching what 3.x stored):
92-
93-
```properties
94-
rqueue.serialization.property.order=DECLARATION
95-
```
96-
97-
{: .warning}
98-
Changing `rqueue.serialization.property.order` while messages are present in the
99-
processing queue will cause those messages to be unexpectedly retried. Drain the processing
100-
queue before switching values.

0 commit comments

Comments
 (0)