Closes #754 Fix REST API response of methods with String return type
Using the REST API from the GUI used to return `"error": "no response from server"` and return code 0 for methods that return String. The problem was that the received response was not in json format, while the expected response content type is `application/json`. Project: http://git-wip-us.apache.org/repos/asf/brooklyn-server/repo Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-server/commit/9caf201d Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-server/tree/9caf201d Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-server/diff/9caf201d Branch: refs/heads/master Commit: 9caf201d195b2992e39087e980e0934c300fcb7f Parents: 463910f 829e495 Author: Geoff Macartney <[email protected]> Authored: Mon Jul 10 14:11:36 2017 +0100 Committer: Geoff Macartney <[email protected]> Committed: Mon Jul 10 14:11:36 2017 +0100 ---------------------------------------------------------------------- .../src/main/java/org/apache/brooklyn/rest/api/ActivityApi.java | 1 + .../apache/brooklyn/rest/resources/PolicyConfigResource.java | 4 ++-- .../java/org/apache/brooklyn/rest/resources/ServerResource.java | 4 ++-- .../org/apache/brooklyn/rest/resources/PolicyResourceTest.java | 5 +++-- .../org/apache/brooklyn/rest/resources/ServerResourceTest.java | 2 +- 5 files changed, 9 insertions(+), 7 deletions(-) ----------------------------------------------------------------------
