Skip to content

Commit

Permalink
chore: document how to add support for a new node major versions (#4590)
Browse files Browse the repository at this point in the history
Resolves #4581

---

By submitting this pull request, I confirm that my contribution is made under the terms of the [Apache 2.0 license].

[Apache 2.0 license]: https://www.apache.org/licenses/LICENSE-2.0
  • Loading branch information
iliapolo authored Jul 29, 2024
1 parent 562c286 commit e504b28
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 1 deletion.
19 changes: 19 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,3 +240,22 @@ be released after a last validation build.

The latest release information (for both of the Docker image tags) can be seen
on [ECR Public Gallery](https://gallery.ecr.aws/jsii/superchain)

## Support for new Node Major versions

When a new major version of node is released, we need to update the `@jsii/check-node` package.
This package is responsible for identifiying which node version is being used by the current process,
whether or not it is supported and tested, and produces appropriate warnings in case it isnt.

> Note that `jsii` will execute on every node version, so "adding support" here only means supressing or showing
> warnings that inform the user on the level of support it has.
### Steps

1. Add a `new NodeRelease(...)` to [constants.ts](./packages/@jsii/check-node/src/constants.ts)
2. If its an LTS version, add the new node version to our testing matrix in [main.yml](./.github/workflows/main.yml) and [docker-images.yml](./.github/workflows/docker-images.yml).

### Useful Resources

- [https://endoflife.date/nodejs](https://endoflife.date/nodejs)
- [Adding support for node 22 PR](https://github.com/aws/jsii/pull/4489)
2 changes: 1 addition & 1 deletion packages/@jsii/check-node/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ export class NodeRelease {
untested: true,
}),
new NodeRelease(19, { endOfLife: new Date('2023-06-01'), untested: true }),
new NodeRelease(21, { endOfLife: new Date('2024-06-01'), untested: true }),

// Currently active releases (as of last edit to this file...)
new NodeRelease(18, { endOfLife: new Date('2025-04-30') }),
new NodeRelease(20, { endOfLife: new Date('2026-04-30') }),
new NodeRelease(21, { endOfLife: new Date('2024-06-01'), untested: true }),
new NodeRelease(22, { endOfLife: new Date('2027-04-30') }),

// Future (planned releases)
Expand Down

0 comments on commit e504b28

Please sign in to comment.