NativeDatasetFactory parameter allocator and memory pool relationship
- Langage dominant
- Java
- Étoiles
- 94
- Forks
- 152
- Merge moyen
- 3 j 16 h
- PR mergées (30 j)
- 11
Description
### 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
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par le constructeur de NativeDatasetFactory présenté dans l’issue et suivez la manière dont BufferAllocator et NativeMemoryPool sont utilisés. Clarifiez leur relation dans la documentation de l’API Java, notamment ce que les contributors peuvent vérifier à partir du chemin d’allocation natif ; le travail est considéré comme terminé lorsque la question d’utilisation a reçu une réponse claire.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- java
- Domaine
- documentation
- Type d'issue
- Documentation
- Difficulté
- 2/5
- Temps estimé
- 1-3 heures
- Activité
- À l'abandon
- Clarté
- À clarifier
- Accessibilité débutants
- 25/100