You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@olingo.apache.org by "Patel, Yesha" <ye...@sap.com> on 2021/10/15 18:52:55 UTC

Parsing error from Olingo 2.0 API

Hi,

When I do delete request, the content gets deleted on the service, however, when parsing the response body, Olingo 2.0 api fails with below exception. The response is from Northwind service and it is same as Postman.

Why does it expect a blank line here, this is delete operation so there won't be any content? Is this a bug?

Any help is appreciated?

Thanks,
Yesha

--batchresponse_9dc68be8-7586-4374-bbd3-1dd8ae549637
Content-Type: multipart/mixed; boundary=changesetresponse_05689a73-f221-4f85-bf14-4ead21626014

--changesetresponse_05689a73-f221-4f85-bf14-4ead21626014
Content-Type: application/http
Content-Transfer-Encoding: binary

HTTP/1.1 204 No Content
Cache-Control: no-cache
DataServiceVersion: 1.0;

--changesetresponse_05689a73-f221-4f85-bf14-4ead21626014--
--batchresponse_9dc68be8-7586-4374-bbd3-1dd8ae549637--

10/15/21 11:16:05 AM Thread[Thread-10,5,main]            IOException, Unable to parse Batch responseBody for $batch request:Expected empty line but was '[None]': line '11'  . org.apache.olingo.odata2.api.batch.BatchException: Expected empty line but was '[None]': line '11'  .
               at org.apache.olingo.odata2.core.batch.v2.BatchParserCommon.consumeBlankLine(BatchParserCommon.java:239)
               at org.apache.olingo.odata2.core.batch.v2.BatchQueryOperation.parse(BatchQueryOperation.java:42)
               at org.apache.olingo.odata2.core.batch.v2.BatchChangeSetPart.parse(BatchChangeSetPart.java:37)
               at org.apache.olingo.odata2.core.batch.v2.BatchBodyPart.consumeChangeSet(BatchBodyPart.java:89)
               at org.apache.olingo.odata2.core.batch.v2.BatchBodyPart.consumeRequest(BatchBodyPart.java:77)
               at org.apache.olingo.odata2.core.batch.v2.BatchBodyPart.parse(BatchBodyPart.java:49)
               at org.apache.olingo.odata2.core.batch.v2.BatchParser.parseBatch(BatchParser.java:84)
               at org.apache.olingo.odata2.core.batch.v2.BatchParser.parse(BatchParser.java:63)
               at org.apache.olingo.odata2.core.batch.v2.BatchParser.parseBatchResponse(BatchParser.java:52)
               at org.apache.olingo.odata2.core.ep.ProviderFacadeImpl.parseBatchResponse(ProviderFacadeImpl.java:264)
               at org.apache.olingo.odata2.api.ep.EntityProvider.parseBatchResponse(EntityProvider.java:957)