Skip to content

feat(staging): split state.json into param.json and secret.json#144

Merged
mpyw merged 1 commit intomulticloudfrom
feat/split-stage-files
Jan 19, 2026
Merged

feat(staging): split state.json into param.json and secret.json#144
mpyw merged 1 commit intomulticloudfrom
feat/split-stage-files

Conversation

@mpyw
Copy link
Owner

@mpyw mpyw commented Jan 19, 2026

Summary

  • Refactor file-based staging store to use separate files per service
  • param.json for Parameter Store entries
  • secret.json for Secrets Manager entries

Changes

  • Store now uses stateDir instead of stateFilePath
  • Add NewStoreWithDir constructor, deprecate NewStoreWithPath
  • Drain merges state from both service files
  • WriteState writes to appropriate file(s) based on service filter
  • Delete removes both files
  • Exists returns true if either file exists
  • IsEncrypted checks both files

Why

This separation prepares for multi-cloud support where different providers may have different service availability (e.g., GCP only has Secret Manager, no Parameter Store equivalent).

Test plan

  • Unit tests updated and passing
  • Lint passing
  • E2E tests (manual verification)

🤖 Generated with Claude Code

@github-actions github-actions bot added go Pull requests that update Go code github_actions Pull requests that update GitHub Actions code gui GUI functionality staging Staging workflow functionality labels Jan 19, 2026
@mpyw mpyw force-pushed the feat/split-stage-files branch from 4ef6dfd to 1d0cb83 Compare January 19, 2026 02:05
@codecov
Copy link

codecov bot commented Jan 19, 2026

Codecov Report

❌ Patch coverage is 98.83721% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 90.14%. Comparing base (1253dff) to head (3b1b4f2).
⚠️ Report is 1 commits behind head on multicloud.

Files with missing lines Patch % Lines
internal/staging/store/file/store.go 98.83% 1 Missing ⚠️
Additional details and impacted files
@@              Coverage Diff               @@
##           multicloud     #144      +/-   ##
==============================================
+ Coverage       90.08%   90.14%   +0.06%     
==============================================
  Files             133      133              
  Lines            7754     7807      +53     
==============================================
+ Hits             6985     7038      +53     
  Misses            526      526              
  Partials          243      243              
Flag Coverage Δ
e2e 67.48% <52.32%> (-0.02%) ⬇️
platform-darwin 64.38% <ø> (ø)
platform-linux 62.85% <ø> (ø)
platform-windows 73.46% <ø> (ø)
unittests 79.67% <98.83%> (+0.13%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mpyw mpyw force-pushed the feat/split-stage-files branch 3 times, most recently from 19ee51f to 9c5d2b1 Compare January 19, 2026 02:18
Refactor file-based staging store to use separate files for each service:
- param.json for Parameter Store entries
- secret.json for Secrets Manager entries

Changes:
- Store now uses stateDir instead of stateFilePath
- Add NewStoreWithDir constructor, deprecate NewStoreWithPath
- Drain merges state from both service files
- WriteState writes to appropriate file(s) based on service filter
- Delete removes both files
- Exists returns true if either file exists
- IsEncrypted checks both files

This separation prepares for multi-cloud support where different
providers may have different service availability.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@mpyw mpyw force-pushed the feat/split-stage-files branch from 9c5d2b1 to 3b1b4f2 Compare January 19, 2026 02:26
@mpyw mpyw enabled auto-merge (squash) January 19, 2026 02:28
@mpyw mpyw mentioned this pull request Jan 19, 2026
7 tasks
@mpyw mpyw merged commit fc9e76e into multicloud Jan 19, 2026
25 checks passed
@mpyw mpyw deleted the feat/split-stage-files branch January 19, 2026 02:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update GitHub Actions code go Pull requests that update Go code gui GUI functionality staging Staging workflow functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant