[ 
https://issues.apache.org/jira/browse/OLINGO-1574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17585465#comment-17585465
 ] 

mibo commented on OLINGO-1574:
------------------------------

Hi [~varun_ramesh], 
had a look and as only the raw response which is already send by the server is 
added to the exception there is no improper error handling (as all what is 
added is anyways send by the server).
Only thing I have changed is a NPE and instead of replacing the existing 
constructors I have added new ones (because it is in the API package/module and 
the API must be backward compatible).

You can have a look here: https://github.com/apache/olingo-odata4/pull/81

If all is fine for you please let me know and I will merge the changes 🙂

Kind Regards, Michael 

> ODataClientErrorException & ODataServerErrorException doesn't have the 
> response body
> ------------------------------------------------------------------------------------
>
>                 Key: OLINGO-1574
>                 URL: https://issues.apache.org/jira/browse/OLINGO-1574
>             Project: Olingo
>          Issue Type: Improvement
>          Components: odata4-client
>    Affects Versions: (Java) V4 4.9.0
>            Reporter: varun_ramesh
>            Assignee: mibo
>            Priority: Major
>         Attachments: 
> 0001-OLINGO-1574-enhancement-for-getting-response-in-case.patch
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> When a OData backend service throws >= 400 error code
> ODataClientErrorException is constructed or if the service throws >= 500 HTTP 
> status code Olingo constructs an ODataServerErrorException.
> This exception class doesn't hold the actual response returned by the backend 
> system. There are cases where the response from the backend system will be 
> useful to determine the actual problem which caused failure HTTP status code. 
>  
> Hence enhancements should be made to the exception class in a way to retrieve 
> the actual response of the backend service. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to