Exposes next permitted poll time on all valid polling responses
- All instances of
PortalJobStatusChangedexposes the next permitted poll time (getNextPermittedPollTime). - All instances of
DirectJobStatusResponsefor jobs created withstatusRetrievalMethodset toPOLLINGexposes the next permitted poll time (getNextPermittedPollTime).
Consumers of the library are expected to query this and schedule the next polling based on the response from the service.
See the documentation for direct jobs and portal jobs for examples on how to handle this.
Breaking changes
- Method
getNextPermittedPollTimeis removed fromTooEagerPollingException. Consumers should retrieve the next permitted poll time from the valid responses, as described above. By removing this we try to discourage exception driven logic. This exception should never be caught, schedule polling based on the valid responses instead. - Constants
NO_UPDATED_STATUSinDirectJobStatusResponseandPortalJobStatusChangedare removed. Use method.is(NO_CHANGES)on the instances to determine whether the queue was empty or not.