Details
-
Bug
-
Resolution: Fixed
-
Major
-
16.6.0, 16.4.3
-
Unknown
-
N/A
-
N/A
-
Description
Hi all,
Using the great xwiki platform to backing up the content of nudger.fr
I noticed a bug on some REST "rel" url formats when querying pages with multiple spaces.
- Given the page at the URL "https://WIKI_HOST/bin/view/verticals/tv/technologies-tv-2/"
- And the working corresponding REST URL at https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/spaces/tv/spaces/technologies-tv-2/pages/WebHome
If i go to the rest document, and look at the links section, i got :
- <link href="https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/spaces/tv/spaces/technologies-tv-2" rel="http://www.xwiki.org/rel/space"/>
- <link href="https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/tv/technologies-tv-2/pages/WebHome/history" rel="http://www.xwiki.org/rel/history"/>
- <link href="https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/tv/technologies-tv-2/pages/WebHome/attachments" rel="http://www.xwiki.org/rel/attachments"/>
- <link href="https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/tv/technologies-tv-2/pages/WebHome/objects" rel="http://www.xwiki.org/rel/objects"/>
- <link href="https://WIKI_HOST/rest/syntaxes" rel="http://www.xwiki.org/rel/syntaxes"/>
- <link href="https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/spaces/tv/spaces/technologies-tv-2/pages/WebHome" rel="self"/>
- <link href="https://WIKI_HOST/rest/wikis/xwiki/classes/verticals.tv.technologies-tv-2.WebHome" rel="http://www.xwiki.org/rel/class"/>
Looking deeper :
the history, attachments and objects url are wrong :
- history : https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/tv/technologies-tv-2/pages/WebHome/history SHOULD BE https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/spaces/tv/spaces/technologies-tv-2/pages/WebHome/history
- objects : https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/tv/technologies-tv-2/pages/WebHome/objects SHOULD BE https://WIKI_HOST/rest/wikis/xwiki/spaces/verticals/spaces/tv/spaces/technologies-tv-2/pages/WebHome/objects
- Idem for attachments
The "spaces" prefix seems to be missing for all second level and more spaces.
Best regards
Attachments
Issue Links
- is duplicated by
-
XWIKI-22618 The REST API query endpoint returns invalid page URLs for nested pages
- Closed