hochschule-darmstadt-UAS / ddk-artbrowser

Exploring the world of arts using open data
http://openartbrowser.org/
MIT License
1 stars 1 forks source link

Iconclass rest call fails if URL is too long #102

Open DPhuongHda opened 3 years ago

DPhuongHda commented 3 years ago

Describe the bug To fetch the data of multipe iconographies from iconclass.org/ a single URL/string is created. This URL consists of all child iconographies which have to be fetched.

http://www.iconclass.org/json/?notation=11H(...)(%2B0)&notation=11H......

Some iconographies have a huge amout of child iconographies (e.g. 200). In this case a huge URL is created which the iconclass-api cannot handle since the URL is way too long (limit: 5209 characters). As a result the child iconography-hierachy is not displayed.

If you directly access the iconclass api with the huge URL you get the following error: Bad Request Request Line is too large (5209 > 4094)

To Reproduce Go to /iconography/11H%28...%29 The child iconography hierachy ist not displayed.

Expected behavior The child iconography hierachy ist not displayed.

Possible fix To bypass this problem you could make two REST calls to reduce the size of a request URL. To do this you might want to split the child-array of an iconography.