Open cbucher opened 1 year ago
Hi @cbucher , thanks for bringing up this issue. Actually it was already reported before https://github.com/eBay/NuRaft/issues/349 and then forgotten.
I'd rather prefer changing it like this:
enum log_val_type : byte {
app_log = 1,
conf = 2,
cluster_server = 3,
log_pack = 4,
snp_sync_req = 5,
custom = 231,
};
given that 999 % 256 = 231
. Would you like to submit a PR? Or let me know if you want me to do it.
Hi,
Yes I will submit a PR.
Hi @greensky00 , I have submitted a PR #404
Best regards
We can see that the "custom" entrie of the log_val_type enum is set to 999. However, when this value is serialized, it is cast as 8bit unsigned integer which maximum value is 255.
Perhaps, the enum could be defined as :