void release() {
        synchronized (allBuffers) {
            checkState(allBuffers.isEmpty(), "Leaking buffers.");
        }
        partitionFileWriter.release();
    }
@Test
    void testRelease() {
        TieredStoragePartitionId partitionId =
                TieredStorageIdMappingUtils.convertId(new ResultPartitionID());
        int subpartitionId = 0;
        AtomicBoolean isReleased = new AtomicBoolean(false);
        TestingPartitionFileWriter partitionFileWriter =
                new TestingPartitionFileWriter.Builder()
                        .setReleaseRunnable(() -> isReleased.set(true))
                        .build();
        SubpartitionRemoteCacheManager cacheManager =
                new SubpartitionRemoteCacheManager(
                        partitionId,
                        subpartitionId,
                        new TestingTieredStorageMemoryManager.Builder().build(),
                        partitionFileWriter);
        cacheManager.release();
        assertThat(isReleased).isTrue();
    }