Code review comment for lp://staging/~fwereade/pyjuju/always-break-broken-relations

Revision history for this message
Kapil Thangavelu (hazmat) wrote :

LGTM +1, some minors from a second pass.

[8]

             workflow_state = RelationWorkflowState(
- self.client, unit_relation, lifecycle, self.makeDir())
+ self.client, unit_relation, unit.unit_name, lifecycle,
+ self.makeDir())

+ return RelationWorkflowState(
+ self._client, unit_relation, relation_name, lifecycle,
+ self._state_dir)

One of these is wrong.

[9]

+ # If they do run redundant hooks, nothing *bad* should happen, but
+ # it's a potentially significant waste of time.

I'm not entirely comfortable calling these redundant hooks, their
effectively state changes events trigger hook executions against a
dead relation. The fact that its safe is an implementation detail that
may change in the future.

The previous comment posited an example that made this more clear. firing a modified after a broken relation is detected, is a problem imo.

review: Approve

« Back to merge proposal