January 2018
Intermediate to advanced
332 pages
7h 36m
English
Endpoints fail, it's inevitable. Although we can try to resend failed messages, we need to realize at some point that there is an issue on our end and stop bombarding the server with requests to forward the messages. This is where priority queues can come in handy.
We will replace the existing logic to use a priority queue so that we detect when to stop trying to resend the message and notify the support team instead.
The biggest change is in the triggerFailureProtocol() method where we check whether the message has failed more times than the preset retryThreshold; if it has, then we add the message to the queue with critical priority, which we later use to prevent subsequent bombardment of the server ...
Read now
Unlock full access