[MGNLRESTCL-123] Support API's without Content-type Created: 23/Dec/19 Updated: 03/Jun/20 Resolved: 22/Apr/20 |
|
| Status: | Closed |
| Project: | REST Client |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 2.0.1 |
| Type: | Improvement | Priority: | Neutral |
| Reporter: | Jorge Franco | Assignee: | Quach Hao Thien |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | 0.25d | ||
| Time Spent: | 1d 3h | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Template: |
|
||||||||
| Acceptance criteria: |
Empty
|
||||||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
||||||||
| Release notes required: |
Yes
|
||||||||
| Documentation update required: |
Yes
|
||||||||
| Date of First Response: | |||||||||
| Epic Link: | Declarative REST clients | ||||||||
| Sprint: | 6.2.1 Ramp-up 22 | ||||||||
| Story Points: | 1 | ||||||||
| Description |
|
Re-evaluation; timeboxed to 1 SP. Some api's not return content-type in the response, and actually response is empty. To support that we will do the following:
|
| Comments |
| Comment by Christopher Zimmermann [ 07/Jan/20 ] |
|
What are some examples - or one example of an API like this? |
| Comment by Jorge Franco [ 07/Jan/20 ] |
|
Yeah, it happens for example with this API - http://openlibrary.org/search.json?title=paranoiax czimmermann |
| Comment by Chris Jennings [ 20/Feb/20 ] |
|
Can either of you please elaborate on adding a content-type header via a filter? Raw content from Github comes with a text/plain content-type header even when it is actually parse-able JSON. eg. https://raw.githubusercontent.com/oobrien/vis/master/tube/data/tfl_stations.json Calling this URL with a Mgnl REST client results in the error "RESTEASY003145: Unable to find a MessageBodyReader of content-type text/plain;charset=utf-8 and type class com.fasterxml.jackson.databind.JsonNode As a workaround, I can use various proxies [1] but this adds a dependency. A filter example would be very useful. |
| Comment by Quach Hao Thien [ 13/Apr/20 ] |
|
Hi jfranco and chris.jennings, I tried both examples above without any error, this problem has been fixed before release rest-client-2.0
|