-
Notifications
You must be signed in to change notification settings - Fork 48
fix(addon): fix Matomo add-on creation #1043
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
Conversation
|
🔎 The preview has been automatically deleted. |
florian-sanders-cc
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, some suggestions to match our conventions & make it slightly more robust but it could be merged as it is (tested locally as well just in case 😉)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah! Forgot to check the commit message: Could we reword it so that users (not contributors to this project) understand the issue that it fixes for them? (Again, this is an issue with using our conventional commits for changelog, consumers don't expect the same info as reviewers / contributors)
Something that would mention that we've fixed Matomo addon creation 🤔
e13b7b5 to
d0519d6
Compare
Matomo add-on creation was failing with a 404 error due to incorrect API path construction. This fix ensures the correct provider ID is used for operator API calls.
d0519d6 to
3f20b65
Compare
Pierre said it was OK 😉
Closes #1042
Context
Creating a Matomo addon failed with a 404 error because the operator API path was constructed incorrectly. The v4 operator APIs use paths like
/v4/addon-providers/addon-${provider}/addons/..., which adds anaddon-prefix. Forproviders like
addon-matomo, passing the full provider name resulted inaddon-addon-matomo.This inconsistency in provider naming only affects Matomo among the operators (keycloak, metabase, otoroshi don't have the
addon-prefix in their keys).Solution
Replace the
isOperatorboolean with an explicitoperatorProviderstring that specifies the exact provider name to use in API calls. This allows each provider to declare the correct string needed for the operator API path, avoiding the duplicate prefix issue.addon-matomo→operatorProvider: 'matomo'keycloak→operatorProvider: 'keycloak'(unchanged behavior)kv,addon-pulsar) simply omit the property