Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] unstable from apache:unstable #88

Open
wants to merge 233 commits into
base: unstable
Choose a base branch
from

Conversation

pull[bot]
Copy link

@pull pull bot commented Mar 9, 2024

See Commits and Changes for more details.


Created by pull[bot]

Can you help keep this open source service alive? 💖 Please sponsor : )

Yangsx-1 and others added 30 commits March 9, 2024 22:41
Currently, we're missing the 'version', 'role', 'modules' in the HELLO command which may cause compatibility issue in some clients like Java lettuce:

```
Caused by: java.lang.IllegalArgumentException: Version must not be null
	at io.lettuce.core.internal.LettuceAssert.notNull(LettuceAssert.java:71)
	at io.lettuce.core.RedisHandshake$RedisVersion.<init>(RedisHandshake.java:333)
	at io.lettuce.core.RedisHandshake$RedisVersion.of(RedisHandshake.java:362)
	at io.lettuce.core.RedisHandshake.applyPostHandshake(RedisHandshake.java:249)
	at io.lettuce.core.RedisHandshake.lambda$initialize$0(RedisHandshake.java:99)
```

For the HELLO command response refer: https://redis.io/commands/hello/
refer #2159 (comment)

This PR is a temporary workaround for actions/runner-images#9491 to avoid
blocking the PR merged. Can revert the change once the image issue is resolved.
Signed-off-by: Mohammad Shehar Yaar Tausif <[email protected]>
Co-authored-by: 纪华裕 <[email protected]>
Co-authored-by: mwish <[email protected]>
Now actions/runner-images#9491 have been fixed and closed.
This revert is #2161. I've tested and everything works fine.
…and (#2196)

In Redis, it will add the migrating/importing slot section
for the source and target node. For the migrating source node,
it will contain the below section:

```
[{slot_id}->-{target_node_id}]
```

And for the importing node, it will add:

```
[{slot_id}-<-{source_node_id}]
```
c8ef and others added 30 commits August 27, 2024 19:17
…#2516)

This closes #2512.

Currently, the replication thread will wait for the worker's exclusive guard stop before closing db.
But it now stops the worker from running new commands after acquiring the worker's exclusive guard,
and it might cause deadlock if switches at the same time.

The following steps will show how it may happen:

- T0: client A sent `slaveof MASTER_IP0 MASTER_PORT0`, then the replication thread was started and waiting for the exclusive guard.

- T1: client B sent `slaveof MASTER_IP1 MASTER_PORT1` and `AddMaster` will stop the previous replication thread, which is waiting for the exclusive guard. But the exclusive guard is acquired by the current thread.

The workaround is also straightforward, just stop workers from running new commands by enabling `is_loading_` to 
true before acquiring the lock in the replication thread.
…2527)

Namespaces would store inside DB if the repl-namespace-enabled was set to yes.
Then replicas will intercept and parse the increment replication log to
see if it needs to reload namespaces. But it won't have the namespace update log
when doing the full sync, so we need to reload from DB once the full replication is done.
…ync (#2549)

Currently, the pre_fullsync_cb will stop the task runner and set the DB loading status to yes,
but it didn't resume those states. This will cause the server to run in restoring status until
success in resyncing from the master. To fix this, we need to call the post_fullsync_cb to resume those statuses
before restarting full sync.

This PR also uses try_lock to allow the replication thread to be stopped while preparing the restore db.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.