I am trying to connect to rest service via retrofit in android application. I am getting responses. But when there is some error response from the service, conversion exception
If the HTTP response indicates that an error occurred,
getInputStream() will throw an IOException. Use getErrorStream() to
read the error response. The headers can be read in the normal way
using getHeaderFields().