Skip to content

feat(compose): accept a comma-separated service list in --service#13705

Open
czubocha wants to merge 1 commit into
mainfrom
feat/compose-service-list
Open

feat(compose): accept a comma-separated service list in --service#13705
czubocha wants to merge 1 commit into
mainfrom
feat/compose-service-list

Conversation

@czubocha

@czubocha czubocha commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

--service now accepts a comma-separated list, so a project-wide command runs on an exact subset of services:

serverless deploy --service=service-a,service-d --stage my-feature
  • Runs on exactly the named services, ordered among themselves by dependsOn.
  • Services not named are left untouched — neither deployed nor removed. Their outputs stay available for ${param:xxx} resolution, so a subset can reference services already deployed elsewhere.
  • Supported for deploy, remove, info, print, and package.
  • Enables services with different lifecycles — e.g. deploying application services to a personal or preview stage while a shared, long-lived service stays in place.
  • Also adds clearer guidance for single-service-only commands (e.g. dev) and unresolved parameters.

Docs

Updated docs/sf/guides/compose.md with a "Running a command on a subset of services" section.

Tests

  • Unit: execute-subset, service-option, teaching-errors, state.
  • Live integration: compose-service-subset (exact-set semantics, dependency ordering, first-run exit code), compose-dev (single-service dev with graph/hoisted params).

Summary by CodeRabbit

  • New Features
    • Compose now supports running an exact subset of services via comma-separated --service values (applies to deploy, remove, info, print, and package).
    • Updated Compose help to include the package command and document the global --service option.
  • Bug Fixes
    • Improved teaching/error messages for invalid commands, blank --service, and missing param/output resolution, including clearer stage guidance.
    • More robust behavior when referenced dependent stacks aren’t deployed yet.
  • Documentation
    • Expanded the Compose guide with subset execution and dependency behavior details.
  • Tests
    • Added integration/unit coverage for subset semantics and single-service Compose dev.

@Mmarzex

Mmarzex commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Snyk checks have passed. No issues have been found so far.

Status Scan Engine Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues
Code Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@coderabbitai

coderabbitai Bot commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 74652d5e-e07c-417a-981f-47a799a66f31

📥 Commits

Reviewing files that changed from the base of the PR and between f1cb5a8 and 2e17519.

📒 Files selected for processing (22)
  • docs/sf/guides/compose.md
  • packages/sf-core/package.json
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/src/lib/runners/compose/index.js
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/compose-dev.test.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/localdep/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/shared/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/middle/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/worker/serverless.yml
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js
🚧 Files skipped from review as they are similar to previous changes (14)
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • docs/sf/guides/compose.md
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js
  • packages/sf-core/src/lib/runners/compose/index.js
  • packages/sf-core/package.json
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/src/lib/runners/compose/compose.js

📝 Walkthrough

Walkthrough

Compose adds comma-separated --service selection, exact subset execution, improved dependency-state errors, expanded help and documentation, and unit/integration coverage for subset deployment, removal, parameter resolution, and single-service dev mode.

Changes

Compose subset execution

Layer / File(s) Summary
Service selection and command routing
packages/sf-core/src/lib/runners/compose/compose.js, packages/sf-core/src/lib/runners/compose/help.js, docs/sf/guides/compose.md, packages/sf-core/tests/unit/lib/runners/compose/*
Parses comma-separated --service values, routes single and multi-service commands, documents supported commands, and adds the package command to help.
Exact subset graph execution
packages/sf-core/src/lib/runners/compose/index.js, packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js, packages/sf-core/tests/integration/compose-service-subset/*
Validates named services, reads dependency state, preserves selected-service ordering, and executes or removes only the requested subset with integration fixtures and regression coverage.
Dependency state and teaching errors
packages/sf-core/src/lib/runners/compose/index.js, packages/sf-core/src/lib/runners/compose/state.js, packages/sf-core/tests/unit/lib/runners/compose/{state,teaching-errors}.test.js
Separates missing outputs from missing service state, tolerates undeployed dependencies, and tests command-specific guidance and parameter handling.
Compose dev integration coverage
packages/sf-core/tests/integration/compose-dev/*, packages/sf-core/package.json
Adds a staged single-service dev integration fixture, endpoint polling and teardown logic, and dedicated Jest scripts.

Estimated code review effort: 4 (Complex) | ~45 minutes

Sequence Diagram(s)

sequenceDiagram
  participant ComposeCLI
  participant runCompose
  participant Compose
  participant StateResolver
  ComposeCLI->>runCompose: parse --service=a,b
  runCompose->>Compose: executeSubsetComponents
  Compose->>StateResolver: read dependency closure
  StateResolver-->>Compose: return service state
  Compose->>Compose: execute selected services in dependency order
Loading

Suggested reviewers: eahefnawy

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: Compose now accepts a comma-separated service list in --service.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/compose-service-list

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

ESLint install failed: one or more packages not found in the registry.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 2

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
packages/sf-core/src/lib/runners/compose/index.js (1)

322-357: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Use === undefined for resolved outputs
if (!stateValue) treats an empty-string CloudFormation output as missing, so this can throw the new "has no output" / "no deployed state" errors for a value that did resolve.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/sf-core/src/lib/runners/compose/index.js` around lines 322 - 357,
Update the stateValue presence check in the parameter-resolution flow to use an
explicit undefined comparison instead of truthiness. Preserve empty-string and
other valid resolved output values, while retaining the existing missing-output
and missing-service error handling for genuinely undefined results.
🧹 Nitpick comments (1)
packages/sf-core/tests/integration/compose-dev/compose-dev.test.js (1)

38-43: 🩺 Stability & Availability | 🔵 Trivial | 💤 Low value

Consider retrying on all non-200 responses to prevent flakiness.

While a cold local-dev proxy might return 5xx errors before the shim is fully wired, newly deployed API Gateway endpoints can also briefly return 403 Forbidden or 404 Not Found while routes are propagating. Retrying on any non-200 status will make the test more resilient against these transient API Gateway states.

♻️ Proposed refactor
-      // A cold local-dev proxy can briefly answer 5xx before the shim is wired.
-      if (response.status >= 500) {
+      // A cold local-dev proxy can briefly answer 5xx before the shim is wired,
+      // and API Gateway can briefly answer 403/404 during route propagation.
+      if (!response.ok) {
         lastErr = new Error(`endpoint returned ${response.status}`)
       } else {
         return response
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@packages/sf-core/tests/integration/compose-dev/compose-dev.test.js` around
lines 38 - 43, Update the response handling in the compose-dev retry loop to
retry on every non-200 HTTP status, not only statuses 500 and above. Preserve
returning the response immediately when its status is 200, while recording an
error containing the returned status for all other responses.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/sf-core/src/lib/runners/compose/compose.js`:
- Around line 246-259: Update the compose service-selection flow around
serviceNames and executeComponentsGraph to reject truthy options.service values
that parse to no service names, including whitespace or comma-only values,
before any command execution. Ensure interactive or single-service commands
cannot fall through to whole-graph execution, and remove options.service before
invoking executeComponentsGraph so malformed raw values are not passed
downstream.

In `@packages/sf-core/tests/integration/compose-dev/compose-dev.test.js`:
- Around line 81-87: Update the beforeAll environment setup at
packages/sf-core/tests/integration/compose-dev/compose-dev.test.js#L81-L87 to
mutate process.env directly, conditionally set SERVERLESS_LICENSE_KEY only when
its dev value exists, and delete SERVERLESS_ACCESS_KEY instead of assigning
undefined. Update afterAll at
packages/sf-core/tests/integration/compose-dev/compose-dev.test.js#L126 to clear
current environment keys and restore originalEnv with Object.assign rather than
reassigning process.env.

---

Outside diff comments:
In `@packages/sf-core/src/lib/runners/compose/index.js`:
- Around line 322-357: Update the stateValue presence check in the
parameter-resolution flow to use an explicit undefined comparison instead of
truthiness. Preserve empty-string and other valid resolved output values, while
retaining the existing missing-output and missing-service error handling for
genuinely undefined results.

---

Nitpick comments:
In `@packages/sf-core/tests/integration/compose-dev/compose-dev.test.js`:
- Around line 38-43: Update the response handling in the compose-dev retry loop
to retry on every non-200 HTTP status, not only statuses 500 and above. Preserve
returning the response immediately when its status is 200, while recording an
error containing the returned status for all other responses.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: e6a015a5-8126-4e6e-940d-5d3d790a5113

📥 Commits

Reviewing files that changed from the base of the PR and between 49c2d35 and 4678a5d.

📒 Files selected for processing (22)
  • docs/sf/guides/compose.md
  • packages/sf-core/package.json
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/src/lib/runners/compose/index.js
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/compose-dev.test.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/localdep/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/shared/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/middle/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/worker/serverless.yml
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js

Comment thread packages/sf-core/src/lib/runners/compose/compose.js
Comment thread packages/sf-core/tests/integration/compose-dev/compose-dev.test.js Outdated
@czubocha czubocha force-pushed the feat/compose-service-list branch from 4678a5d to 8d6eb0a Compare July 14, 2026 17:01

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js`:
- Around line 145-160: Hoist the freshStage value from the deploy test to the
surrounding test scope so it is available during teardown. Update afterAll to
delete the API stack associated with freshStage in addition to the existing
stage stack, ensuring cleanup runs even when the expected failure assertion
regresses.
- Line 18: Update both suites in
packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js:
at lines 18 and 190, snapshot process.env by value using a spread copy; at lines
40-49 and 202-211, mutate environment keys in place, delete the access key as
needed, and restore the original values with Object.assign instead of replacing
process.env.
- Around line 28-34: Update stackExists to return false only for the expected
CloudFormation ValidationError indicating the stack does not exist, and rethrow
all other DescribeStacks failures. In both teardown sites at lines 52-69 and
212-229, apply the same missing-stack-only filtering so delete and waiter errors
propagate instead of being suppressed.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5d823cb3-ce97-46d4-b6a8-236bf2f9b327

📥 Commits

Reviewing files that changed from the base of the PR and between 4678a5d and 8d6eb0a.

📒 Files selected for processing (22)
  • docs/sf/guides/compose.md
  • packages/sf-core/package.json
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/src/lib/runners/compose/index.js
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/compose-dev.test.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/localdep/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/shared/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/middle/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/worker/serverless.yml
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js
🚧 Files skipped from review as they are similar to previous changes (13)
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • docs/sf/guides/compose.md
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/src/lib/runners/compose/index.js

@czubocha czubocha force-pushed the feat/compose-service-list branch from 8d6eb0a to f1cb5a8 Compare July 14, 2026 18:18

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 2

🧹 Nitpick comments (1)
packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml (1)

7-8: 🔒 Security & Privacy | 🔵 Trivial | 💤 Low value

Unencrypted SNS topic (test fixture only).

Checkov flags this topic as unencrypted (CKV_AWS_26). Low real-world risk since this is a disposable integration-test fixture, but adding KmsMasterKeyId would silence the finding if it matters for policy compliance.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml`
around lines 7 - 8, Update the AWS::SNS::Topic resource in the serverless
fixture to include a KmsMasterKeyId encryption configuration, using the
project’s established KMS key reference if available, so Checkov rule CKV_AWS_26
is satisfied while preserving the fixture’s behavior.

Source: Linters/SAST tools

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@packages/sf-core/src/lib/runners/compose/index.js`:
- Around line 352-356: Update the refresh command in the ServerlessError message
within the compose runner to append the existing stageFlag, matching the
stage-specific deploy hint. Preserve the current depService info command and all
other error text.

In `@packages/sf-core/tests/integration/compose-dev/compose-dev.test.js`:
- Around line 69-95: Move the originalCwd initialization in beforeAll above the
shim existence check so it is set even when the check throws. Keep afterAll’s
process.chdir(originalCwd) behavior unchanged and preserve the existing shim
validation.

---

Nitpick comments:
In
`@packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml`:
- Around line 7-8: Update the AWS::SNS::Topic resource in the serverless fixture
to include a KmsMasterKeyId encryption configuration, using the project’s
established KMS key reference if available, so Checkov rule CKV_AWS_26 is
satisfied while preserving the fixture’s behavior.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 064db6f7-9b81-4152-a7d6-c7c360a6c0bb

📥 Commits

Reviewing files that changed from the base of the PR and between 8d6eb0a and f1cb5a8.

📒 Files selected for processing (22)
  • docs/sf/guides/compose.md
  • packages/sf-core/package.json
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/src/lib/runners/compose/index.js
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/compose-dev.test.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/localdep/serverless.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-dev/fixture/shared/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/compose-service-subset.test.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/db/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/middle/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/worker/serverless.yml
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js
🚧 Files skipped from review as they are similar to previous changes (13)
  • packages/sf-core/src/lib/runners/compose/state.js
  • packages/sf-core/tests/integration/compose-dev/fixture/api/handler.js
  • docs/sf/guides/compose.md
  • packages/sf-core/src/lib/runners/compose/help.js
  • packages/sf-core/tests/integration/compose-service-subset/fixture/api/serverless.yml
  • packages/sf-core/tests/integration/compose-service-subset/fixture/serverless-compose.yml
  • packages/sf-core/tests/unit/lib/runners/compose/service-option.test.js
  • packages/sf-core/tests/integration/compose-dev/fixture/serverless-compose.yml
  • packages/sf-core/package.json
  • packages/sf-core/tests/unit/lib/runners/compose/state.test.js
  • packages/sf-core/tests/unit/lib/runners/compose/teaching-errors.test.js
  • packages/sf-core/src/lib/runners/compose/compose.js
  • packages/sf-core/tests/unit/lib/runners/compose/execute-subset.test.js

Comment thread packages/sf-core/src/lib/runners/compose/index.js Outdated
Comment thread packages/sf-core/tests/integration/compose-dev/compose-dev.test.js
`--service` now accepts a comma-separated list, so a project-wide command
runs on an exact subset of services:

    serverless deploy --service=service-a,service-d --stage my-feature

- Runs on exactly the named services, ordered among themselves by `dependsOn`.
- Services not named are left untouched — neither deployed nor removed. Their
  outputs remain available for `${param:xxx}` resolution, so a subset can
  reference services already deployed elsewhere.
- Supported for deploy, remove, info, print, and package.
- Adds clearer guidance for single-service-only commands (e.g. `dev`) and
  unresolved parameters.

Docs updated in guides/compose.md. Covered by unit and live integration tests.
@czubocha czubocha force-pushed the feat/compose-service-list branch from f1cb5a8 to 2e17519 Compare July 14, 2026 19:00
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.

2 participants