Derek Collison
9ccd7abdf8
Test for preAcks
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-21 12:08:24 -07:00
Derek Collison
ed9de4b0a1
Improved publisher performance under some instances of asymmetric network latency clusters on interest based streams.
...
Under asymmetric network latency based clusters, if a node in an R3 was replicating a consumer and the parent stream, but was the leader of neither, but the path from the stream leader was faster then the consumer leader a replicated ack could arrive before the message itself.
In this case we used to forward a delete message request to the stream leader which would then replicate that to all stream replicas, causing more work which could lead to increased publisher times on clients connected to the slow node.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-20 20:53:45 -07:00
Derek Collison
0c1301ec14
Fix for data race
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-19 10:52:52 -07:00
Derek Collison
5a16f98427
Fixed an off by one bug that under certain circumstances could cause large consumer replica states.
...
This could lead to instability in the system.
The bug would manifest in replicated consumers when certain messages could be acked out of order, and, the pending list would never go to zero.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-19 10:41:59 -07:00
Derek Collison
027f2e42c8
Remove snapshot of cores and maxprocs
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-17 15:09:50 -07:00
Derek Collison
f0e1585490
Fix flapping test
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-17 13:14:43 -07:00
Neil Twigg
4647e14b3e
Don't recycle buffer more than once
2023-03-17 09:25:17 +00:00
Neil Twigg
9f99efad03
Use pooled buffer for flushing encrypted message blocks
2023-03-16 17:43:09 +00:00
Derek Collison
5bb6f167b9
Make sure to cleanup messages on a follower consumer for an interest based stream when the consumer leader sends a state snapshot.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-15 20:11:16 -07:00
Derek Collison
8dbfbbe577
Fix test
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-15 17:23:51 -07:00
Derek Collison
531fadd3e2
Don't warn if error is node closed.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-15 16:45:33 -07:00
Neil
c0784bc363
Merge pull request #3952 from nats-io/neil/fssdirty
...
Only mark fss dirty if a change is made
2023-03-15 09:25:11 +00:00
Waldemar Quevedo
da7a8b63bc
Reword ocsp routes/gateways terminology to 'peers' instead
...
Add test for verify_and_map usage with ocsp
Signed-off-by: Waldemar Quevedo <wally@nats.io >
2023-03-14 17:01:42 -07:00
Waldemar Quevedo
f8914788f5
Fix leaf client connection failing in ocsp setup
...
Signed-off-by: Waldemar Quevedo <wally@nats.io >
2023-03-14 14:07:18 -07:00
Derek Collison
5a1878b015
Fix for workqueue stream scaling up and not removing acked messages.
...
Make sure when scaling up streams that are workqueue or interest policy that consumers scale as well.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-13 17:13:49 -07:00
Neil Twigg
7105df5afc
Don't use string builder in subjString (it is slow)
2023-03-13 11:56:05 +00:00
Neil Twigg
1ead6df6f1
Only mark fss dirty if a change is made
2023-03-10 12:53:29 +00:00
Derek Collison
062dec7f5e
Added in error warning if stream or consumer delete fails.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-07 19:26:29 -05:00
Derek Collison
e0cbe503ed
Do not hold jetstream lock cleaning up orphans.
...
Could optionally deadlock.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-07 06:42:53 -05:00
Tomasz Pietrek
df282a221c
Fix Pull Consumer not sending request timeout
...
Server did check for timeouts in `processWaiting`,
but that needs to be also checked in `nextWaiting` in case of
tight timings, as `nextWaiting` can remove Pull Request based on
timeouts too.
Signed-off-by: Tomasz Pietrek <tomasz@nats.io >
2023-03-03 14:49:04 +01:00
Waldemar Quevedo
8f1ca99fb7
Fix flaky test TestMonitorJsz/raftgroups
...
Signed-off-by: Waldemar Quevedo <wally@nats.io >
2023-03-02 10:41:30 -08:00
Byron Ruth
ee4f1f85ba
Bump 2.9.16-beta
...
Signed-off-by: Byron Ruth <byron@nats.io >
2023-03-02 12:14:58 -05:00
Byron Ruth
92b93af06a
Release v2.9.15
...
Signed-off-by: Byron Ruth <byron@nats.io >
2023-03-02 11:56:38 -05:00
Derek Collison
c873cb38c0
Bump to 2.9.15-RC.4
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 23:20:26 -08:00
Derek Collison
2beca1a2a6
Partial cache errors are also not critical write errors
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 22:52:02 -08:00
Derek Collison
c07087c99d
Do metasnapshots optionally on quit and leader change, do not force.
...
Do not require force snapshots for all consumer deletes.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 22:46:29 -08:00
Derek Collison
f358bf2687
General improvements to the JetStream clustering layer during meta corruption.
...
We now check for orphaned streams or consumers in clustered mode after our metastate has recovered.
Do not warn on failures for installing raft snapshots if this is due to the node being closed.
During a stream update make sure to check to see if our group assignment has changed out from underneath of us.
Stream info should always delay if we are not the leader. Could cause duplicate responses when it should not.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 22:08:13 -08:00
Derek Collison
c586014477
General raft improvements under heavy corruption.
...
Do not exit candidate state in place when stepping down, would cause double vote requests.
When truncating our WAL make sure to adjust commit and applied as needed.
On a miss where the index is less than ours, if we can not find the entry reset our state.
For a vote, if last processed term is higher than ours always agree if no vote has been cast.
If terms are equal make sure the requestor's index is at least as high as ours.
If we decide not to vote for someone, and we have not voted and we are a better fit, move forward with a campaign.
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 22:06:50 -08:00
Derek Collison
deddf8f094
Fix since we have two streams and order in slice not guaranteed
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 07:58:01 -08:00
Derek Collison
ebe08040e9
Attempt to fix flapper again
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 06:24:51 -08:00
Derek Collison
baca7bd751
Fix for test flapper
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 04:58:01 -08:00
Derek Collison
9f1580686a
Revert behavior for JetStream published directly from client to be handled inline.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-03-01 04:35:52 -08:00
Derek Collison
8f7a88103b
Merge pull request #3926 from nats-io/fix-3924
...
[FIXED] Fix for MQTT Spec 4.7.2-1 violation
2023-02-28 21:58:24 -08:00
Derek Collison
d9933b1f7a
Fix for MQTT Spec 4.7.2-1
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 20:43:46 -08:00
Jeremy Saenz
26f241cb62
Updated LEAFZ names to use remoteServer name/id and added is_spoke
2023-02-28 18:09:24 -08:00
Derek Collison
95ed471866
Bump to 2.9.15-RC.3
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 14:56:56 -08:00
Derek Collison
321afe6aee
Merge pull request #3923 from nats-io/JMS-LeafZNames
...
Update LEAFZ to include leafnode server/connection name
2023-02-28 14:54:43 -08:00
Derek Collison
d920ca6319
Merge pull request #3922 from nats-io/stress-perf
...
[IMPROVED] Performance and Stability under heavy IO loads.
2023-02-28 14:49:36 -08:00
Derek Collison
1956fa3e23
Signal a metasnapshot for consumer deletes as well
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 14:30:23 -08:00
Derek Collison
724160ebac
Fix flapping tests
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 14:30:23 -08:00
Jeremy Saenz
9d4a603aaf
Update LEAFZ to include leafnode server/connection name
2023-02-28 14:20:18 -08:00
Derek Collison
bab10c1ecb
Revert closeAndKeepIndex behavior
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 13:39:24 -08:00
Derek Collison
68cd312870
Be more conservative on defaultMaxTotalCatchupOutBytes, default to 64M
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 13:28:09 -08:00
Derek Collison
24cb570646
Do not lock on stream name for consumer write state error
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 13:24:18 -08:00
Derek Collison
6bda358fa3
Fix tests that made assumptions about single server processing.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 13:24:18 -08:00
Derek Collison
3807441fd7
Always process inbound messages in separate execution context.
...
Do not duplicate work on leader, sealed and clustered state.
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 11:45:31 -08:00
Derek Collison
d85bec2007
Do not block in place on warning, and only warn if consumer not closed
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 11:45:31 -08:00
Derek Collison
adbb50fc21
Fixed dios capacity to 4 due to testing under heavy load.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 11:45:31 -08:00
Derek Collison
b19fe508c4
Do not block routes/gws on internal stream and consumer info requests
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 11:17:29 -08:00
Derek Collison
bee149b458
Only need server's rlock here.
...
Signed-off-by: Derek Collison <derek@nats.io >
2023-02-28 11:17:29 -08:00