Usage analytics help product managers understand the actual usage of their products.
CLIENT/API CONSIDERATIONS
The following method generates a usage heartbeat. Since the body can handle an array of usage heartbeats, you can send data for multiple usage features at once.
POST /isv/{isv_id}/data_gathering/usage_heartbeats
It is critical, both for your application and your SLASCONE environment, that usage heartbeats are generated in an optimal way. In most cases, you should avoid sending usage heartbeats in real time, as doing so could potentially significantly slow down your application. Instead, it is recommended to:
- collect them locally
- aggregate them (if applicable)
- send ONE (aggregated) usage heartbeat
Let us assume an example, with two usage features A and B. Let us assume that Feature A was called 10 times in the last hour, whereas Feature B was called 5. Instead of sending 15 usage heartbeats, it is recommended to send ONE usage heartbeat with the values 10 and 5 for Features A and B, respectively.
FREQUENCY
The frequency in which you send usage heartbeats depends on your application type. Usually the following applies:
- Web/SaaS applications: every X hours, typically 24 hours.
- Desktop/Mobile Applications: on program/session close, latest after X hours (in order to address zombie sessions).
GRANULARITY
Obviously, by sending aggregated usage heartbeats, the data granularity is reduced. However, the granularity is not required to correspond to the use heartbeat frequency: Therefore, you may send a usage heartbeat every 24 hours for the complete 24 hours, or you may send a usage heartbeat every 24 hours comprising six-hour chunks. The granularity in the latter case is six hours.
Nevertheless, it is obviously less complex if the granularity does match the frequency.
TIMESTAMP
The timestamp field is optional in usage heartbeats. If omitted, SLASCONE uses the current time as the timestamp for the heartbeat. The timestamp field enables you to customize the data's granularity.
Comments
0 comments
Please sign in to leave a comment.