-
Notifications
You must be signed in to change notification settings - Fork 1
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
Implement Logging Solution #217
Comments
So far I have added the log table to the SQLite database and I have methods to manipulate the fields in it (db3656b). Next I need to add some code to keep track of the number of songs in the jam (I'm just going to track the maximum for now, ie. the max number of songs that are in the jam at any one time), and then I need to insert calls to do the logging throughout the codebase. |
With these two commits (JayThomason/tutti-server@783a69d and JayThomason/tutti-server@3799edf) I have updated the server code to remove the old server endpoints. I added the /log endpoint which takes a JSON list of jams encoded as JSON objects with four fields: the start_time (unix time client side when the jam was created), length (approx. length of jam in seconds), num_users, and num_songs). |
As of here (56dab52), all that is left to do for the logger is test it more and add an Alarm that runs every so often to dump the jams in the database to the server. |
Status update: I've started building the alarm system that will active about once per day and try to log the data in the local sqlite db to the log server (273ea64). I'm going off of this sample application to implement this functionality. |
It seems that there is no way to reliably check whether you have already set a specific alarm in the Android AlarmManager, so I've had to rely on using a shared preferences bool. As of (2bb8f78) the logger alarm will fire every ~6 hours. I changed the time down from about 1 day because I want more resolution when watching metrics over the next two weeks or so. I think that the only optimization left to be made is to ensure that the alarm is reset when the phone is turned off and back on again. |
Logger alarm is being set on reboot (ef11bc7). Gonna close this issue for now because it seems to be working. We can test tomorrow and prepare to submit to the play store. |
One of our deliverables requires that we record key metrics about app usage. These metrics might include usage time, number of songs per jam, and number of users per jam.
The design that I am considering right now looks like this:
The text was updated successfully, but these errors were encountered: