Smalyshev added a comment.

The ideal solution here would be for Kartotherian to call directly WDQS (via its discovery end point mentioned in the previous comments) and supply it the aforementioned header if the idea is to throttle requests on WDQS.

I am not sure whether we have direct endpoint for external cluster, but if we do, calling it with proper X-Client-IP would work too. That would lose the caching though so if somebody uses the same query twice within a short period - e.g. reloading a page with the same map, etc. - that might have performance impact. Not sure though what are cache hit/miss rates for Kartotherian there, I guess we could check it somewhere in the data?

In that case, perhaps it would worth investigating whether the set of queries could be restricted somehow?

If you have any ideas about that, you're welcome, but right now my task is lass ambitious - just make sure whole Karthoterian->WDQS service is not blocked due to one over-eager client.

It could also work if Karthoterian implemented its own resource management system - i.e. tracked how heavy queries are for each client and throttled/denied heavy ones - but since WDQS already has such system in place, we might as well use it.


TASK DETAIL
https://phabricator.wikimedia.org/T200594

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Smalyshev
Cc: mobrovac, MSantos, Gehel, Aklapper, MaxSem, Pnorman, Mholloway, Smalyshev, Amatissart, Lahi, Gq86, Looniverse, Lucas_Werkmeister_WMDE, GoranSMilovanovic, QZanden, EBjune, Orienteerix, merbst, LawExplorer, debt, JGirault, Jonas, phabyogi, Xmlizer, Susannaanas, lxbarth, Eevans, jkroll, Planemad, Hardikj, Wikidata-bugs, Jdouglas, aude, Tobias1984, Manybubbles, Yurik, Jdforrester-WMF, Mbch331, Jay8g
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to