3 ms·
That 5 seconds is going to bite you. There is going to be some sort of stall in the future that causes all of your jobs to hit that 5 seconds and everything is
by latchkey 4y ago
That 5 seconds is going to bite you.
There is going to be some sort of stall in the future that causes all of your jobs to hit that 5 seconds and everything is going to start to back up and cause other problems up the line that are really hard to test for in advance.
You're better off designing a system that doesn't rely on some arbitrary number of seconds (why not 4 or 6 seconds?) to begin with.
- naasking 4y agoYes, non-determinism is the bane of distributed systems. It should be minimized whenever possible.
- convolvatron 4y agoin general I've been a lot more successful making fewer assumptions than trying to enforce them
- charrondev 4y agoThe system doesn’t rely on the 5s FWIW worth and is capable of running entirely through the distributed queue. The 5s check is just there to improve UX on small user actions.
- latchkey 4y agoLet's say that ALL of the jobs suddenly take up 6s. They ALL get queued up. Now you have a queue problem and you have more to debug. You have to figure out why the queue is filling up and why things are taking longer than 5s. You also have an issue where the execution might die (machine crashes) before the job makes it into a queue. You're better off just going straight to queue with the jobs and remove the added complexity of a 5s rule.