Skip to content

Commit 5d189ed

Browse files
authored
Merge pull request #421 from codecrafters-io/TropicolX-patch-66
Refactor handshake process descriptions in markdown
2 parents 27eedb7 + bee821a commit 5d189ed

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

stage_descriptions/replication-06-eh4.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
In this stage, you'll implement the second step of the replication handshake.
22

3-
### The Handshake Process (Recap)
3+
### Handshake (Recap)
44

5-
As a recap, there are three steps to the handshake process:
5+
As a recap, there are three steps to the handshake:
66

77
1. The replica sends a `PING` to the master (Handled in the previous stage)
88
2. The replica sends `REPLCONF` twice to the master
99
3. The replica sends `PSYNC` to the master
1010

11-
For this stage, you'll handle the second part of this process.
11+
For this stage, you'll handle the second step of this process.
1212

1313
### The `REPLCONF` Command
1414

@@ -17,7 +17,7 @@ The `REPLCONF` command is used to configure a connected replica. After receiving
1717
1. `REPLCONF listening-port <PORT>`: This tells the master which port the replica is listening on. This value is used for [monitoring and logging](https://github.com/redis/redis/blob/90178712f6eccf1e5b61daa677c5c103114bda3a/src/replication.c#L107-L130), not for replication itself.
1818
2. `REPLCONF capa psync2`: This notifies the master of the replica's capabilities.
1919
- `capa` stands for "capabilities". It indicates that the next argument is a feature the replica supports.
20-
- `psync2` signals that the replica supports the PSYNC 2.0 protocol, which is an improved version of the [partial synchronization](https://redis.io/docs/latest/operate/oss_and_stack/management/replication/) feature used to resynchronize a replica with its master.
20+
- `psync2` signals that the replica supports the PSYNC2 protocol. PSYNC2 is an improved version of the [partial synchronization](https://redis.io/docs/latest/operate/oss_and_stack/management/replication/) feature used to resynchronize a replica with its master.
2121
- You can safely hardcode `capa psync2` for now.
2222

2323
Both commands should be sent as RESP arrays, so the exact bytes will look something like this:

0 commit comments

Comments
 (0)