1
0
mirror of https://github.com/taigrr/nats.docs synced 2025-01-18 04:03:23 -08:00

updates based on RI changes to README

This commit is contained in:
Ginger Collison 2021-02-05 15:12:28 -06:00 committed by GitHub
parent 2b6d217e37
commit 9d1e79110c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -30,16 +30,16 @@ The `WorkQueuePolicy` mode is a specialized mode where a message, once consumed
### Message Deduplication
JetStream support idempotent message writes by ignoring duplicate messages as indicated by the `Msg-Id` header.
JetStream support idempotent message writes by ignoring duplicate messages as indicated by the `Nats-Msg-Id` header.
```nohighlight
% nats req -H Msg-Id:1 ORDERS.new hello1
% nats req -H Msg-Id:1 ORDERS.new hello2
% nats req -H Msg-Id:1 ORDERS.new hello3
% nats req -H Msg-Id:1 ORDERS.new hello4
% nats req -H Nats-Msg-Id:1 ORDERS.new hello1
% nats req -H Nats-Msg-Id:1 ORDERS.new hello2
% nats req -H Nats-Msg-Id:1 ORDERS.new hello3
% nats req -H Nats-Msg-Id:1 ORDERS.new hello4
```
Here we set a `Msg-Id:1` header which tells JetStream to ensure we do not have duplicates of this message - we only consult the message ID not the body.
Here we set a `Nats-Msg-Id:1` header which tells JetStream to ensure we do not have duplicates of this message - we only consult the message ID not the body.
```nohighlight
$ nats str info ORDERS