Repository navigation
JSPWIKI-1310 Add the difference between two versions of a page to the REST API - #654
Draft
arturobernalg wants to merge 31 commits into
Draft
arturobernalg wants to merge 31 commits into
arturobernalg wants to merge 31 commits into
Conversation
…n OpenAPI file that a test compares with the answers
… the REST API version 1
# Conflicts: # ChangeLog.md
…o feature/JSPWIKI-1310-plugins-suggestions # Conflicts: # ChangeLog.md
…310-plugins-suggestions
…310-search # Conflicts: # ChangeLog.md
…310-plugins-suggestions # Conflicts: # ChangeLog.md
…s to the REST API version 1
…310-search # Conflicts: # ChangeLog.md
…o feature/JSPWIKI-1310-plugins-suggestions # Conflicts: # ChangeLog.md # jspwiki-main/src/main/java/org/apache/wiki/search/DefaultSearchManager.java
…gestions' into feature/JSPWIKI-1310-pages-read
…HTML to the REST API version 1
…the pages in the REST API
… into feature/JSPWIKI-1310-pages-list # Conflicts: # jspwiki-main/src/test/java/org/apache/wiki/rest/ApiV1ServletTest.java
…t do not wait for it
…o feature/JSPWIKI-1310-plugins-suggestions
…gestions' into feature/JSPWIKI-1310-pages-read
… into feature/JSPWIKI-1310-pages-list
…o feature/JSPWIKI-1310-plugins-suggestions
…gestions' into feature/JSPWIKI-1310-pages-read # Conflicts: # ChangeLog.md
… into feature/JSPWIKI-1310-pages-list # Conflicts: # ChangeLog.md
…te its JSON with Jackson
…d a description that broke the JAX-RS generator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of JSPWIKI-1310. This pull request builds on #589, #590, #645, #646, #650 and #653, so it shows their commits until they are merged; the new commit is the last one.
It adds GET /api/v1/pages/{name}/diff, to read the difference between two versions of a page, as the wiki shows it. The parameter from is required, and to is the latest version when it is absent. The answer is JSON with the name, the two versions and the html of the difference, written by the difference provider of the wiki.
I also ran it on a Tomcat 10.1 with the war of this branch, with the versioning provider and a page with two versions: from 1 to 2 marks the added line as the wiki does, to defaults to the latest version, the reverse difference works, and version 9 is 404.
ChangeLog.md is updated.