dataquest-dev / DSpace

(Official) The DSpace digital asset management system that powers your Institutional Repository
https://wiki.lyrasis.org/display/DSDOC7x/
BSD 3-Clause "New" or "Revised" License
2 stars 2 forks source link

Matomo Statistics - use handle in the URL (DSpace7 has UUID) #607

Open milanmajchrak opened 7 months ago

kosarko commented 1 month ago

na tohle jsem dneska zapomnel. Tohle se tyka item views, tedy trackovani z FE?

milanmajchrak commented 1 month ago

Rozmýšľam, čo sme chceli touto issue povedať, lebo pri trackovani Matomo requestu sa nepouživa žiadny item/bistream uuid, ani vo v5, ani vo v7. Nemysleli sme to, že pri logovani štatistik pri sťahovani bistreamov namiesto uuid logovat handle?

kosarko commented 4 weeks ago

co posila FE jako pageview? je tam handle nebo uuid? v5 podle me brala url (kterou vidim v browseru) a ta byla xmlui/handle/xxx/yyy, takze pak muzu nejak v matomu delat pageviews per handle...

co posila BE?

milanmajchrak commented 4 weeks ago

Už rozumiem. Matomo netrackuje FE requesty, na to tam maju google analytics a na FE sme Matomo neriešili.

Matomo trackuje na BE iba

kosarko commented 3 weeks ago

On je tracking-code pro matomo v (lindat-common) footeru, akorat nevim, jestli to tam zustalo i v te dspace verzi a jestli to trackuje neco rozumneho, nebo jestli to udela jen jeden hit pri nacteni footeru. To je jedna cast, druha je, ze by asi bylo lepsi v matomo videt handles nez uuids...

Ad BE tohle https://github.com/dataquest-dev/DSpace/blob/8d115daea75b9586248aab4359b6b6f28a78a980/dspace-api/src/main/java/org/dspace/app/statistics/clarin/ClarinMatomoTracker.java#L101-L108 vypada lehce podivne...vsechno setHeaderUserAgent?

milanmajchrak commented 3 weeks ago
  1. Piwik je vo footeri, len posiela requesty na lindat, dalo by sa to updatnut znova moutnutim footeru.
  2. Rozumiem, vieme zmenit UUID na handle, ale je tam problem, ze by sa tym padom zmenila cela URL. Nebude lepšie spraviť to cez segmenty? Žeby som pridal handle ako Custom Variable do Matomo requestu.
  3. Tak ten setHeaderUserAgent je chyba, fixnem to. Ďakujem za upozornenie
kosarko commented 2 weeks ago

Rozumiem, vieme zmenit UUID na handle, ale je tam problem, ze by sa tym padom zmenila cela URL. Nebude lepšie spraviť to cez segmenty? Žeby som pridal handle ako Custom Variable do Matomo requestu.

segmenty za me nejsou dobra volba viz ufal/DSpace#957, tam linknuta debata a zejmena

we changed how segments work in 3.12.0, now when you select visits based on a page url, it will return all visits and all page urls these visits did.

nebo https://matomo.org/faq/general/how-do-segments-work-when-segmenting-on-specific-actions-pages-or-events-and-how-do-i-filter-out-any-actions-that-dont-match/

custom variables taky nevypada jako spravna cesta. https://plugins.matomo.org/CustomVariables:

This feature used to be part of Matomo. However, we no longer plan to further develop custom variables and only fix important bugs or security issues and we might stop supporting Custom Variables in the future. We therefore highly recommend using Custom Dimensions instead which is directly available within your Matomo

Custom Dimensions maybe...zkusim se na to podivat

kosarko commented 1 week ago

custom dimensions po kratkym pokusu vypada, ze by melo byt pouzitelny...

milanmajchrak commented 1 week ago

Je potrebne upraviť footer, aby trackoval správne UI events - vyskúšať pridať posielanie Matomo requests v onInit metode. Ako sa to bude správať pri SSR?