Skip to main content

Module writes

Module writes 

Source
Expand description

Write tools. Every mutation builds a full candidate GatewayConfig, then either validates it (dry_run) or commits it through the configured ConfigStore โ€” exactly the path the Admin API takes.

Structsยง

DeleteArgs
PutArgs
ReloadArgs

Functionsยง

commit_candidate
Applies mutate to a clone of the live config, then validates or commits.
delete_plugin_config
delete_policy
delete_route
delete_store
delete_supernode
named_json ๐Ÿ”’
Names of the entries in a named-resource section, keyed for comparison.
parse_named ๐Ÿ”’
Like super::parse_payload, but the name argument wins over (or fills in) any name inside the payload before deserializing โ€” payloads commonly omit name and rely on the tool argument, exactly as the REST PUT /api/...{name} handlers let the path segment override the body.
put_plugin_config
put_policy
put_route
put_store
put_supernode
reload_config
Re-reads gateway.yaml. With the file config source, put_*/delete_* edits are live but never written back, so a reload silently reverts them โ€” hence the guard: unless discard_unsaved is set, any difference between memory and disk is reported and nothing is reloaded.
remove ๐Ÿ”’
unsaved_changes
One line per resource that differs between the live config and the file: policy 'p' only in memory, route 'r' only on disk, store 's' differs.
upsert ๐Ÿ”’