Skip to content

Add app-wide configuration values provider endpoint#487

Merged
erikeelde merged 4 commits into
mainfrom
claude/dazzling-lalande-9d2b83
Jun 22, 2026
Merged

Add app-wide configuration values provider endpoint#487
erikeelde merged 4 commits into
mainfrom
claude/dazzling-lalande-9d2b83

Conversation

@erikeelde

Copy link
Copy Markdown
Owner

Summary

Adds a new, purely-additive provider read endpoint — TogglesProviderContract.configurationValuesUri() — that returns all configuration values for the calling application in a single query, instead of requiring a separate query per configuration.

  • New contract URI (path configurationValues, distinct from the configuration/* key matcher) + recorded in the hand-maintained toggles-core.api.
  • New ProviderConfigurationDao.getConfigurationValueCursor(callingApplication) Room query — the existing per-config values query minus the configurationId filter (scoped to applicationId).
  • New UriMatch.CONFIGURATION_VALUES matcher entry plus the query() and getType() branches in TogglesProvider. The new query inherits the shared setNotificationUri, so the cursor notifies on changes.
  • No existing endpoint behavior changes.

This is the foundational read primitive for a planned client-side in-memory replica (build the full toggle snapshot from three wholesale reads — scopes, configurations, all values — instead of 3 queries per flag). It targets a measured ~240-round-trip cost on a 40-flag Compose settings screen.

Test Plan

  • 4 new Robolectric/Hilt tests (TogglesProviderAllConfigurationValuesTest): getType mime, values across configurations, values across scopes (with content assertions), empty cursor
  • Full provider implementation suite green (92 tests, 0 failures)
  • detekt clean on :toggles-core and :modules:provider:implementation
  • javap -public confirms the public signature matches the .api entry
  • CI: full ./gradlew check + instrumentation tests

🤖 Generated with Claude Code

erikeelde and others added 4 commits June 20, 2026 00:09
Documents the plan to adopt adaptive navigation (NavigationSuiteScaffold +
adaptive-navigation3 list-detail), MaterialExpressiveTheme with the expressive
motion scheme, and Expressive components on the value-editor screens.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Enum option lists can be long, so use a proper scrollable selectable list
instead of ToggleButtonGroup, gated behind a dogfooded boolean feature toggle
(read via toggles-flow) so the new behavior can be tested at runtime.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Task-by-task plan covering adaptive navigation, list-detail pane, expressive
components on the value editors, and the toggle-gated enum list, derived from
the approved design spec.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Returns all configuration values for the calling application in a single
query (configurationValuesUri), the foundational read primitive for a
client-side in-memory replica. Additive; no existing endpoint changes.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@erikeelde erikeelde merged commit bbf3442 into main Jun 22, 2026
4 checks passed
@erikeelde erikeelde deleted the claude/dazzling-lalande-9d2b83 branch June 22, 2026 19:42
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.

1 participant