Page MenuHomePhabricator

Document max request size of wikibase.cloud instances
Open, Needs TriagePublicFeature

Description

Feature summary (what you would like to be able to do and where):
As a developer, I get an error when trying to create a large entity to Wikibase.cloud and I want to know the max size to be able to split up the request in multiple requests.
See https://github.com/LeMyst/WikibaseIntegrator/discussions/462 and https://github.com/internetarchive/wcdimportbot/issues/358

Use case(s) (list the steps that you performed to discover that problem, and describe the actual underlying problem which you want to solve. Do not describe only a solution):
As a developer I want to know the limitations of Wikibase.cloud instances beforehand, so I can build a robust and reliable ETL-framework.

Benefits (why should this be implemented?):
Because right now it is unclear what the max size is, and then Wikibase becomes a risk because we don't know the constraints and configuration limits.

Event Timeline

So9q updated the task description. (Show Details)
So9q updated the task description. (Show Details)

It would be great to find out if the max size is documented on Wikidata, and whether this problem is relevant to Wikidata users as well.
@Lydia_Pintscher

Cloud: In wmde/wbaas-deploy, I found no maxSerializedEntitySize or maxArticleSize setting. In wbstack/mediawiki, the platform’s LocalSettings.php doesn’t override maxSerializedEntitySize. The bundled Wikibase default sets it from $wgMaxArticleSize, as described in the docs. This implies that cloud uses the default wikibase setup currently

Wikidata: In wikimedia/mediawiki-config, WMF assigns maxSerializedEntitySize to both repo and client configuration in Wikibase.php. The Wikidata default value is 3000 KB currently

Suite: There is no maxSerializedEntitySize or maxArticleSize setting, so suite will also use the default setup currently

The default setup is that maxSerializedEntitySize comes from the default mediawiki maxArticleSize.
This also means the default can be retrieved by API if not specifically overriden.
See for example https://addshore-alpha.wikibase.cloud/w/api.php?action=query&meta=siteinfo&siprop=general&format=json maxarticlesize":2097152
However for a Wikibase install this is only true if maxSerializedEntitySize is then not explicitly set too.

Wikibase already adds at least "wikibase-propertytypes": { to the siteinfo response, along with some other things too.

"wikibase-conceptbaseuri": "https://addshore-alpha.wikibase.cloud/entity/",
"wikibase-geoshapestoragebaseurl": "https://commons.wikimedia.org/wiki/",
"wikibase-tabulardatastoragebaseurl": "https://commons.wikimedia.org/wiki/",

It would be easy enough to also add wikibase-maxSerializedEntitySize to this response.
And or add it to the WikibaseManifest responses (if that is starting to be more widely accepted and used)
perhaps both...