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

Update modules for v5 #5116

Open
jsumners opened this issue Oct 23, 2023 · 51 comments
Open

Update modules for v5 #5116

jsumners opened this issue Oct 23, 2023 · 51 comments
Labels
v5.x Issue or pr related to Fastify v5

Comments

@jsumners
Copy link
Member

jsumners commented Oct 23, 2023

To prepare for v5 we need to go through the list of repositories in this issue and:

  1. Determine if the module/project should be archived and marked as deprecated. Mostly we should look at the commit history to determine if the community is interested in the module/project. A secondary check would be inspecting the data for the module at npm-stat.com. Unless we have people using, and contributing to modules, we should be reducing our maintenance burden by archiving them.
  2. Evaluate if the module/project needs any updates. Most likely this will simply mean updating dependencies, dropping Node <= 16, and updating CI configuration accordingly (see footnote 1). Note: we must pin tap@16.3.9 for any projects utilizing it. See Update modules for v5 #5116 (comment) for a required change related to this. Blue Oak is now OSI approved (https://opensource.org/license/blue-oak-model-license/), thus solving the licensing issue on this dependency.

If you are interested in helping with any of these, please create a new issue in the repo you're interested in that has the title "Updating for v5" and a body with something like "👋 I'm X, and would like to work on this." It should also include a link back to this issue. After that issue is created, a member of the Fastify team will create a next branch for you to target. Once that branch is created, you will be able to start a new Pull Request that targets it. We will help out with any questions you may have.


Footnote 1

Regarding updating the CI configuration in these projects. Most projects in the list should have a CI workflow that looks like https://github.com/fastify/fast-content-type-parse/blob/4de4e57f2d2c2893094c2a46069e04767b179d8e/.github/workflows/ci.yml#L1-L23. Thus, we have a few possible changes:

  1. If a project has a different configuration that the one linked in the previous paragraph, it is likely that the configuration should be update to match it.
  2. If the project is using the linked configuration, it should be updated to reference the v4 tag of the worklows repo once issue Create a v4 set workflows#106 has been resolved.
  3. If it is determined that the shared configuration should not be used for the project, the configuration should be updated as outlined at the top of this issue.
@jsumners jsumners pinned this issue Oct 23, 2023
@Uzlopak
Copy link
Contributor

Uzlopak commented Oct 23, 2023

@mcollina

Did you get feedback from openjs regarding tap v18 used as dev dependency?

@Fdawgs
Copy link
Member

Fdawgs commented Oct 27, 2023

Majority of the repos are using the shared workflows so CI changes should be easy enough.

I'll hop on that.

@EliphazBouye
Copy link

@jsumners I've just created a issue to work on fastify/rate-limit plugin the link : fastify/fastify-rate-limit#333

@gurgunday
Copy link
Member

Note: we must pin tap@16.3.9 for any projects utilizing it.

Should we pin specifically to tap@16.3.9 or is ^16 sufficient?

@gurgunday
Copy link
Member

Also, maybe we can also work on centralizing all CI workflows (and possibly most scripts) during this release cycle

I see that some repos use plugins-ci, which is great, but others use dedicated workflows

WDYT?

CC @Eomm

@jsumners
Copy link
Member Author

Note: we must pin tap@16.3.9 for any projects utilizing it.

Should we pin specifically to tap@16.3.9 or is ^16 sufficient?

16.3.9 is the last release in the accepted release line. It should be pinned explicitly as an indicator of intention

@Eomm
Copy link
Member

Eomm commented Oct 30, 2023

Also, maybe we can also work on centralizing all CI workflows (and possibly most scripts) during this release cycle

We have centralized all the main extranal software such as redis. so I think it is a matter of missing PR or unsupported versions

Right now the releases are going to change: we are waiting the OpenJS Foundation as npm provenance signature host

@Fdawgs
Copy link
Member

Fdawgs commented Nov 2, 2023

As part of pinning tap, Dependabot configs also needs to be updated to ignore major tap versions to stop it from opening PRs, see:

ignore:
- dependency-name: tap
update-types: ["version-update:semver-major"]

@Eomm
Copy link
Member

Eomm commented Nov 2, 2023

A reminder that we have this notion page to see all the public repos and download stats:

@nrayburn-tech
Copy link

Just wanted to put a checklist of items to look at when updating a package that I have found so far. These won't apply for every repo, but they should be checked if they apply or not for every repo. I'll keep adding to this as I find anything else. (Feel free to edit/update this comment or copy it into the main issue summary.)

@Fdawgs
Copy link
Member

Fdawgs commented Nov 20, 2023

We may not need to pin tap: openjs-foundation/cross-project-council#1170 (comment)

@jsumners
Copy link
Member Author

I am keeping up with that thread (as you probably can see). I will update the task list here if it comes about in time that Blue Oak is authorized. But we can bump tap at any time without affecting the major-ness of any releases.

@Uzlopak Uzlopak added the v5.x Issue or pr related to Fastify v5 label Dec 9, 2023
@Uzlopak
Copy link
Contributor

Uzlopak commented Dec 9, 2023

Maybe we should archive the docs-chinese, docs-portuguese and docs-korean, as there is basically no activity.

@mcollina
Copy link
Member

We can not upgrade tap in any repo that supports node v14, so it'd be a Fastify v5 affair.

As far as it seems, Blue Oak is on track to be OSI approved in a month. If it's not, then we would need to migrate (seems very unlikely).

@mcollina
Copy link
Member

I think it's mostly safe for v5 to upgrade to latest tap.

@gurgunday
Copy link
Member

fastify-dx is archived, it can be marked as done

@synapse
Copy link

synapse commented Mar 22, 2024

Hey everyone, us, the team at Nearform has been doing an amazing job over the past week to upgrade as many plugins as possible to be ready for Fastify v5. We've also put together a comprehensive list of all the plugins, along with additional links to the PRs we've opened and NPM Stats for repositories that we believe are no longer in use or not worth upgrading. However, the decision on whether to upgrade these repositories is ultimately up to you.

❌ - closed without merge
👍 - done by us + merged
✅ - done by somebody else
⏱️ - done by us - not merged yet
☠️ - we consider that this repo should be archived (up to you)
🧰 - working on this
❓ - doubts/questions
⚠️ - has issues upgrading

  • accept-negotiator
  • action-pr-title ☠️ NPM Stats
  • ajv-compiler
  • any-schema-you-like ☠️ NPM Stats
  • avvio ✅
  • aws-lambda-fastify ✅
  • benchmarks ☠️ NPM Stats
  • busboy ⏱️ (@synapse) PR
  • compile-schemas-to-typescript ☠️ NPM Stats
  • create-fastify ☠️❓ NPM Stats
  • csrf ⏱️ (@synapse) PR
  • csrf-protection
  • deepmerge ⏱️ PR
  • deprecate-modules ☠️ NPM Stats
  • docs-chinese ☠️ NPM Stats
  • docs-korean ☠️ NPM Stats
  • docs-portuguese ☠️ NPM Stats
  • env-schema 🧰 (@synapse)
  • example
  • fast-json-stringify ⏱️ (@synapse) PR
  • fast-json-stringify-compiler
  • fast-proxy
  • fast-uri
  • fastify
  • fastify-accepts 👍 (@bilalshareef) PR
  • fastify-accepts-serializer ⏱️ (@bilalshareef) PR
  • fastify-api ☠️❓ NPM Stats
  • fastify-auth 👍 (@synapse) PR
  • fastify-autoload
  • fastify-awilix ⏱️ (@bilalshareef) PR
  • fastify-basic-auth ⏱️ (@synapse) PR
  • fastify-bearer-auth
  • fastify-caching ✅
  • fastify-circuit-breaker 👍 (@bilalshareef) PR
  • fastify-citgm ☠️ NPM Stats
  • fastify-cli
  • fastify-compress
  • fastify-cookie ✅
  • fastify-cors 👍 (@bilalshareef) PR
  • fastify-diagnostics-channel ☠️ NPM Stats
  • fastify-dx ✅
  • fastify-early-hints 🧰 (@bilalshareef)
  • fastify-elasticsearch
  • fastify-env 👍 (@bilalshareef) PR
  • fastify-error ⏱️ (@synapse) PR
  • fastify-etag 👍 (@bilalshareef) PR
  • fastify-example-todo ☠️ NPM Stats
  • fastify-example-twitter ☠️ NPM Stats
  • fastify-express 👍 (@synapse) PR
  • fastify-flash ⏱️ (@synapse)
  • fastify-formbody 👍 (@synapse) PR
  • fastify-funky ☠️ NPM Stats
  • fastify-helmet 👍 (@synapse) PR
  • fastify-hotwire ☠️ NPM Stats
  • fastify-http-proxy
  • fastify-jwt ⏱️ (@synapse) PR
  • fastify-kafka ☠️❓ (peak around 10) NPM Stats
  • fastify-leveldb ☠️ NPM Stats
  • fastify-mongodb ⏱️ (@synapse) PR
  • fastify-multipart ❌ (@synapse) PR
  • fastify-mysql ⏱️ (@synapse) PR
  • fastify-nextjs ⏱️ (@synapse) PR
  • fastify-oauth2 ⏱️ (@synapse) PR
  • fastify-passport ⏱️ (@synapse) PR
  • fastify-plugin ⏱️ (@synapse) PR
  • fastify-postgres 👍 (@synapse) PR
  • fastify-rate-limit ✅
  • fastify-redis ⏱️ (@synapse) PR
  • fastify-reply-from ⚠️ problematic upgrade
  • fastify-request-context 👍 PR
  • fastify-response-validation
  • fastify-routes 👍 (@bilalshareef) PR
  • fastify-routes-stats
  • fastify-schedule 👍 (@bilalshareef) PR
  • fastify-secure-session 👍 (@bilalshareef) PR
  • fastify-sensible 👍 (@bilalshareef) PR
  • fastify-snippet ☠️ NPM Stats
  • fastify-soap-client ☠️ NPM Stats
  • fastify-starter-codesandbox ☠️ NPM Stats
  • fastify-static ⏱️ (@bilalshareef) PR
  • fastify-swagger
  • fastify-swagger-ui
  • fastify-test ☠️ NPM Stats
  • fastify-throttle
  • fastify-type-provider-fluent-json-schema ☠️ NPM Stats
  • fastify-type-provider-json-schema-to-ts ☠️ NPM Stats
  • fastify-type-provider-typebox ☠️ NPM Stats
  • fastify-typescript-extended-sample ☠️ NPM Stats
  • fastify-url-data ✅
  • fastify-vite ❓ (not sure what to do with this)
  • fastify-websocket ⏱️
  • fastify-zipkin ☠️ NPM Stats
  • fluent-json-schema
  • forwarded
  • gh-issues-finder ☠️ NPM Stats
  • github-action-merge-dependabot ☠️ NPM Stats
  • graphics
  • help
  • json-schema-ref-resolver
  • light-my-request
  • manifetch
  • middie
  • one-line-logger
  • pacchetto
  • point-of-view
  • pre-commit
  • process-warning
  • proxy-addr
  • releasify
  • restartable
  • safe-regex2
  • secure-json-parse
  • semver-major-release-script
  • send
  • session
  • skeleton
  • tsconfig
  • under-pressure
  • vite-plugin-blueprint
  • website
  • workflows ✅

@gurgunday
Copy link
Member

This is absolutely amazing, especially since I also had some ideas about archiving a few of the repos

Thank you so much

@gurgunday
Copy link
Member

@synapse small issue with the list showing dead packages, some packages were checked against the wrong names

For instance we should check for @fastify/accept-negotiator instead, which is downloaded 1 million times a week, and not 0

These (and potentially others) seem to be wrong:
https://www.npmjs.com/package/accept-negotiator
https://www.npmjs.com/package/action-pr-title
https://www.npmjs.com/package/github-action-merge-dependabot

I can't edit comments so can't fix it manually, would be appreciated if you could take a look

@synapse
Copy link

synapse commented Mar 25, 2024

Hey @gurgunday sorry for that, I've rechecked all repos previously marked as to be archived. Indeed the NPM naming was different from the repo name. I've updated them, fortunately there were only a few of them off. I also left you the markdown source there in case you want to update the main one.
Let me know if there are thing that seem off

@Fdawgs
Copy link
Member

Fdawgs commented Apr 22, 2024

Ah crud, just realised we missed something.
We need to update the plugin version across all of them, for example:
https://github.com/fastify/under-pressure/blob/7eca099076d525dea037405582f0cd48ee593cf3/index.js#L312

@gurgunday
Copy link
Member

I think someone said doing that without first releasing a version of v5 causes a crash?

Haven't looked at the code though so not sure

@nrayburn-tech
Copy link

The fastify plugin seems to support multiple versions by using Semver ranges. https://github.com/fastify/fastify-plugin?tab=readme-ov-file#fastify-version

Somebody from the fastify team should probably share what is expected, but I would guess something like the below.

  • if the plugin only supports v4 today, update it to only support v5 on the next branch.
  • If the plugin supports multiple versions then the plugin probably needs an issue created and a discussion to decide how to move forward.

Once the next branch is updated, if it only supports v5 then that branch won’t be usable until a v5 version is released. It might make sense to wait for an alpha or beta version of v5 that can be used before making that change. Or, doing an alpha release solely for this reason.

@Fdawgs
Copy link
Member

Fdawgs commented Apr 23, 2024

I think someone said doing that without first releasing a version of v5 causes a crash?

Ah yeah, good point. Ignore me 😹

@gurgunday
Copy link
Member

@nrayburn-tech yeah next plugins will definitely only support v5 (and node LTS versions >=18) in general — that's been the case in previous cycles

We should release an alpha/beta very soon, as soon as we can rebase next

Then we (or @Fdawgs, who is good at this 😄) can run a script to mass update next plugins to change that plugin version

@puskin94
Copy link
Contributor

it looks all the plugins / repos are in one of this 2 statuses:

  1. a PR for reaching v5 has been submitted and merged
  2. a PR for reaching v5 has been submitted and it is in the review status

v5 is near 🥳

@simoneb
Copy link
Contributor

simoneb commented Apr 23, 2024

Thanks everybody. I'd like to mention especially @synapse, @bilalshareef, @puskin94 and @Gesma94 who have contributed this work on behalf of Nearform.

@simoneb
Copy link
Contributor

simoneb commented Apr 25, 2024

Is there anything else that needs support to get this over the line?

@gurgunday
Copy link
Member

Other than a few small issues in repos like restartable and autoload, we're nearly done with plugin updates

I will propose archiving a few plugins, so I haven't updated them, but the rest is complete I think

We should start doing prereleases of v5 soon

@simoneb
Copy link
Contributor

simoneb commented Apr 25, 2024

If there's any other support needed, just ping me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
v5.x Issue or pr related to Fastify v5
Projects
Status: Todo
Development

No branches or pull requests