GATEWAY-3180 subtask GATEWAY-3374: PD Deferred code and unit tests.