You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<!-- Describe what has changed in this PR -->
**What changed?**
This is a refactoring of the domain-handler with the intent of making
the pathing complexity in that method more tractable. The idea is pretty
simple: Separate out the following pathways:
- Local-domain updates (in this PR)
- Global-domain configuration updates (in following PRs)
- Failovers
- Normal active/passive failover
- AA failover
and in doing so, unify the UpdateDomain Failover functionality and the
new Failover endpoint, which is really a subset of functionality of
UpdateDomain. The reason for this is because the handler's extremely
hard to follow and has a lot of needless complexity through it's
overloaded use-cases.
The idea being that by splitting out the pathways as mentioned above,
they can follow a much more standard pattern of:
- Request validation
- Fetching existing data
- performing writes
Without huge amounts of conditionals and guards. This should make
validation a lot easier (right now it's really hard to work out what's
permissable). It should make future edits easier. Importantly for my
work it should unblock the ability to write changes to the
failoverHistory endpoint, since otherwise crowbaring that it is too
hard.
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
**How did you test it?**
Unit tests and manual local testing
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
**Potential risks**
This could break domain updates, failover, registration if there's a
bug, so some care is warranted.
---------
Signed-off-by: David Porter <[email protected]>
0 commit comments