feat(async-replication): events handler observers, facade, and lifecycle guards (3/8) - #279
Draft
marceloneppel wants to merge 1 commit into
Draft
Conversation
marceloneppel
force-pushed
the
async-replication-2-manager
branch
from
September 4, 2026 23:07
3fb11e3 to
3890375
Compare
marceloneppel
force-pushed
the
async-replication-3-events-core
branch
from
September 4, 2026 23:07
46387a5 to
cf50a0b
Compare
marceloneppel
force-pushed
the
async-replication-2-manager
branch
from
September 4, 2026 23:22
3890375 to
28cd1c6
Compare
marceloneppel
force-pushed
the
async-replication-3-events-core
branch
from
September 4, 2026 23:22
cf50a0b to
d398076
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue
Ports the event-observing half of the charms' async replication module; the data plane landed in 2/8. Part of the stacked series — the promotion/standby flow methods land in 4/8.
Solution
PostgreSQLAsyncReplication(Object): constructor + observers on both replication relations, the public surface the charms consume (delegating to the manager),set_app_status/handle_read_only_mode, and the observed handlers_on_async_relation_joined(VM observesrelation_joined, K8srelation_created— divergence preserved),_on_async_relation_departed,_on_async_relation_broken(with the DPE-10203 teardown resilience: the standby check,update_configand watcher-endpoint failures are logged and survived),_on_async_relation_changed,_on_create_replication(clears a stale promotion before the guard, per #1913) and_on_secret_changed(by-id consumer matching via_same_secret_id).The
relationprobe treats a relation with unreadable databags as absent (DPE-10203).