Skip to content
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

Activity analytics #2

Closed
Minoru opened this issue Apr 15, 2015 · 5 comments
Closed

Activity analytics #2

Minoru opened this issue Apr 15, 2015 · 5 comments
Assignees
Labels
Milestone

Comments

@Minoru
Copy link
Member

Minoru commented Apr 15, 2015

This is feature two of the three that @ForNeVeR originally envisioned.

Gestalt should monitor commits to the repositories belonging to the organization and report per-user and per-repo statistics (probably with weekly and monthly averages).

@Minoru Minoru added this to the 0.1 milestone Apr 15, 2015
@ForNeVeR
Copy link
Member

Well, I don't like this overall [ { "type": "user_stats" }, { "type": "repo_stats" } ] structure. It was useful for streaming data such as news, but it will introduce more problems for any unsorted data. I'd suggest the following:

{ "repos": [ { "name": "world-domination",
               "url": "https://github.com/codingteam/world-domination",
               "day_average": 15,
               "week_average": 1050,
               "month_average": 100500 } ],
  "users": [ { "name": "Minoru", 
               "url": "https://github.com/Minoru",
               "day_average": 15,
               "week_average": 1050,
               "month_average": 100500 } ],
}

And maybe we will want to introduce separate URLs for every user and repo later (if we'll add more time-expensive metrics and/or if the existing metrics suddenly become expensive).

Also I think there was a problem with "repo-url" key - you seem to be using underscores in keys, let's stick with them. (And I've fixed that in proposed format by replacing it with "url" anyway.)

@Minoru
Copy link
Member Author

Minoru commented Apr 18, 2015

Yes, using the array was a bad idea; dictionary is better.

Your proposed format seems to be missing the point of the feature, though — we want something like "average number of commits over some periods of time", and it's nowhere to be found in your dicts.

repo-url was a typo, thank you. Fixed.

It also occurred to me that we should specify how exactly the commits are counted. With DVCS it's possible for a developer to code away for a week without pushing anything, and then suddenly we have all those commits pushed to all those repositories. How should we handle this? I see two approaches:

  • use pushes' dates. That's simple enough: the user above will have 0 average for a week but a big number for today;
  • use commits' dates. That's slighly harder (we need to crawl the commits and extract the dates) and might be counterintuitive to less adept DVCS users (people who weren't even in the top 10 suddenly jumping to top places).

Even though, I'd vote for the second approach as more "fair".

@ForNeVeR
Copy link
Member

I just haven't shown some keys from the dictionaries. I've updated my examples to show them.

Regarding the commit counting - I'd say we don't care at this moment. We can use only data provided by Github API and if it provides both kinds of dates - that's fine; if not - that's fine too.

@Minoru
Copy link
Member Author

Minoru commented Apr 18, 2015

I've replaced the format in the draft with the one you suggested. Thanks!

I also added a sentence clarifying how we count commits.

@Minoru
Copy link
Member Author

Minoru commented Apr 25, 2015

Closing the issue due to the stabilization of version 1 of the API.

@Minoru Minoru closed this as completed Apr 25, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants