@ThreadSafe public class HsFileDataManager extends Object implements Runnable, BufferRecycler
HsSubpartitionFileReaderImpl
for
loading data w.r.t. their offset in the file.BufferRecycler.DummyBufferRecycler
Constructor and Description |
---|
HsFileDataManager(BatchShuffleReadBufferPool bufferPool,
ScheduledExecutorService ioExecutor,
HsFileDataIndex dataIndex,
Path dataFilePath,
HsSubpartitionFileReader.Factory fileReaderFactory,
HybridShuffleConfiguration hybridShuffleConfiguration) |
Modifier and Type | Method and Description |
---|---|
void |
deleteShuffleFile() |
void |
recycle(MemorySegment segment)
Recycles the
MemorySegment to its original BufferPool instance. |
HsDataView |
registerNewSubpartition(int subpartitionId,
HsSubpartitionViewInternalOperations operation)
This method only called by result partition to create subpartitionFileReader.
|
void |
release()
Releases this file data manager and delete shuffle data after all readers is removed.
|
void |
releaseSubpartitionReader(HsSubpartitionFileReader subpartitionFileReader)
Release specific
HsSubpartitionFileReader from HsFileDataManager . |
void |
run() |
void |
setup()
Setup read buffer pool.
|
public HsFileDataManager(BatchShuffleReadBufferPool bufferPool, ScheduledExecutorService ioExecutor, HsFileDataIndex dataIndex, Path dataFilePath, HsSubpartitionFileReader.Factory fileReaderFactory, HybridShuffleConfiguration hybridShuffleConfiguration)
public void setup()
public HsDataView registerNewSubpartition(int subpartitionId, HsSubpartitionViewInternalOperations operation) throws IOException
IOException
public void deleteShuffleFile()
public void releaseSubpartitionReader(HsSubpartitionFileReader subpartitionFileReader)
HsSubpartitionFileReader
from HsFileDataManager
.subpartitionFileReader
- to release.public void release()
public void recycle(MemorySegment segment)
BufferRecycler
MemorySegment
to its original BufferPool
instance.recycle
in interface BufferRecycler
segment
- The memory segment to be recycled.Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.