Managing Collections
1. Understanding Collection Purpose
| Use | Description |
| Backup | Snapshot before risky changes |
| Migration | Switch pod type / region |
| Clone | Spin up dev/test from prod data |
| Restore | Roll back from snapshot |
Note: Collections are a pod-based feature. Serverless uses built-in backups.
2. Creating Collection from Index
Example: Create Collection
pc.create_collection(name="docs-2026-05", source="docs-pod")
| Param | Description |
name | Collection name (unique per project) |
source | Source pod-based index name |
3. Listing All Collections
Example: List
for c in pc.list_collections():
print(c["name"], c["status"])
4. Describing Collection
Example: Describe
info = pc.describe_collection("docs-2026-05")
print(info["size"], info["status"], info["vector_count"])
| Field | Description |
size | Bytes consumed |
vector_count | Total vectors snapshotted |
status | Initializing / Ready |
5. Creating Index from Collection
Example: Restore
pc.create_index(
name="docs-restored",
dimension=1536,
metric="cosine",
spec=PodSpec(
environment="us-east-1-aws",
pod_type="p1.x1",
source_collection="docs-2026-05",
),
)
6. Deleting Collection
Example: Delete
pc.delete_collection("docs-2026-05")
Warning: Deletion is permanent; cannot recover snapshot.
7. Managing Collection Size Limits
| Limit | Value |
| Max per project | 100 collections (Standard) |
| Max size | Plan-dependent |
| Storage cost | ~$0.024/GB-month (varies) |
8. Handling Collection Creation Time
| Vector Count | Approx Time |
| 100K | ~1–2 min |
| 1M | ~5–10 min |
| 10M | ~30–60 min |
9. Verifying Collection Status
Example: Wait for Ready
import time
while pc.describe_collection("docs-2026-05")["status"] != "Ready":
time.sleep(5)
10. Using Collections for Testing Environments
Dev-from-Prod Workflow
- Create collection from prod index.
- Wait for Ready status.
- Create dev index with
source_collection.
- Use smaller pod type to save cost.
- Delete dev index + collection when done.
| Benefit | Detail |
| Realistic data | Full prod distribution |
| Isolated | No risk to prod traffic |