Skip to content

Conversation

@hsablonniere
Copy link
Member

@hsablonniere hsablonniere commented Jan 26, 2026

Context

The add-on logs endpoint is currently using the v2 API. The v4 API relies on a more modern stack, making it the preferred choice going forward.

Proposal

  • Migrate add-on logs to use the v4 API endpoint
  • Rename log-v4.js to log.js since v4 is now the standard
  • Remove the old log-v4.js file (now consolidated into log.js)

Note

Temporarily, the service filter has been set to all in a separate commit (chore: wip add service all). This is a work in progress and may need further refinement.

Test plan

  • Test add-on logs streaming
  • Test add-on logs with different filter options
  • Verify backward compatibility with existing CLI usage

TODO

  • Remove temporary service=all

@github-actions
Copy link

github-actions bot commented Jan 26, 2026

🔎 A preview has been automatically published!

If you created the alias to the preview script, you can run this command to download and install this preview:

clever-preview update addon-logs-v2-to-v4

You can also run it from your local repository:

./scripts/preview.js update addon-logs-v2-to-v4
OS SHA256 checksum
🐧 linux ee5d4b22b682f9792f167f66d033b14cd54383b9b4614b22ab1a3538ffa1d6da
🍏 macos 1d4d661893cb15837eb4092bb8959a2642c266e52b7ecd0cc145ccfa01dc6fd2

This preview will be deleted once this PR is closed.

@hsablonniere hsablonniere mentioned this pull request Jan 26, 2026
2 tasks
@hsablonniere hsablonniere added this to the 4.6.0 milestone Jan 26, 2026
@hsablonniere hsablonniere marked this pull request as ready for review January 27, 2026 17:04
@hsablonniere hsablonniere requested a review from a team as a code owner January 27, 2026 17:04
Copy link
Contributor

@florian-sanders-cc florian-sanders-cc left a comment

Choose a reason for hiding this comment

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

Tested the command with a redis and it worked fine 👍
The code LGTM!

Copy link
Contributor

@pdesoyres-cc pdesoyres-cc left a comment

Choose a reason for hiding this comment

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

Nearly there, I've experienced a strange issue (that was present on application logs before this PR)

Use ResourceLogStream for addon logs instead of the v2 API.
This enables all log formats (human, json, json-stream) for add-ons.
Now that the v2 log API is gone, rename the file to its original name.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants