atom feed2 messages in com.marklogic.developer.general[MarkLogic Dev General] Issue with XC...
FromSent OnAttachments
Yalaverthi, Sudheer (LNG-RDU)Jan 9, 2018 9:36 am 
Ron HitchensJan 9, 2018 10:21 am 
Subject:[MarkLogic Dev General] Issue with XCC - Error parsing HTTP headers: Premature EOF, partial header line read: ''
From:Yalaverthi, Sudheer (LNG-RDU) (sudh@lexisnexis.com)
Date:Jan 9, 2018 9:36:40 am
List:com.marklogic.developer.general

Hi,

I have a java program that makes MarkLogic calls using XCC api to fetch some
data. Calls to MarkLogic from the same client with same adhoc query and input
parameters runs successfully sometimes and fails sometimes. Our ML cluster is in AWS and the client program is running from one of our
on-prem unix boxes.

In a successful call, I see an entry like this in Elastic Load Balancer(ELB)
access logs

2018-01-09T17:04:12.029671Z ELB-STACKNAME-MASKED CLIENTIP-MASKED:44606
TARGETIP-MASKED:9000 0.000489 0.000008 0.000013 - - 1440 1452 "- - - " "-" - -

and I can see corresponding entries in ML Access logs for 9000 port.

For a failed call, I see an entry like this

2018-01-09T17:04:46.682065Z ELB-STACKNAME-MASKED CLIENTIP-MASKED:36752
TARGETIP-MASKED:9000 0.000651 0.000011 0.000015 - - 0 0 "- - - " "-" - -

and no corresponding logs in 9000 port ML access log file.

From the ELB logs, the only difference between the successful and failed calls
is the received_bytes and sent_bytes. For failed I see the bytes as 0 though I
am making the exact same call that had succeeded earlier.

For failure scenario, I see WARNINGs like below and finally an error

2018-01-09 10:33:02.220 WARNING [1] (AbstractRequestController.runRequest):
Error parsing HTTP headers: Premature EOF, partial header line read: '' 2018-01-09 10:35:23.257 WARNING [1] (AbstractRequestController.runRequest):
Error parsing HTTP headers: Premature EOF, partial header line read: '' 2018-01-09 10:37:42.264 WARNING [1] (AbstractRequestController.runRequest):
Error parsing HTTP headers: Premature EOF, partial header line read: '' 2018-01-09 10:40:01.272 WARNING [1] (AbstractRequestController.runRequest):
Error parsing HTTP headers: Premature EOF, partial header line read: '' 2018-01-09 10:42:22.328 WARNING [1] (AbstractRequestController.runRequest):
Error parsing HTTP headers: Premature EOF, partial header line read: '' 2018-01-09 10:42:22.328 INFO [1] (AbstractRequestController.runRequest):
automatic query retries (5) exhausted, throwing:
com.marklogic.xcc.exceptions.ServerConnectionException: Error parsing HTTP
headers: Premature EOF, partial header line read: ''

I am not quite sure what is causing this different behavior for the same
program. Any help is really appreciated.

Thanks, Sudheer