NativeDatasetFactory parameter allocator and memory pool relationship
- 主要語言
- Java
- 星號
- 94
- 分支
- 152
- 平均合併
- 3 天 16 小時
- 30 天內合併 PR
- 11
描述
### Describe the usage question you have. Please include as many useful details as possible.
@zhztheplayer
```
/**
* Constructor.
*
* @param allocator a context allocator associated with this factory. Any buffer that will be created natively will
* be then bound to this allocator.
* @param memoryPool the native memory pool associated with this factory. Any buffer created natively should request
* for memory spaces from this memory pool. This is a mapped instance of c++ arrow::MemoryPool.
* @param datasetFactoryId an ID, at the same time the native pointer of the underlying native instance of this
* factory. Make sure in c++ side the pointer is pointing to the shared pointer wrapping
* the actual instance so we could successfully decrease the reference count once
* {@link #close} is called.
* @see #close()
*/
public NativeDatasetFactory(BufferAllocator allocator, NativeMemoryPool memoryPool, long datasetFactoryId) {
this.allocator = allocator;
this.memoryPool = memoryPool;
this.datasetFactoryId = datasetFactoryId;
}
```
what's the relationship between allocator and memoryPool, does allocator allocate buffers from the memory pool or there is no such restrictions?
thanks
### Component(s)
Java
貢獻指南
研究方向
從 issue 中所示的 NativeDatasetFactory 建構函式開始,追蹤 BufferAllocator 和 NativeMemoryPool 的使用方式。在 Java API 文件中釐清它們之間的關係,包括 contributors 可以從 native 配置路徑中驗證的內容;當使用問題獲得清楚回答時,即表示完成。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- java
- 領域
- documentation
- Issue 類型
- 文件
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 活躍度
- 停滯
- 描述清晰度
- 需要釐清
- 新手友好度
- 25/100