e-ucm / unity-tracker

Unity gleaner tracker that uses csharp-tracker

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Missing file used to start NetStorage

wvdvegt opened this issue · comments

Hi
Can you please tell me what should go inside the /Assets/track.txt file that is loaded from disk to start the NetStorage class?

The format and instructions is also fine.

Also not described is if the 'a:' value for the authorization field in NetStorage is a correct value or a dummy.

Finally I assume the trackingCode is the hash of the game for which traces are to be stored.

Best Regards
Wim van der Vegt / OUNL

In track.txt, you need write the host and the tracking code associated to the game in analytics-frontend
https://github.com/e-ucm/rage-analytics/wiki/Tracking-code
track.txt format is:

host;trackingCode

a: authorization value means that the player is anonymous, he don't have account in a2/analytics-frontend.

Best Regards

Hi

Thanks, but it still remains a bit unclear:

  1. does the host entry contain just the host name or the full url to the api endpoint including the port number?
  2. And if so what is the correct endpoint. In the tracker website i see documentation about two sets of api (one at port 3000 and one at 3300 if my memory is correct). Unclear is, from documentation, what port numbers to use,

I can already perform simple calls like health & login on the 3000 port but everything related to this app keeps returning 4xx errors (either not found or access denied).

Best Regards
Wim van der Vegt / OUNL

Happy Christmas!

  1. The host entry contains the full url to the endpoint. An example is
    publicly-exposed-ip:3000/api/proxy/gleaner/:xyz where the xyz bit is the tracking code as returned when a game is registered by a developer; and the publicly-exposed-ip is the publicly visible IP of the server that is running all those docker containers. I don't remember if you have to write 'collector/' or not - Antonio can correct me if I am wrong.

  2. All access to the back-end API (and other analytics server-side assets) should be done via A2 - therefore, via publicly-exposed-ip:3000.

The 4xx errors can be broken into 2 categories: some are due to sloppy programming, and can be removed (eg.: looking for a list of available games before logging in, when those are only available after you have logged in). And the second category is mostly due to not being authenticated before attempting to perform certain requests. Please send the logs of a2 so that we can tell them apart.

The host entry, in the track.txt file contains publicly-exposed-ip:3000/api/proxy/gleaner/collector/ and the tracker code sends two diferent POST calls using this host.
publicly-exposed-ip:3000/api/proxy/gleaner/collector/start/"trackingCode" and publicly-exposed-ip:3000/api/proxy/gleaner/collector/track

The /collector/start return

{
           authToken: <String>,     //Used as 'Authorization' header for '/api/collector/track' requests.
           objectId: <String>,         //Used as Object.id in the following xAPI statements.
           actor: Object                 //https://github.com/adlnet/xAPI-Spec/blob/master/xAPI.md#actor
 }

http://e-ucm.github.io/rage-analytics-backend/#api-Collector