Skip to content

Add Node 18 - 26 support (possible to add 27 in later) - #134

Open
GroophyLifefor wants to merge 1 commit into
mainfrom
node-across-support
Open

Add Node 18 - 26 support (possible to add 27 in later) #134
GroophyLifefor wants to merge 1 commit into
mainfrom
node-across-support

Conversation

@GroophyLifefor

Copy link
Copy Markdown
Member
  • Fixed import.meta.dirname (needs Node 20.11+) in CLI/runner-local-docker → replaced with stdlib dirname(fileURLToPath(import.meta.url)).
  • Fixed import.meta.main/import.meta.filename (needs Node 22.12+/20.11+) in all perf/load/*/index.mjs entrypoints — on Node 18 both are undefined, so the server never started and the load runner hung silently. Replaced with the portable import.meta.url === pathToFileURL(process.argv[1]).href check.
  • Added engines: ">=18" to package.json.
  • Added a Node version matrix (18, 20, 22, 24, 26) to pr.yml; fixed an artifact-name collision in load.yml/compare.yml that would've broken parallel matrix runs, and a missing node input in compare.yml.

Verified load and compare end-to-end on Node 18.20.8 and 20.20.2.

ref: #47

- Added Node.js engine requirement (>=18) to package.json and package-lock.json.
- Updated GitHub Actions workflows to accept Node.js version as an input for baseline, test, and compare jobs.
- Modified artifact naming in workflows to include Node.js version for better traceability.
- Refactored path handling in CLI scripts to use `fileURLToPath` for improved compatibility.
Comment thread package.json
"author": "",
"license": "MIT",
"engines": {
"node": ">=18"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that Node 18 is EOL do we want to worry about it here and do performance reporting for 18?

Might not be good to release stats using it if it's not being patched anymore

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My two cents: what matters here is supporting Express 5’s minimum supported version (Node 18) and the latest LTS (Node 26). We don’t really care about the versions in between.

Comment thread .github/workflows/pr.yml
name: Run Baseline Load Tests (node ${{ matrix.node }})
strategy:
matrix:
node: [18, 20, 22, 24, 26]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment about Node 18

Comment thread .github/workflows/pr.yml
name: Run Test Load Tests (node ${{ matrix.node }})
strategy:
matrix:
node: [18, 20, 22, 24, 26]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

Comment thread .github/workflows/pr.yml
needs: [baseline, test]
strategy:
matrix:
node: [18, 20, 22, 24, 26]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

artifactName:
description: "Artifact name for results"
value: perf-load-test-${{github.run_id}}
value: perf-load-test-${{github.run_id}}-${{inputs.node}}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These two will overlap so 2nd is rejected

uses: actions/upload-artifact@v4
with:
name: perf-load-test-${{github.run_id}}
name: perf-load-test-${{github.run_id}}-${{inputs.node}}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2nd

Comment thread .github/workflows/pr.yml
matrix:
node: [18, 20, 22, 24, 26]
uses: ./.github/workflows/load.yml
with:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would propose that we upload with separate artifact names here and same below

Then in load.yml:

inputs:
  artifactName:
    required: true
    type: string

@O4FDev O4FDev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request perf-wg-agenda

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

3 participants