apache httpcomponents - Neo4j server seems to drop connection when processing for 200 seconds -


i've been writing neo4j server extension (as described here, i.e. managed server extension: http://docs.neo4j.org/chunked/stable/server-plugins.html). should string via post (which in productivity hold information extension should process, of no further concern here). tried extension neo4j 1.8.2 , 1.9.rc2, outcome same.

now problem extension quite lot of work can take couple of minutes. however, after 200 seconds, connection gets lost. i'm not absolutely sure happening, seems server dropping connection.

to verify behavior, wrote new, empty server extension nothing else wait 5 minutes (via thread.sleep()). test-client-class, post dummy data. tested jersey, apache httpcomponents , plain java url connections. jersey , plain java retry after 200 seconds, httpcomponents throw " org.apache.http.nohttpresponseexception: target server failed respond".

i think it's server issue, first because exception seems stand in context (there's comment saying in httpcomponent's code) , second because when set connection timeout and/or socket timeout lower values 200 seconds, normal timeout exceptions.

now there's 1 thing on top of that: said post data. seemingly whole behavior depends on amount of data sent. pinned down far can say, when sending string of length ca. 4500 characters, described behavior not happen, alright , http 204 "no content" response correct. send ca. 6000 characters or more, mentioned connection drop occurs. string i'm sending here dummy data. sent string sequence of 'a', i.e. "aaaaaaaa..." created loop 4500 or 6000 iterations, respectively.

in productive code wait until server operation has finished, don't how prevent connection drop.

is there option on neo4j server configure (i looked didn't find anything) or isn't server's fault , clients wrong? bug somewhere?

thanks reading , or hints!

just wrap up: found out there exists default timeout constant in jetty (version 6.x used neo4j then, think) set 200 seconds. changed using jetty api neo4j server did not appear offer possibility configure this. changing neo4j 2.x solved issue (why unknown). newer version of neo4j issue did not come anymore.


Comments

Popular posts from this blog

c# - Operator '==' incompatible with operand types 'Guid' and 'Guid' using DynamicExpression.ParseLambda<T, bool> -