Skip to content

feature: consolidate capability toggles under wave.capabilities.*#1098

Merged
pditommaso merged 3 commits into
masterfrom
capabilities-config-group
Jul 23, 2026
Merged

feature: consolidate capability toggles under wave.capabilities.*#1098
pditommaso merged 3 commits into
masterfrom
capabilities-config-group

Conversation

@pditommaso

@pditommaso pditommaso commented Jul 22, 2026

Copy link
Copy Markdown
Collaborator

Summary

Groups Wave's installation-level capability toggles under a single, consistent wave.capabilities.* namespace, and adds a strict environment that disables them all at once for locked-down / regulated deployments.

Previously these landed with inconsistent shapes: wave.allowAnonymous (flat), wave.container.pull.enabled (nested), wave.inject-credentials (flat, top-level), and wave.views.enabled (nested). This unifies them.

Capability Key (default true) What false does
Anonymous (unauthenticated) access wave.capabilities.anonymous-access Requires authenticated access
Ephemeral pull/augmentation path wave.capabilities.ephemeral-token Requests rejected — must use freeze mode
Registry credential brokering on proxy pulls wave.capabilities.credentials-federation Wave doesn't inject creds; caller uses own (e.g. IAM role)
HTML view pages under /view/** wave.capabilities.web-views ViewController not loaded → 404

All flags default to true (permissive) so existing deployments behave exactly as before. The new strict environment (application-strict.yml, enabled with MICRONAUT_ENVIRONMENTS=strict) sets all four to false.

Changes

  • ContainerController — renames wave.container.pull.enabledwave.capabilities.ephemeral-token (field allowPullephemeralToken); reads anonymous access from wave.capabilities.anonymous-access; rejection message updated to reflect the new naming.
  • RegistryProxyService — adds wave.capabilities.credentials-federation gating getCredentials on the proxy-pull path.
  • ViewController — class-level @Requires(property = 'wave.capabilities.web-views', ...).
  • application.yml — new wave.capabilities block with documented defaults.
  • application-strict.yml — new env profile disabling all capabilities.
  • docs/configuration.md — new Capabilities section documenting all four flags and the strict environment.
  • Javadocs and log/error messages updated to the new naming.

Backward compatibility

  • Defaults unchanged (all true) — no behavior change for existing installs.

  • The legacy wave.allowAnonymous key still works as an undocumented alias: application.yml resolves anonymous-access from ${wave.allowAnonymous:true}, so operators who still set the old key are honored (no default shadows it). Covered by AnonymousAccessLegacyAliasTest:

    wave.allowAnonymous resolved anonymous-access
    unset true (default)
    false false
    true true

Related PRs

Test specs from #1088 and #1086 are reproduced here under the new keys, preserving original authorship.

Testing

./gradlew :test — all pass:

  • ContainerControllerTest
  • RegistryProxyServiceCredentialsTest
  • ViewControllerDisabledTest / ViewControllerEnabledTest
  • AnonymousAccessLegacyAliasTest

🤖 Generated with Claude Code

@pditommaso
pditommaso requested a review from gavinelder July 22, 2026 17:37

@gavinelder gavinelder left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't feel I deserve the attribution within the codebase the clean improvements to the variable names to declare intent are well thought out and provide a strong level of clarity.

pditommaso and others added 3 commits July 23, 2026 14:02
Groups the installation-level capability toggles under a single, consistent
`wave.capabilities.*` config namespace (all default `true`), and adds a
`strict` environment (application-strict.yml) that disables them all at once
for locked-down / regulated deployments.

- wave.capabilities.ephemeral-token       (renames wave.container.pull.enabled, #1089)
- wave.capabilities.credentials-federation (supersedes wave.inject-credentials, #1088)
- wave.capabilities.web-views             (supersedes wave.views.enabled, #1086)

Javadocs, error/log messages and user documentation updated accordingly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds anonymous access as a capability toggle (default true). The legacy
`wave.allowAnonymous` key still works as an undocumented backward-compat alias
via the config fallback expression, and is disabled in the `strict` environment.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Adds AnonymousAccessLegacyAliasTest proving the legacy `wave.allowAnonymous`
key still drives `wave.capabilities.anonymous-access` (unset → true default;
false/true overrides honored).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@pditommaso
pditommaso force-pushed the capabilities-config-group branch from 0c93e8c to acec05b Compare July 23, 2026 12:46
@pditommaso
pditommaso merged commit ca2d0ed into master Jul 23, 2026
3 checks passed
@pditommaso
pditommaso deleted the capabilities-config-group branch July 23, 2026 12:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants