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

Command Processing Stage #152

Open
kushal0511-not opened this issue Mar 25, 2024 · 3 comments
Open

Command Processing Stage #152

kushal0511-not opened this issue Mar 25, 2024 · 3 comments

Comments

@kushal0511-not
Copy link

kushal0511-not commented Mar 25, 2024

I passed this stage(Command Processing Stage ) earlier now while running test for next stage it is again failing for Command processing stage
I have just added 1 line (conn.Write()) in case REPLCONF.
i tried without changing code , It passes sometimes but most of times it is failing.

remote: [replication-13] PSYNC ? -1 received.
remote: [replication-13] +FULLRESYNC 20lvbc0fgoe7n06a4slgtvgq1303t8506s6sc2pm 0 sent.
remote: [replication-13] RDB file sent.
remote: [replication-13] $ redis-cli SET foo 123
remote: [replication-13] $ redis-cli SET bar 456
remote: [replication-13] $ redis-cli SET baz 789
remote: [replication-13] Getting key foo
remote: [replication-13] $ redis-cli GET foo
remote: [replication-13] 123 received.
remote: [replication-13] Getting key bar
remote: [replication-13] $ redis-cli GET bar
remote: [replication-13] 
remote: [replication-13] Assertion failed, retrying... (Attempt 2/5)
remote: [replication-13] 
remote: [replication-13] $ redis-cli GET bar
remote: [replication-13] 
remote: [replication-13] Assertion failed, retrying... (Attempt 3/5)
remote: [replication-13] 
remote: [replication-13] $ redis-cli GET bar
remote: [replication-13] 
remote: [replication-13] Assertion failed, retrying... (Attempt 4/5)
remote: [replication-13] 
remote: [replication-13] $ redis-cli GET bar
remote: [replication-13] 
remote: [replication-13] Assertion failed, retrying... (Attempt 5/5)
remote: [replication-13] 
remote: [replication-13] $ redis-cli GET bar
remote: [replication-13] 
remote: [replication-13] resp: invalid syntax
remote: [replication-13] Test failed
remote: [replication-13] Terminating program
remote: [replication-13] Program terminated successfully
Copy link

linear bot commented Mar 25, 2024

@naqet
Copy link

naqet commented Mar 30, 2024

I have the same issue. Sometimes it passes and sometimes it doesn't (I use golang).

I use goroutines to accept connections and read messages and in case there is command that should be sent also to the replication server, I have another goroutine running waiting for channel to have value with command pushed in.

Every other test passes without any problems using this approach, but with this one I have been stuck for several hours now.

Also for some reason, sometimes the first SET command is not an ARRAY but a bulk string with some weird value.

image

@rohitpaulk
Copy link
Member

@naqet the bulk string there is the RDB file from the handshake, which should've been read before starting to listen for propagated commands. Looks like you eventually passed the stage, do you happen to remember what the issue was?

@kushal0511-not we've improved logs so you shouldn't see the cryptic "resp: invalid syntax" log anymore, you should see a more informative log.

Still think we can improve logs more here, will keep open until we've got that done

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

No branches or pull requests

3 participants