mirror of
https://github.com/floci-io/floci.git
synced 2026-11-27 07:39:24 -05:00
* fix(networkfirewall): validate replacement before replacing state * fix(networkfirewall): require UpdateToken and keep unchanged fields on update UpdateRuleGroup and UpdateFirewallPolicy now require the current UpdateToken and reject a stale one with InvalidTokenException, as the API reference documents. The replacement is built from the stored resource, so Capacity and Tags, which neither update request models, and any field the request leaves out carry over instead of being dropped. A rule group's Type can't change after creation, UpdateFirewallPolicy requires FirewallPolicy, and UpdateRuleGroup requires exactly one of RuleGroup or Rules, so a request without a definition no longer wipes the stored one. Rule group and firewall policy create, update and delete now share the service lock, so a delete can't be undone by an overlapping update and two updates holding the same token can't both apply. --------- Co-authored-by: Priamo <pgermosen@gmail.com>