private void releaseSlot(LogicalSlot slot, Throwable cause) {
        requestedPhysicalSlots.removeKeyB(slot.getSlotRequestId());
        slotProvider.cancelSlotRequest(slot.getSlotRequestId(), cause);
    }
@Test
    void testLogicalSlotReleasingCancelsPhysicalSlotRequest() throws Exception {
        testLogicalSlotRequestCancellationOrRelease(
                true, true, (context, slotFuture) -> slotFuture.get().releaseSlot(null));
    }