Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Update to node22 + remove 18 #5332

Merged
merged 8 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: [18, 20, 22]
node-version: [20, 22]
steps:
- uses: actions/checkout@v4
- run: git fetch --depth=1
Expand Down
309 changes: 0 additions & 309 deletions V3-Upgrade-Guide.md

This file was deleted.

35 changes: 35 additions & 0 deletions V4-Upgrade-Guide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# SAP Cloud SDK for JavaScript Version 4 Upgrade Guide <!-- omit from toc -->

The purpose of this document is to collect information on the Cloud SDK version 3 to version 4 migration.
It should include information on all steps a user needs to take when updating the SDK version from 3 to 4.

This document should be written in a style which addresses the consumer of the SDK.
It will eventually end up in the SDK docs portal and release notes for version 4.

Please add your items below when creating a change which will involve manual tasks for the user when performing the upgrade.
Add sections to the document as you see fit.

<!-- Everything below this line should be written in the style of end user documentation. If you need to add hints for SDK developers, to that above. -->

# How to Upgrade to Version 4 of the SAP Cloud SDK for JavaScript <!-- omit from toc -->

This document will guide you through the steps necessary to upgrade to version 4 of the SAP Cloud SDK.
Depending on your project, some steps might not be applicable. The To-Do list is:
deekshas8 marked this conversation as resolved.
Show resolved Hide resolved

- [Update Your Project Dependencies](#update-your-project-dependencies)
- [Update to Node 22 or Newer](#update-to-node-22-or-newer)

## Update Your Project Dependencies

Search for occurrences of `@sap-cloud-sdk/[some module]` in your `package.json` files.
Replace the version numbers with `^4`.
Depending on if you're using `npm` or `yarn`, run `npm install` or `yarn` in the directories of your `package.json` files to update the `package-lock.json` or `yarn.lock` file.
deekshas8 marked this conversation as resolved.
Show resolved Hide resolved
deekshas8 marked this conversation as resolved.
Show resolved Hide resolved

Running your tests or deploying your application might fail at this point in time if you need to adapt to any breaking changes.
deekshas8 marked this conversation as resolved.
Show resolved Hide resolved
We recommend updating your applications in one commit or pull request and making sure everything still works using your existing test suite.

## Update to Node 22 or Newer

All SAP Cloud SDK for JavaScript libraries now support node 22 (LTS) as the **minimum** node version.
If you are using a node version older than 22, update your runtime environment to a newer version.
On Cloud Foundry you can do this by [setting the node engine in your `package.json`](https://docs.cloudfoundry.org/buildpacks/node/index.html#runtime).
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
"@types/jsonwebtoken": "^9.0.7",
"@types/license-checker": "^25.0.6",
"@types/mock-fs": "^4.13.4",
"@types/node": "^18.19.68",
"@types/node": "^22.0.0",
"@types/uuid": "^10.0.0",
"@types/voca": "^1.4.6",
"axios": "^1.7.9",
Expand Down
14 changes: 13 additions & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1950,13 +1950,20 @@
resolved "https://registry.npmjs.org/@types/node/-/node-12.20.55.tgz#c329cbd434c42164f846b909bd6f85b5537f6240"
integrity sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==

"@types/node@^18.19.68", "@types/node@^18.19.7":
"@types/node@^18.19.7":
version "18.19.68"
resolved "https://registry.npmjs.org/@types/node/-/node-18.19.68.tgz#f4f10d9927a7eaf3568c46a6d739cc0967ccb701"
integrity sha512-QGtpFH1vB99ZmTa63K4/FU8twThj4fuVSBkGddTp7uIL/cuoLWIUSL2RcOaigBhfR+hg5pgGkBnkoOxrTVBMKw==
dependencies:
undici-types "~5.26.4"

"@types/node@^22.0.0":
version "22.10.5"
resolved "https://registry.npmjs.org/@types/node/-/node-22.10.5.tgz#95af89a3fb74a2bb41ef9927f206e6472026e48b"
integrity sha512-F8Q+SeGimwOo86fiovQh8qiXfFEh2/ocYv7tU5pJ3EXMSSxk1Joj5wefpFK2fHTf/N6HKGSxIDBT9f3gCxXPkQ==
dependencies:
undici-types "~6.20.0"

"@types/nodemailer@^6.4.17":
version "6.4.17"
resolved "https://registry.npmjs.org/@types/nodemailer/-/nodemailer-6.4.17.tgz#5c82a42aee16a3dd6ea31446a1bd6a447f1ac1a4"
Expand Down Expand Up @@ -9710,6 +9717,11 @@ undici-types@~5.26.4:
resolved "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617"
integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==

undici-types@~6.20.0:
version "6.20.0"
resolved "https://registry.npmjs.org/undici-types/-/undici-types-6.20.0.tgz#8171bf22c1f588d1554d55bf204bc624af388433"
integrity sha512-Ny6QZ2Nju20vw1SRHe3d9jVu6gJ+4e3+MMpqu7pqE5HT6WsTSlce++GQmK5UXS8mzV8DSYHrQH+Xrf2jVcuKNg==

undici@^5.25.4:
version "5.28.4"
resolved "https://registry.npmjs.org/undici/-/undici-5.28.4.tgz#6b280408edb6a1a604a9b20340f45b422e373068"
Expand Down
Loading