antirez / disque

Disque is a distributed message broker
BSD 3-Clause "New" or "Revised" License
8.01k stars 537 forks source link

Contradiction in README about Job ID format #145

Closed vi closed 8 years ago

vi commented 8 years ago

Job IDs always start with "D-" and end with "$" and are always composed of exactly 42 characters. end with "$" $

identified by an ID like the following: D-dcb833cf-8YL1NT17e9+wsA/09NqxscQI-05a1

Where is the dollar sign?

justincase commented 8 years ago

The format changed in 71b9bdaab87db61bde45bbbac097118ef78fd0cd:

Last character was '$'. Given that this character is not selected by
normal GUIs with double click, it was unconfortable to select a Disque
ID with the mouse during development.

Moreover in a fixed len ID, the terminating character is not an important
feature, while the ability to have more reserved bits may turn to be
important. So '$' is now another byte reserved for the future. The final
two byes are now "AA" instead of "A$", however implementations should
never check the last two chars since they may change.

The final "AA"/"A$" sequence was recently dropped as well.

antirez commented 8 years ago

Thanks for the PR (no longer applies because of another older PR I applied). Indeed the doc was not updated with the recent changes in the implementation.