You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Michael Bolz (JIRA)" <ji...@apache.org> on 2015/06/19 08:23:00 UTC
[jira] [Closed] (OLINGO-705) EdmMetadataRequest ignores the Custom
Headers set
[ https://issues.apache.org/jira/browse/OLINGO-705?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael Bolz closed OLINGO-705.
-------------------------------
> EdmMetadataRequest ignores the Custom Headers set
> -------------------------------------------------
>
> Key: OLINGO-705
> URL: https://issues.apache.org/jira/browse/OLINGO-705
> Project: Olingo
> Issue Type: Bug
> Components: odata4-client
> Affects Versions: (Java) V4 4.0.0-beta-03
> Reporter: Ramesh Reddy
> Priority: Critical
>
> I am trying to add "Authorization" header for retrieving $metadata on the service that is secured though HTTPBasic. The following code fails with 401.
> {code}
> EdmMetadataRequest metadataRequest = client.getRetrieveRequestFactory().getMetadataRequest(serviceRoot);
> metadataRequest.addCustomHeader("Authorization", "Basic dXNlcjpyZWRoYXQxIQ==");
> ODataRetrieveResponse<Edm> metadataRespose = metadataRequest.execute();
> Edm edm = metadataRespose.getBody();
> {code}
> While debugging through the code, I found out that the header is never set on the request object. The same worked on the "ODataEntitySetIteratorRequest", but I suggest verify this on all the requests.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)