logoalt Hacker News

iamEAPyesterday at 5:32 PM7 repliesview on HN

I work closely with the team responsible for a large, self-hosted GitHub Enterprise instance. This is good advice for clients/consumers of GH data, but it can very easily lead to a lot of strain on the server-side. It’s not obvious what fields that you request are simple reads from tables or actually end up invoking git under the hood.

You could argue the rate limit guards should better reflect that, but that’s just not the reality of the system. Likely speaks to a lot of stability issues GitHub has been facing lately.


Replies

bob1029yesterday at 5:54 PM

All of the queries my agents use select fields like issue title, body, labels, createdAt, updatedAt, etc. That's about it. I would hope that stuff is cached and efficient to read. I do not think GraphQL is a good way to interact with git. Running git on the CLI is the best way to interact with git.

enormousnessyesterday at 5:39 PM

Isn't it kind of part and parcel of any GraphQL deployment to update it efficiently?

dieselgateyesterday at 5:54 PM

> It’s not obvious what fields that you request are simple reads from tables or actually end up invoking git under the hood.

I'm not familiar with graphql but what would make something "invoke git", is it a technical thing or hyperbole?

show 1 reply
RomanKornevyesterday at 9:48 PM

> lot of strain on the server-side

That's why GitHub assigns "points" to each requests and deducts based on the data shape you request. For simple requests it's 1-to-1, but can quickly balloon

kccqzyyesterday at 5:53 PM

That is true for almost any GraphQL backend not just GHE.

0xbadcafebeeyesterday at 7:51 PM

It's definitely one source of GitHub's issues. They never implemented limits properly and their codebase is likely decades of cruft and impossible to retrofit quickly (to say nothing of their horrific mysql clusters). If you want to scale and survive it, you have to build the thing right the first time.

show 1 reply
bboryesterday at 7:53 PM

Well 1. GitHub is the broken & bad one, and 2. isn't that kind of on them? If they're getting a ton of requests that read data awkwardly, the fix seems like the quintessential data engineering task.

show 1 reply