Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Please note that this work has been funded by University of Maryland
References
Description
This PR adds an integration with Matomo, the most used alternative to Google Analytics. The code lies on top of the solutions previously adopted for Analytics. An Orejime cookie for tracking purposes with Matomo has been added.
Instructions for Reviewers
List of changes in this PR:
ngx-matomo-client
in DSpace;In order to test this PR, a Matomo instance needs to be up and running. Follow the instructions on this PR to setup and integrate with DSpace a self hosted Matomo instance. You can also use a Matomo Cloud instance (a free demo of 30 days is available).
Two new attributes in settings are needed.
trackerUrl
is the endpoint of the Matomo instance, whilesiteId
is used to distinguish different sites on the same Matomo instance - e.g. for communication with a self-hosted Matomo instance listening on the default port, this is the correct value of thematomo
settings object:If there is no
matomo.sideId
ormatomo.trackerUrl
property, the Orejime cookie for Matomo will not show up.Then, if the cookie is not accepted, the Matomo tracking will not start.
As soon as the Matomo cookie is accepted, user actions on DSpace should be logged onto Matomo.
Checklist
main
branch of code (unless it is a backport or is fixing an issue specific to an older branch).npm run lint
npm run check-circ-deps
)package.json
), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.