Interface CollectionMethods

All Superinterfaces:
ClientSettings, io.metaloom.qdrant.client.CommonSettings
All Known Subinterfaces:
QDrantGRPCClient
All Known Implementing Classes:
AbstractQDrantGRPCClient, QDrantGRPCClientImpl

public interface CollectionMethods extends ClientSettings
  • Method Details

    • listCollections

      Get list name of all existing collections.
      Returns:
    • loadCollections

      default GrpcClientRequest<Collections.GetCollectionInfoResponse> loadCollections(String collectionName)
      Get detailed information about specified existing collection
      Parameters:
      collectionName - Name of the collection to retrieve
      Returns:
    • createCollection

      Create new collection with given parameters.
      Parameters:
      collectionName - Name of the new collection
      params - Vector parameters for the new collection (e.g. dimension, method of distance computation)
      Returns:
    • createCollection

      default GrpcClientRequest<Collections.CollectionOperationResponse> createCollection(String collectionName, Collections.VectorParamsMap paramsMap)
    • createCollection

      default GrpcClientRequest<Collections.CollectionOperationResponse> createCollection(String collectionName, Collections.VectorsConfig config, Integer shardNumber, Integer replicationFactor, Integer writeConsistencyFactor, Boolean onDiskPayload, Collections.HnswConfigDiff hnswConfig, Collections.WalConfigDiff walConfig, Collections.OptimizersConfigDiff optimizersConfig, Integer timeout)
      Create new collection with given parameters.
      Parameters:
      collectionName - Name of the new collection
      config - Vector configuration for the new collection which contains vector params (e.g. dimension, method of distance computation)
      shardNumber - Number of shards in collection. Default is 1 for standalone, otherwise equal to the number of nodes Minimum is 1
      replicationFactor - Number of shards replicas. Default is 1 Minimum is 1
      writeConsistencyFactor - Defines how many replicas should apply the operation for us to consider it successful. Increasing this number will make the collection more resilient to inconsistencies, but will also make it fail if not enough replicas are available. Does not have any performance impact.
      onDiskPayload - If true - point's payload will not be stored in memory. It will be read from the disk every time it is requested. This setting saves RAM by (slightly) increasing the response time. Note: those payload values that are involved in filtering and are indexed - remain in RAM.
      hnswConfig - Custom params for HNSW index. If none - values from service configuration file are used.
      walConfig - Custom params for WAL. If none - values from service configuration file are used.
      optimizersConfig - Custom params for Optimizers. If none - values from service configuration file are used.
      timeout - Wait for operation commit timeout in seconds. If timeout is reached - request will return with service error.
      Returns:
    • deleteCollection

      default GrpcClientRequest<Collections.CollectionOperationResponse> deleteCollection(String collectionName, Integer timeout)
      Drop collection and all associated data
      Parameters:
      collectionName - Name of the collection to delete
      timeout - Wait for operation commit timeout in seconds. If timeout is reached - request will return with service error.
      Returns:
    • updateCollectionAliases

      default GrpcClientRequest<Collections.CollectionOperationResponse> updateCollectionAliases(List<? extends Collections.AliasOperations> actions, Integer timeout)
      Update aliases of the collections.
      Parameters:
      actions - Alias update operations (create,delete,rename)
      timeout - Wait for operation commit timeout in seconds. If timeout is reached - request will return with service error.
      Returns:
    • updateCollection

      Update parameters of the existing collection
      Parameters:
      collectionName - Name of the collection to update
      paramConfig - Collection base params. If none - values from service configuration file are used.
      Returns:
    • updateCollection

      default GrpcClientRequest<Collections.CollectionOperationResponse> updateCollection(String collectionName, Collections.CollectionParamsDiff paramConfig, Collections.OptimizersConfigDiff optimizerConfig, Integer timeout)
      Update parameters of the existing collection
      Parameters:
      collectionName - Name of the collection to update
      paramConfig - Collection base params. If none - values from service configuration file are used.
      optimizerConfig - Custom params for Optimizers. If none - values from service configuration file are used. This operation is blocking, it will only proceed ones all current optimizations are complete
      timeout - Wait for operation commit timeout in seconds. If timeout is reached - request will return with service error.
      Returns: