Skip to content

Conversation

@bevzzz
Copy link
Collaborator

@bevzzz bevzzz commented Jul 11, 2025

This PR introduces APIs for managing replication operations it the cluster:

// Query current sharding state
client.cluster().shardingStateQuerier().withShard("test-shard").run();

// Launch new replication and query its status
client.cluster().replicator().withClassName("Pizza").withShard("test-shard").run();
client.cluster().replication().querier().withShard("test-shard").includeStatusHistory(true).run()
client.cluster().replication().canceler().withUuid("test-repl-uuid").run();
client.cluster().replication().deleter().withUuid("test-repl-uuid").run();

It is also possible to manage roles' permissions related to replication ops:

Permission.replicate("Pizza", "test-shard", ReplicatePermission.Action.CREATE, ReplicatePermission.Action.UPDATE);

As usual, all of the above is available in the async-flavor. 📞 🔙

❗Unfortunately, ClientReplicateTest suites add roughly 1min to the total test execution time, because "waiting" for a replication op to acquire status CANCELED and then deleting it is taking a lot of time.

Reference PR: https://github.com/weaviate/weaviate-python-client/pull/1708/files

@bevzzz bevzzz requested a review from antas-marcin July 11, 2025 17:58
@bevzzz bevzzz self-assigned this Jul 11, 2025
Copy link

@orca-security-eu orca-security-eu bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Orca Security Scan Summary

Status Check Issues by priority
Passed Passed Infrastructure as Code high 0   medium 0   low 0   info 0 View in Orca
Passed Passed SAST high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Secrets high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Vulnerabilities high 0   medium 0   low 0   info 0 View in Orca

@bevzzz bevzzz marked this pull request as ready for review July 14, 2025 12:35
@bevzzz bevzzz force-pushed the feat/replicate-ops branch from 7a35fe0 to 2554157 Compare July 22, 2025 08:35
@bevzzz bevzzz merged commit 9a70054 into main Jul 22, 2025
5 checks passed
@bevzzz bevzzz deleted the feat/replicate-ops branch July 22, 2025 09:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants