# FailureReason: Unrecoverable/Unexpected BadResponse while attempting POST

**URL:** <https://discuss.elastic.co/t/failurereason-unrecoverable-unexpected-badresponse-while-attempting-post/218377>\
**Category:** Elasticsearch\
**Created:** [February 7, 2020, 3:55pm UTC](https://discuss.elastic.co/t/failurereason-unrecoverable-unexpected-badresponse-while-attempting-post/218377 "2020-02-07T15:55:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![amit\_kumar3](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/amit_kumar3/32/49351_2.png) [@amit\_kumar3](https://discuss.elastic.co/u/amit_kumar3)\
**Post date:** [February 7, 2020, 3:55pm UTC](https://discuss.elastic.co/t/failurereason-unrecoverable-unexpected-badresponse-while-attempting-post/218377/1 "2020-02-07T15:55:12Z")

</div>

System.IO.IOException: Received an unexpected EOF or 0 bytes from the transport stream.  
at System.Net.ConnectStream.Read(Byte buffer, Int32 offset, Int32 size)  
at System.IO.StreamReader.ReadBuffer(Char userBuffer, Int32 userOffset, Int32 desiredChars, Boolean& readToUserBuffer)  
at System.IO.StreamReader.Read(Char buffer, Int32 index, Int32 count)  
at Newtonsoft.Json.JsonTextReader.ReadData(Boolean append, Int32 charsRequired)  
at Newtonsoft.Json.JsonTextReader.ReadStringIntoBuffer(Char quote)  
at Newtonsoft.Json.JsonTextReader.ReadStringValue(ReadType readType)  
at Newtonsoft.Json.JsonTextReader.ReadAsString()  
at Nest.AggregateJsonConverter.GetDateHistogramBucket(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.ReadBucket(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.GetMultiBucketAggregate(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.ReadAggregate(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.GetSubAggregates(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.GetKeyedBucket(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.ReadBucket(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.GetMultiBucketAggregate(JsonReader reader, JsonSerializer serializer)  
at Nest.AggregateJsonConverter.ReadAggregate(JsonReader reader, JsonSerializer serializer)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.DeserializeConvertable(JsonConverter converter, JsonReader reader, Type objectType, Object existingValue)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.PopulateDictionary(IDictionary dictionary, JsonReader reader, JsonDictionaryContract contract, JsonProperty containerProperty, String id)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.SetPropertyValue(JsonProperty property, JsonConverter propertyConverter, JsonContainerContract containerContract, JsonProperty containerProperty, JsonReader reader, Object target)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.PopulateObject(Object newObject, JsonReader reader, JsonObjectContract contract, JsonProperty member, String id)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, Object existingValue)  
at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent)  
at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType)  
at Newtonsoft.Json.JsonSerializer.Deserialize[T](JsonReader reader)  
at Nest.JsonNetSerializer.Deserialize[T](Stream stream)  
at Nest.JsonNetSerializer.DeserializeAsync[T](Stream stream, CancellationToken cancellationToken)  
at Elasticsearch.Net.ResponseBuilder`1.<SetBodyAsync>d__31.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Elasticsearch.Net.ResponseBuilder`1.d\_\_28.MoveNext()  
--- End of stack trace from previous location where exception was thrown ---  
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()  
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)  
at Elasticsearch.Net.HttpWebRequestConnection.d\_\_5`1.MoveNext()  
--- End of stack trace from previous location where exception was thrown ---

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 6, 2020, 3:55pm UTC](https://discuss.elastic.co/t/failurereason-unrecoverable-unexpected-badresponse-while-attempting-post/218377/2 "2020-03-06T15:55:13Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
