bclzvs / serf

Automatically exported from code.google.com/p/serf
0 stars 0 forks source link

Subversion (serf) client enters infinite loop when server repeatedly crashes #94

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Top reproduce:

1. Create a repository with Subversion trunk built with -DSVN_DEBUG
2. touch $REPO/conf/debug-abort (this causes the server to crash during 
svn_repos_open)
3. Start httpd+mod_dav_svn (e.g., using davautockech.sh --no-tests)
4. svn ls http://...

The Subversion client enters an infinite loop, forever retrying the initial 
OPTIONS request. A more detailed analysis is available here:

http://subversion.tigris.org/issues/show_bug.cgi?id=4274

Serf should probably? detect that it received a hangup instead of a proper HTTP 
response, and report an error.

Verified with Serf versions 1.1.1 and 1.2.x, and the same code appears to be 
present on trunk as well.

Original issue reported on code.google.com by br...@xbc.nu on 11 Jan 2013 at 3:34

GoogleCodeExporter commented 9 years ago
Step 1 of the reproduction recipe has changed:
set CPPFLAGS=-DSVN_DEBUG_CRASH_AT_REPOS_OPEN not -DSVN_DEBUG.

Original comment by br...@xbc.nu on 11 Jan 2013 at 4:28

GoogleCodeExporter commented 9 years ago
This bug is considered a blocker for Subversion's 1.8.0 release.  (Whether it's 
considered good manners to drop cross-project dependencies into this tracker is 
debatable, but I'm just saying...)  ;-)

Original comment by cmpilato on 16 Jan 2013 at 1:09

GoogleCodeExporter commented 9 years ago
Fixed with new error code introduced in trunk r1717.  Backported to 1.2.x in 
r1718.  (Not sure if we'd need to bump to serf 1.3.x to get new error code - 
could also just reuse an error code for 1.2.x...)

Original comment by justin.e...@gmail.com on 20 Jan 2013 at 1:48

GoogleCodeExporter commented 9 years ago
r1717 on trunk and r1718 on 1.2.x branch have introduced 6 test failures. All 
tests pass before these revisions.

$ scons check
...
== Testing test/testcases/simple.response ==
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>scotch.ics.uci.edu</title>
<!--base href="http://scotch.ics.uci.edu/" /-->
<link href="default.css" rel="stylesheet" type="text/css" />
</head>

<body>

<p>More to come!</p>

<p><a href="manual/">Apache httpd 2.0 manual</a></p>

<p><a href="CA.cert.pem">Trust our CA!</a></p>

<p><img src="apache_pb.gif" alt="Powered by Apache!" /></p>

</body>

</html>
..FFFFFF.................

There were 6 failures:
1) test_serf_closed_connection: test/test_context.c:435: expected <0> but was 
<120108>
2) test_serf_setup_proxy: test/test_context.c:505: expected <0> but was <98>
3) test_keepalive_limit_one_by_one: test/test_context.c:656: expected <0> but 
was <98>
4) test_keepalive_limit_one_by_one_and_burst: test/test_context.c:810: expected 
<0> but was <98>
5) test_serf_progress_callback: test/test_context.c:932: expected <0> but was 
<98>
6) test_serf_request_timeout: test/test_context.c:1162: expected <0> but was 
<98>

!!!FAILURES!!!
Runs: 25 Passes: 19 Fails: 6

ERROR: some test(s) failed in test_all
scons: *** [check] Error 1
scons: building terminated because of errors.

Original comment by Arfrever...@gmail.com on 20 Jan 2013 at 2:50

GoogleCodeExporter commented 9 years ago
See r1721 (trunk) & r1722 (branches/1.2.x).  Passess 'make check' for me on 
both trees.  There are valid cases where reset_connection() can be called 
without an underlying socket error on the first response a connection sees.

Original comment by justin.e...@gmail.com on 20 Jan 2013 at 7:40