[MGNLRESTCL-8] Provide app for testing of services Created: 02/Feb/15  Updated: 13/Apr/15  Resolved: 27/Mar/15

Status: Closed
Project: REST Client
Component/s: None
Affects Version/s: None
Fix Version/s: 1.0.3

Type: New Feature Priority: Neutral
Reporter: Roman Kovařík Assignee: Roman Kovařík
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
duplicate
is duplicated by MGNLRESTCL-7 Provide app for testing of definitions Closed
Template:
Acceptance criteria:
Empty
Date of First Response:

 Description   

See
https://git.magnolia-cms.com/gitweb/?p=internal/sandbox/syseleven-supercache.git;a=tree;f=src/main/java/info/magnolia/supercache/app;h=91f89671f61c8a4e5bdd2ce2d106b7bdfd727352;hb=HEAD for inspiration.



 Comments   
Comment by Jaroslav Simak [ 09/Mar/15 ]

Imho you shouldn't do all the logic in the view impl, that should be part of the presenter, see this this link

RestClientAppModule

  • fix copyright year
  • can we come up with something better than preseededServiceClasses? wouldn't serviceClasses be enough?

RestClientAppViewImpl

  • there are hardcoded messages for final Button sendButton and final Button formatBodyButton
Comment by Milan Divilek [ 26/Mar/15 ]

Reopen:
1. Please fix path in i18n message for restclient.app.service.description. There should be /module/rest-client-app/config/serviceClasses instead of /module/rest-client/config/serviceClasses
2. Rest app client has no logo
3. When performing rest call fails on javax.ws.rs.ClientErrorException then app tries read error message from response

String errorMessage = e.getResponse().readEntity(ObjectNode.class).findValue("errorMessage").asText();

but this fails when response has no entity or when entity is for example ArrayNode. App should check if response has entity and instead of ObjectNode it should try to get JsonNode.class (which is parent of all node classes).
Also it should not look only for "errorMessage" entity which is specific for WCS. For example Eloqua Rest API doesn't contain this entity. You should print whole JsonNode.

Generated at Mon Feb 12 10:42:17 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.