Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Add ability for clients to pass custom events #12
There are some event types that are common across all client apps.
However, apps might want to collect more flexible data. For example, Atom currently collects "file open" events, which preserve the grammar (e.g. language) of the opened file. That way we can answer questions like "what languages are most popular among users of Atom? (More on that in #8 (comment)).
This pull request adds the ability for
Jun 14, 2018
@annthurium: Thanks for the ping.
Following up on #12 (comment), I'd still like to recommend that we don't think of "custom events" as "custom." Quite the contrary: I think this should be the default/recommended way of recording events. These events provide richer information (by automatically including the timestamp of the event and supporting arbitrary metadata), and they're consistent with the event reporting approach in commonly-used tools like Google Analytics and Datadog.
To me, the simple usage counts are a more custom concept for a metrics library to provide. Along those lines, if we wanted to do so, I think we could implement the simple usage counts in terms of the more generic events implemented in this PR. For example, for events that should be aggregated locally and reported to the metrics backend on a daily basis:
Would you consider changing the terminology of "custom events" in the code and in the docs to remove the "custom" phrasing and refer to them as the primary way that clients should record event data?
I don't think "custom" implies "not the default." I think it implies "flexibility to send whatever data you want." I'm going to run these names past a few other devs and see how they interpret it and then get back to you - that way we have a few more data points about the clarity (or lack thereof) of this terminology. :-) thanks for bringing it up!