Skip to content

feat(scale-set): add service controller - #5300

Draft
edersonbrilhante wants to merge 19 commits into
mainfrom
feat-scale-set-typescript
Draft

feat(scale-set): add service controller#5300
edersonbrilhante wants to merge 19 commits into
mainfrom
feat-scale-set-typescript

Conversation

@edersonbrilhante

@edersonbrilhante edersonbrilhante commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Description

Adds the scale-set service controller, GitHub scale-set client library, and EC2 scale-set capability under lambdas/**.

Builds on the neutral EC2 runner creation result from #5312. This PR owns the scale-set-specific orchestration tags and their validation, adds the explicit scale-set-service runner source, and binds each reconciliation request's abort signal before launch, tag, or terminate work.

Splits the EC2 scale-set logic into configuration, inventory, reconciliation, scale-up, and scale-down contexts, with provider.ts as the public facade and matching context-focused tests.

Aligns message handling with the upstream actions/scaleset listener: acknowledge before job acquisition and reconciliation, treat provider failures after acknowledgement as fatal for that reconciler, and keep transport and session recovery separate. Scale-set consumes neutral failed-instance counts and does not inherit the webhook/SQS retry policy.

Normalizes GitHub and Actions service URL paths with linear scans, avoiding regular-expression denial-of-service risks on uncontrolled input while preserving invalid-path rejection.

Documentation and CI workflow changes are in follow-up #5347.

Test Plan

  • Compute-provider suite: 21 files, 348 tests passed.
  • Control-plane suite: 14 files, 345 tests passed.
  • GitHub scale-set client: 4 files, 40 tests passed.
  • Scale-set service: 9 files, 67 tests passed.
  • TypeScript type-checks passed for control-plane, GitHub scale-set client, and scale-set service.
  • ESLint and Prettier passed for the changed TypeScript package scopes.
  • git diff --check and pre-commit checks passed.

Related Issues

Depends on #5312.

@edersonbrilhante
edersonbrilhante requested review from a team as code owners August 26, 2026 10:44
@github-actions

github-actions Bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Dependency Review

The following issues were found:
  • ✅ 0 vulnerable package(s)
  • ✅ 0 package(s) with incompatible licenses
  • ✅ 0 package(s) with invalid SPDX license definitions
  • ⚠️ 3 package(s) with unknown licenses.
See the Details below.

License Issues

lambdas/services/scale-set/package.json

PackageVersionLicenseIssue Type
@aws-github-runner/aws-ssm-utilNullUnknown License
@aws-github-runner/compute-providersNullUnknown License
@aws-github-runner/github-actions-scale-setNullUnknown License

OpenSSF Scorecard

Scorecard details
PackageVersionScoreDetails
npm/@aws-sdk/client-ssm ^3.1009.0 UnknownUnknown
npm/@types/node ^22.19.3 UnknownUnknown
npm/typescript ^5.9.3 UnknownUnknown
npm/@aws-github-runner/aws-ssm-util UnknownUnknown
npm/@aws-github-runner/compute-providers UnknownUnknown
npm/@aws-github-runner/github-actions-scale-set UnknownUnknown
npm/@aws-sdk/client-ssm ^3.1009.0 UnknownUnknown
npm/@octokit/auth-app 8.2.0 🟢 6.8
Details
CheckScoreReason
Code-Review🟢 10all changesets reviewed
Security-Policy🟢 9security policy file detected
Maintained🟢 57 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 5
Binary-Artifacts🟢 10no binaries found in the repo
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Pinned-Dependencies🟢 4dependency not pinned by hash detected -- score normalized to 4
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Fuzzing⚠️ 0project is not fuzzed
License🟢 10license file detected
Signed-Releases⚠️ -1no releases found
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Packaging🟢 10packaging workflow detected
SAST🟢 10SAST tool is run on all commits
npm/@octokit/request ^9.2.2 UnknownUnknown
npm/@types/node ^22.19.3 UnknownUnknown
npm/@vercel/ncc 0.38.4 🟢 7.4
Details
CheckScoreReason
Packaging⚠️ -1packaging workflow not detected
Maintained🟢 1011 commit(s) and 2 issue activity found in the last 90 days -- score normalized to 10
Code-Review🟢 10all changesets reviewed
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Token-Permissions🟢 9detected GitHub workflow tokens with excessive permissions
Binary-Artifacts🟢 10no binaries found in the repo
Pinned-Dependencies🟢 3dependency not pinned by hash detected -- score normalized to 3
License🟢 10license file detected
Fuzzing⚠️ 0project is not fuzzed
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration
Signed-Releases⚠️ -1no releases found
Security-Policy🟢 10security policy file detected
SAST⚠️ 0SAST tool is not run on all commits -- score normalized to 0
npm/typescript ^5.9.3 UnknownUnknown
npm/undici ^6.19.2 UnknownUnknown
npm/undici 6.28.0 🟢 8.2
Details
CheckScoreReason
Dependency-Update-Tool🟢 10update tool detected
Maintained🟢 1030 commit(s) and 7 issue activity found in the last 90 days -- score normalized to 10
Code-Review🟢 10all changesets reviewed
Security-Policy🟢 10security policy file detected
Token-Permissions⚠️ 0detected GitHub workflow tokens with excessive permissions
Dangerous-Workflow🟢 10no dangerous workflow patterns detected
Binary-Artifacts🟢 8binaries present in source code
CII-Best-Practices⚠️ 0no effort to earn an OpenSSF best practices badge detected
Pinned-Dependencies🟢 6dependency not pinned by hash detected -- score normalized to 6
Vulnerabilities🟢 73 existing vulnerabilities detected
Packaging🟢 10packaging workflow detected
Branch-Protection⚠️ -1internal error: error during branchesHandler.setup: internal error: some github tokens can't read classic branch protection rules: https://github.com/ossf/scorecard-action/blob/main/docs/authentication/fine-grained-auth-token.md
Signed-Releases⚠️ -1no releases found
License🟢 10license file detected
Fuzzing🟢 10project is fuzzed
SAST🟢 10SAST tool is run on all commits
CI-Tests🟢 1030 out of 30 merged PRs checked by a CI test -- score normalized to 10
Contributors🟢 10project has 63 contributing companies or organizations

Scanned Files

  • lambdas/libs/compute-providers/package.json
  • lambdas/libs/github-actions-scale-set/package.json
  • lambdas/services/scale-set/package.json
  • lambdas/yarn.lock

Comment thread lambdas/libs/github-actions-scale-set/src/client.ts Fixed
Comment thread lambdas/libs/github-actions-scale-set/src/client.ts Fixed
Comment thread lambdas/libs/github-actions-scale-set/src/config.ts Fixed
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 341697e to 3eb2808 Compare August 26, 2026 11:49
@edersonbrilhante
edersonbrilhante changed the base branch from refactor-ec2-provider-isolation to refactor-ec2-runner-orchestration-boundary August 26, 2026 11:49
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 3eb2808 to 9e47723 Compare August 26, 2026 12:43
@edersonbrilhante
edersonbrilhante marked this pull request as draft August 26, 2026 13:59
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 6ac6290 to 46d0cd5 Compare August 27, 2026 12:20
@edersonbrilhante
edersonbrilhante changed the base branch from refactor-ec2-runner-orchestration-boundary to refactor-pool-provider-test-boundary August 27, 2026 12:22
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from acf9a55 to 86ecd3a Compare August 27, 2026 19:00
@edersonbrilhante
edersonbrilhante changed the base branch from refactor-pool-provider-test-boundary to refactor-ec2-runner-orchestration-boundary August 27, 2026 19:00
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 86ecd3a to 98e3f72 Compare August 27, 2026 19:28
@edersonbrilhante
edersonbrilhante changed the base branch from refactor-ec2-runner-orchestration-boundary to refactor-ec2-orchestration-support August 27, 2026 19:28
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 98e3f72 to 1ace218 Compare August 27, 2026 19:59
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 1ace218 to dec0ffa Compare August 27, 2026 20:15
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from dec0ffa to 652dba7 Compare August 27, 2026 20:35
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 652dba7 to fb95b1a Compare August 28, 2026 11:13
Base automatically changed from refactor-ec2-orchestration-support to main September 2, 2026 17:16
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from fc51166 to 4ce2ba2 Compare September 2, 2026 17:29
Comment thread .github/workflows/lambda.yml Dismissed
Comment thread .github/workflows/release.yml Dismissed
@edersonbrilhante
edersonbrilhante force-pushed the feat-scale-set-typescript branch from 4ce2ba2 to 17e79aa Compare September 3, 2026 21:17
@edersonbrilhante edersonbrilhante added scale-set javascript Pull requests that update Javascript code labels Sep 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

javascript Pull requests that update Javascript code scale-set

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants