[SERVER-28467] Sign range of times Created: 23/Mar/17  Updated: 06/Dec/17  Resolved: 06/Jun/17

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 3.5.9

Type: Task Priority: Major - P3
Reporter: Misha Tyulenev Assignee: Misha Tyulenev
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 2017-06-19
Participants:

 Description   

generate the signature that signs the range of times. so there is no need to generate it on every request.
e.g. if the current time is X than generate signature for X+100, and use it for all times X+1, X+2 ... X+100



 Comments   
Comment by Githook User [ 06/Jun/17 ]

Author:

{u'username': u'mikety', u'name': u'Misha Tyulenev', u'email': u'misha@mongodb.com'}

Message: SERVER-28467 sign range of times
Branch: master
https://github.com/mongodb/mongo/commit/d624abbb333ad8a3b414a110d88214b241387bad

Comment by Randolph Tan [ 19/May/17 ]

My proposal is to use bit masking to achieve this. So the idea is to use a constant value to mask the logical time to compute for hash:

const uint64_t kRangeMask = 0xFFFFF00000000000; // ~ 1hr & 32bit worth of increments
auto signature = computeHash(logicalTime | tRangeMask, key);

With this, we just need to decide how big the range is (rounded to next 2^n) and express it as a mask.

Generated at Thu Feb 08 04:18:13 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.