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

Get all orgs/teams/permissions in a single GitHub API call #112

Merged
merged 1 commit into from
Aug 19, 2014

Conversation

lucamilanesio
Copy link
Contributor

Exposes a new API call at GitHub root level to build the complete
set of organisations and teams that current user belongs to.

This change allows to massively reduce the number of calls to GitHub
especially for people that belongs to multiple organisations with
lots of teams and members.

Signed-off-by: Luca Milanesio [email protected]

@buildhive
Copy link

Kohsuke Kawaguchi » github-api #208 SUCCESS
This pull request looks good
(what's this?)

@lucamilanesio
Copy link
Contributor Author

Unfortunately I cannot really assert anything sure as different users may have different organisations and teams. I will never be sure on who is running the tests and on which user.
Do you have any suggestion?

@suryagaddipati
Copy link
Collaborator

@lucamilanesio I guess maybe try getting that info via a different method and verify if its the same
https://github.com/kohsuke/github-api/blob/master/src/test/java/org/kohsuke/github/AppTest.java#L557

@lucamilanesio
Copy link
Contributor Author

Yes, I could ... but it is like measure a metre with the same metre 😃 But you're right: better than nothing 😸

Exposes a new API call at GitHub root level to build the complete
set of organisations and teams that current user belongs to.

This change allows to massively reduce the number of calls to GitHub 
especially for people that belongs to multiple organisations with 
lots of teams and members.

Signed-off-by: Luca Milanesio <[email protected]>
@buildhive
Copy link

Kohsuke Kawaguchi » github-api #209 SUCCESS
This pull request looks good
(what's this?)

@lucamilanesio
Copy link
Contributor Author

@suryagaddipati what do you think now? Split into two separate tests, one on the organizations and another on the teams (one test = one thing = one assertion).

@lucamilanesio
Copy link
Contributor Author

@kohsuke @suryagaddipati any extra feedback on this change? Are we good to go?

@lucamilanesio
Copy link
Contributor Author

@kohsuke @suryagaddipati ping ?

@suryagaddipati
Copy link
Collaborator

@lucamilanesio sorry. I will test this out this evening.

@lucamilanesio
Copy link
Contributor Author

@suryagaddipati thanks for that. Is the change OK now? Can we merge it?

suryagaddipati added a commit that referenced this pull request Aug 19, 2014
Get all orgs/teams/permissions in a single GitHub API call
@suryagaddipati suryagaddipati merged commit 1e81ab1 into hub4j:master Aug 19, 2014
@suryagaddipati
Copy link
Collaborator

@lucamilanesio merged it in and made a new release (1.57).

@lucamilanesio
Copy link
Contributor Author

@suryagaddipati fantastic, great news. Will refer to the new release in our GitHub plugin for Gerrit Code Review (https://gerrit-review.googlesource.com/#/admin/projects/plugins/github)

@lucamilanesio
Copy link
Contributor Author

@suryagaddipati I cannot find the github-api 1.57 in any public maven repo ... have you published it somewhere?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants