mirror of
https://github.com/qdrant/landing_page.git
synced 2026-10-09 12:58:31 +02:00
Read-write contention troubleshooting guide (#2421)
* New r/w contention troubleshooting guide * Add snippet to low latency search guide * Add FAQ entry * Add 'Read More' section to guide
This commit is contained in:
+7
@@ -0,0 +1,7 @@
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"hnsw_config": {
|
||||
"max_indexing_threads": 4
|
||||
}
|
||||
}'
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
public class Snippet
|
||||
{
|
||||
public static async Task Run()
|
||||
{
|
||||
var client = new QdrantClient("localhost", 6334); // @hide
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
hnswConfig: new HnswConfigDiff { MaxIndexingThreads = 4 }
|
||||
);
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```bash
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"hnsw_config": {
|
||||
"max_indexing_threads": 4
|
||||
}
|
||||
}'
|
||||
```
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```csharp
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
hnswConfig: new HnswConfigDiff { MaxIndexingThreads = 4 }
|
||||
);
|
||||
```
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
```go
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
HnswConfig: &qdrant.HnswConfigDiff{
|
||||
MaxIndexingThreads: qdrant.PtrOf(uint64(4)),
|
||||
},
|
||||
})
|
||||
```
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
```java
|
||||
import io.qdrant.client.grpc.Collections.HnswConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setHnswConfig(
|
||||
HnswConfigDiff.newBuilder().setMaxIndexingThreads(4).build())
|
||||
.build())
|
||||
.get();
|
||||
```
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
```python
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
hnsw_config=models.HnswConfigDiff(max_indexing_threads=4),
|
||||
)
|
||||
```
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
```rust
|
||||
use qdrant_client::qdrant::{HnswConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}")
|
||||
.hnsw_config(HnswConfigDiffBuilder::default().max_indexing_threads(4)),
|
||||
)
|
||||
.await?;
|
||||
```
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
```typescript
|
||||
client.updateCollection("{collection_name}", {
|
||||
hnsw_config: {
|
||||
max_indexing_threads: 4,
|
||||
},
|
||||
});
|
||||
```
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package snippet
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
func Main() {
|
||||
// @hide-start
|
||||
client, err := qdrant.NewClient(&qdrant.Config{
|
||||
Host: "localhost",
|
||||
Port: 6334,
|
||||
})
|
||||
// @hide-end
|
||||
|
||||
if err != nil { panic(err) } // @hide
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
HnswConfig: &qdrant.HnswConfigDiff{
|
||||
MaxIndexingThreads: qdrant.PtrOf(uint64(4)),
|
||||
},
|
||||
})
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
```http
|
||||
PATCH /collections/{collection_name}
|
||||
{
|
||||
"hnsw_config": {
|
||||
"max_indexing_threads": 4
|
||||
}
|
||||
}
|
||||
```
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.example.snippets_amalgamation;
|
||||
|
||||
import io.qdrant.client.grpc.Collections.HnswConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
public class Snippet {
|
||||
public static void run() throws Exception {
|
||||
// @hide-start
|
||||
io.qdrant.client.QdrantClient client =
|
||||
new io.qdrant.client.QdrantClient(io.qdrant.client.QdrantGrpcClient.newBuilder("localhost", 6334, false).build());
|
||||
// @hide-end
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setHnswConfig(
|
||||
HnswConfigDiff.newBuilder().setMaxIndexingThreads(4).build())
|
||||
.build())
|
||||
.get();
|
||||
}
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
from qdrant_client import QdrantClient, models # @hide
|
||||
|
||||
client = QdrantClient(url="http://localhost:6333") # @hide
|
||||
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
hnsw_config=models.HnswConfigDiff(max_indexing_threads=4),
|
||||
)
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
use qdrant_client::qdrant::{HnswConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
pub async fn main() -> anyhow::Result<()> {
|
||||
let client = qdrant_client::Qdrant::from_url("http://localhost:6334").build()?; // @hide
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}")
|
||||
.hnsw_config(HnswConfigDiffBuilder::default().max_indexing_threads(4)),
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import { QdrantClient } from "@qdrant/js-client-rest"; // @hide
|
||||
|
||||
const client = new QdrantClient({ host: "localhost", port: 6333 }); // @hide
|
||||
|
||||
client.updateCollection("{collection_name}", {
|
||||
hnsw_config: {
|
||||
max_indexing_threads: 4,
|
||||
},
|
||||
});
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"optimizers_config": {
|
||||
"max_optimization_threads": 1
|
||||
}
|
||||
}'
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
public class Snippet
|
||||
{
|
||||
public static async Task Run()
|
||||
{
|
||||
var client = new QdrantClient("localhost", 6334); // @hide
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
optimizersConfig: new OptimizersConfigDiff { MaxOptimizationThreads = new MaxOptimizationThreads { Value = 1 } }
|
||||
);
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```bash
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"optimizers_config": {
|
||||
"max_optimization_threads": 1
|
||||
}
|
||||
}'
|
||||
```
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```csharp
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
optimizersConfig: new OptimizersConfigDiff { MaxOptimizationThreads = new MaxOptimizationThreads { Value = 1 } }
|
||||
);
|
||||
```
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
```go
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
OptimizersConfig: &qdrant.OptimizersConfigDiff{
|
||||
MaxOptimizationThreads: qdrant.NewMaxOptimizationThreads(1),
|
||||
},
|
||||
})
|
||||
```
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
```java
|
||||
import io.qdrant.client.grpc.Collections.MaxOptimizationThreads;
|
||||
import io.qdrant.client.grpc.Collections.OptimizersConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setOptimizersConfig(
|
||||
OptimizersConfigDiff.newBuilder()
|
||||
.setMaxOptimizationThreads(
|
||||
MaxOptimizationThreads.newBuilder().setValue(1).build())
|
||||
.build())
|
||||
.build())
|
||||
.get();
|
||||
```
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
```python
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
optimizers_config=models.OptimizersConfigDiff(max_optimization_threads=1),
|
||||
)
|
||||
```
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
```rust
|
||||
use qdrant_client::qdrant::{OptimizersConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}").optimizers_config(
|
||||
OptimizersConfigDiffBuilder::default().max_optimization_threads(1),
|
||||
),
|
||||
)
|
||||
.await?;
|
||||
```
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
```typescript
|
||||
client.updateCollection("{collection_name}", {
|
||||
optimizers_config: {
|
||||
max_optimization_threads: 1,
|
||||
},
|
||||
});
|
||||
```
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package snippet
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
func Main() {
|
||||
// @hide-start
|
||||
client, err := qdrant.NewClient(&qdrant.Config{
|
||||
Host: "localhost",
|
||||
Port: 6334,
|
||||
})
|
||||
// @hide-end
|
||||
|
||||
if err != nil { panic(err) } // @hide
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
OptimizersConfig: &qdrant.OptimizersConfigDiff{
|
||||
MaxOptimizationThreads: qdrant.NewMaxOptimizationThreads(1),
|
||||
},
|
||||
})
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
```http
|
||||
PATCH /collections/{collection_name}
|
||||
{
|
||||
"optimizers_config": {
|
||||
"max_optimization_threads": 1
|
||||
}
|
||||
}
|
||||
```
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
package com.example.snippets_amalgamation;
|
||||
|
||||
import io.qdrant.client.grpc.Collections.MaxOptimizationThreads;
|
||||
import io.qdrant.client.grpc.Collections.OptimizersConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
public class Snippet {
|
||||
public static void run() throws Exception {
|
||||
// @hide-start
|
||||
io.qdrant.client.QdrantClient client =
|
||||
new io.qdrant.client.QdrantClient(io.qdrant.client.QdrantGrpcClient.newBuilder("localhost", 6334, false).build());
|
||||
// @hide-end
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setOptimizersConfig(
|
||||
OptimizersConfigDiff.newBuilder()
|
||||
.setMaxOptimizationThreads(
|
||||
MaxOptimizationThreads.newBuilder().setValue(1).build())
|
||||
.build())
|
||||
.build())
|
||||
.get();
|
||||
}
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
from qdrant_client import QdrantClient, models # @hide
|
||||
|
||||
client = QdrantClient(url="http://localhost:6333") # @hide
|
||||
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
optimizers_config=models.OptimizersConfigDiff(max_optimization_threads=1),
|
||||
)
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
use qdrant_client::qdrant::{OptimizersConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
pub async fn main() -> anyhow::Result<()> {
|
||||
let client = qdrant_client::Qdrant::from_url("http://localhost:6334").build()?; // @hide
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}").optimizers_config(
|
||||
OptimizersConfigDiffBuilder::default().max_optimization_threads(1),
|
||||
),
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import { QdrantClient } from "@qdrant/js-client-rest"; // @hide
|
||||
|
||||
const client = new QdrantClient({ host: "localhost", port: 6333 }); // @hide
|
||||
|
||||
client.updateCollection("{collection_name}", {
|
||||
optimizers_config: {
|
||||
max_optimization_threads: 1,
|
||||
},
|
||||
});
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"optimizers_config": {
|
||||
"max_segment_size": 100000
|
||||
}
|
||||
}'
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
public class Snippet
|
||||
{
|
||||
public static async Task Run()
|
||||
{
|
||||
var client = new QdrantClient("localhost", 6334); // @hide
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
optimizersConfig: new OptimizersConfigDiff { MaxSegmentSize = 100000 }
|
||||
);
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```bash
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"optimizers_config": {
|
||||
"max_segment_size": 100000
|
||||
}
|
||||
}'
|
||||
```
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```csharp
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
optimizersConfig: new OptimizersConfigDiff { MaxSegmentSize = 100000 }
|
||||
);
|
||||
```
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
```go
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
OptimizersConfig: &qdrant.OptimizersConfigDiff{
|
||||
MaxSegmentSize: qdrant.PtrOf(uint64(100000)),
|
||||
},
|
||||
})
|
||||
```
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
```java
|
||||
import io.qdrant.client.grpc.Collections.OptimizersConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setOptimizersConfig(
|
||||
OptimizersConfigDiff.newBuilder().setMaxSegmentSize(100000).build())
|
||||
.build())
|
||||
.get();
|
||||
```
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
```python
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
optimizers_config=models.OptimizersConfigDiff(max_segment_size=100000),
|
||||
)
|
||||
```
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
```rust
|
||||
use qdrant_client::qdrant::{OptimizersConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}").optimizers_config(
|
||||
OptimizersConfigDiffBuilder::default().max_segment_size(100000u64),
|
||||
),
|
||||
)
|
||||
.await?;
|
||||
```
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
```typescript
|
||||
client.updateCollection("{collection_name}", {
|
||||
optimizers_config: {
|
||||
max_segment_size: 100000,
|
||||
},
|
||||
});
|
||||
```
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package snippet
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
func Main() {
|
||||
// @hide-start
|
||||
client, err := qdrant.NewClient(&qdrant.Config{
|
||||
Host: "localhost",
|
||||
Port: 6334,
|
||||
})
|
||||
// @hide-end
|
||||
|
||||
if err != nil { panic(err) } // @hide
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
OptimizersConfig: &qdrant.OptimizersConfigDiff{
|
||||
MaxSegmentSize: qdrant.PtrOf(uint64(100000)),
|
||||
},
|
||||
})
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
```http
|
||||
PATCH /collections/{collection_name}
|
||||
{
|
||||
"optimizers_config": {
|
||||
"max_segment_size": 100000
|
||||
}
|
||||
}
|
||||
```
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.example.snippets_amalgamation;
|
||||
|
||||
import io.qdrant.client.grpc.Collections.OptimizersConfigDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
public class Snippet {
|
||||
public static void run() throws Exception {
|
||||
// @hide-start
|
||||
io.qdrant.client.QdrantClient client =
|
||||
new io.qdrant.client.QdrantClient(io.qdrant.client.QdrantGrpcClient.newBuilder("localhost", 6334, false).build());
|
||||
// @hide-end
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setOptimizersConfig(
|
||||
OptimizersConfigDiff.newBuilder().setMaxSegmentSize(100000).build())
|
||||
.build())
|
||||
.get();
|
||||
}
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
from qdrant_client import QdrantClient, models # @hide
|
||||
|
||||
client = QdrantClient(url="http://localhost:6333") # @hide
|
||||
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
optimizers_config=models.OptimizersConfigDiff(max_segment_size=100000),
|
||||
)
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
use qdrant_client::qdrant::{OptimizersConfigDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
pub async fn main() -> anyhow::Result<()> {
|
||||
let client = qdrant_client::Qdrant::from_url("http://localhost:6334").build()?; // @hide
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}").optimizers_config(
|
||||
OptimizersConfigDiffBuilder::default().max_segment_size(100000u64),
|
||||
),
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import { QdrantClient } from "@qdrant/js-client-rest"; // @hide
|
||||
|
||||
const client = new QdrantClient({ host: "localhost", port: 6333 }); // @hide
|
||||
|
||||
client.updateCollection("{collection_name}", {
|
||||
optimizers_config: {
|
||||
max_segment_size: 100000,
|
||||
},
|
||||
});
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"params": {
|
||||
"read_fan_out_delay_ms": 100
|
||||
}
|
||||
}'
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
public class Snippet
|
||||
{
|
||||
public static async Task Run()
|
||||
{
|
||||
var client = new QdrantClient("localhost", 6334); // @hide
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
collectionParams: new CollectionParamsDiff { ReadFanOutDelayMs = 100 }
|
||||
);
|
||||
}
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```bash
|
||||
curl -X PATCH http://localhost:6333/collections/{collection_name} \
|
||||
-H 'Content-Type: application/json' \
|
||||
--data-raw '{
|
||||
"params": {
|
||||
"read_fan_out_delay_ms": 100
|
||||
}
|
||||
}'
|
||||
```
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
```csharp
|
||||
using Qdrant.Client;
|
||||
using Qdrant.Client.Grpc;
|
||||
|
||||
await client.UpdateCollectionAsync(
|
||||
collectionName: "{collection_name}",
|
||||
collectionParams: new CollectionParamsDiff { ReadFanOutDelayMs = 100 }
|
||||
);
|
||||
```
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
```go
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
Params: &qdrant.CollectionParamsDiff{
|
||||
ReadFanOutDelayMs: qdrant.PtrOf(uint64(100)),
|
||||
},
|
||||
})
|
||||
```
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
```java
|
||||
import io.qdrant.client.grpc.Collections.CollectionParamsDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setParams(
|
||||
CollectionParamsDiff.newBuilder().setReadFanOutDelayMs(100).build())
|
||||
.build())
|
||||
.get();
|
||||
```
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
```python
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
collection_params=models.CollectionParamsDiff(read_fan_out_delay_ms=100),
|
||||
)
|
||||
```
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
```rust
|
||||
use qdrant_client::qdrant::{CollectionParamsDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}")
|
||||
.params(CollectionParamsDiffBuilder::default().read_fan_out_delay_ms(100u64)),
|
||||
)
|
||||
.await?;
|
||||
```
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
```typescript
|
||||
client.updateCollection("{collection_name}", {
|
||||
params: {
|
||||
read_fan_out_delay_ms: 100,
|
||||
},
|
||||
});
|
||||
```
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package snippet
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/qdrant/go-client/qdrant"
|
||||
)
|
||||
|
||||
func Main() {
|
||||
// @hide-start
|
||||
client, err := qdrant.NewClient(&qdrant.Config{
|
||||
Host: "localhost",
|
||||
Port: 6334,
|
||||
})
|
||||
// @hide-end
|
||||
|
||||
if err != nil { panic(err) } // @hide
|
||||
|
||||
client.UpdateCollection(context.Background(), &qdrant.UpdateCollection{
|
||||
CollectionName: "{collection_name}",
|
||||
Params: &qdrant.CollectionParamsDiff{
|
||||
ReadFanOutDelayMs: qdrant.PtrOf(uint64(100)),
|
||||
},
|
||||
})
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
```http
|
||||
PATCH /collections/{collection_name}
|
||||
{
|
||||
"params": {
|
||||
"read_fan_out_delay_ms": 100
|
||||
}
|
||||
}
|
||||
```
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.example.snippets_amalgamation;
|
||||
|
||||
import io.qdrant.client.grpc.Collections.CollectionParamsDiff;
|
||||
import io.qdrant.client.grpc.Collections.UpdateCollection;
|
||||
|
||||
public class Snippet {
|
||||
public static void run() throws Exception {
|
||||
// @hide-start
|
||||
io.qdrant.client.QdrantClient client =
|
||||
new io.qdrant.client.QdrantClient(io.qdrant.client.QdrantGrpcClient.newBuilder("localhost", 6334, false).build());
|
||||
// @hide-end
|
||||
|
||||
client
|
||||
.updateCollectionAsync(
|
||||
UpdateCollection.newBuilder()
|
||||
.setCollectionName("{collection_name}")
|
||||
.setParams(
|
||||
CollectionParamsDiff.newBuilder().setReadFanOutDelayMs(100).build())
|
||||
.build())
|
||||
.get();
|
||||
}
|
||||
}
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
from qdrant_client import QdrantClient, models # @hide
|
||||
|
||||
client = QdrantClient(url="http://localhost:6333") # @hide
|
||||
|
||||
client.update_collection(
|
||||
collection_name="{collection_name}",
|
||||
collection_params=models.CollectionParamsDiff(read_fan_out_delay_ms=100),
|
||||
)
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
use qdrant_client::qdrant::{CollectionParamsDiffBuilder, UpdateCollectionBuilder};
|
||||
|
||||
pub async fn main() -> anyhow::Result<()> {
|
||||
let client = qdrant_client::Qdrant::from_url("http://localhost:6334").build()?; // @hide
|
||||
|
||||
client
|
||||
.update_collection(
|
||||
UpdateCollectionBuilder::new("{collection_name}")
|
||||
.params(CollectionParamsDiffBuilder::default().read_fan_out_delay_ms(100u64)),
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
import { QdrantClient } from "@qdrant/js-client-rest"; // @hide
|
||||
|
||||
const client = new QdrantClient({ host: "localhost", port: 6333 }); // @hide
|
||||
|
||||
client.updateCollection("{collection_name}", {
|
||||
params: {
|
||||
read_fan_out_delay_ms: 100,
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user