diff --git a/.gitignore b/.gitignore index b964f61..d675cd1 100644 --- a/.gitignore +++ b/.gitignore @@ -27,4 +27,8 @@ coveragereport/ stamp-h1 src/taskrambler /tests/*Test +/tests/*.log +/tests/*.trs gmon.out +test-driver + diff --git a/Makefile.am.coverage b/Makefile.am.coverage index c45711a..52643e5 100644 --- a/Makefile.am.coverage +++ b/Makefile.am.coverage @@ -21,7 +21,7 @@ generate-coverage-html: @echo Collecting coverage data - $(LCOV) -d $(top_builddir) -c -o coverage.run --gcov-tool /usr/x86_64-pc-linux-gnu/gcc-bin/4.5.3/gcov + $(LCOV) -d $(top_builddir) -c -o coverage.run --gcov-tool /usr/bin/gcov $(LCOV) -d $(top_builddir) -a ./coverage.base -a ./coverage.run -o coverage.info LANG=C $(GENHTML) --prefix $(top_builddir) --output-directory coveragereport --title "Code Coverage" --legend --branch-coverage --show-details coverage.run diff --git a/TODO b/TODO index 6bfe265..990bb26 100644 --- a/TODO +++ b/TODO @@ -6,3 +6,72 @@ VERY BIG TODO: - handle errors after all system call...especially open, close, etc. - IPV6 support + +- There seem to be a problem in the server under heavy load. Some tests with ab show that at some point it does not accept any more connections. Nor does it seem to answer request. I guess that it might be difficult to find this.... + => might be done... maybe not completely, I still loose connections under very high load. + +- using tsearch for my memory management was kind of a bad idea. tsearch uses malloc and free upon addition and remove of elements. Resulting again in uncontroolled heap usage. I guess I have to implement my own tree mechanism here, which does not involve further allocation. + +- another bug: if there is trailing garbage on the header line + we got a segfault... + + GET /images/waldschrat.jpg HTTP/1.1^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D^[[D + ^[[D = backspace... + +- the unexpected connection close seems to occur just on concurrency over + 1000 paralell connections...maybe this gives a hint. + +- after changing to non blocking sockets the server hangs after some requests. + have to check when this happens.... + * it seems that it does not occur without keep-alive and concurrency + * also concurrent connection don't seem to make a problem. + * keep-alive alone again don't seem to be a problem... + !!!! if both are active something is screwed up.... !!!! + +- at least some of the problems result in something that I think + is a bug in the glibc implementation of tdelete. + + Under some circumstances tdelete does not search the whole tree. + Here comes some debug output of the code... + + This shows a code fragment that tries to remove a no longer + needed asset from the asset_pool. + + DEBUG: pool release asset --./assets/image/waldschrat.jpg-- + + Twalk over all elements in the tree: + + DEBUG: ./assets/image/waldschrat.jpg(1910357807899405601) => 0xe378a8 + DEBUG: ./assets/js/jquery.js(10519512221325982142) => 0x10d3638 + + Output of each call to tDelete comparison function: + (Notice that the searched asset hash was in the previous Twalk. + + DEBUG: search asset hash: 1910357807899405601 + DEBUG: found: 10519512221325982142, key: ./assets/js/jquery.js + DEBUG: !!!!! NOT FOUND !!!!!!! + DEBUG: find results in (nil) + + Repeated 2 times if non was found... + + DEBUG: search asset hash: 1910357807899405601 + DEBUG: found: 10519512221325982142, key: ./assets/js/jquery.js + DEBUG: !!!!! NOT FOUND !!!!!!! + DEBUG: find results in (nil) + DEBUG: search asset hash: 1910357807899405601 + DEBUG: found: 10519512221325982142, key: ./assets/js/jquery.js + DEBUG: !!!!! NOT FOUND !!!!!!! + DEBUG: find results in (nil) + === + + Again a twalk over all elements... + + DEBUG: ./assets/image/waldschrat.jpg(1910357807899405601) => 0xe378a8 + DEBUG: ./assets/js/jquery.js(10519512221325982142) => 0x10d3638 + + Final statement... + + DEBUG delete 0xe378a8, parent was (nil) + + So, it looks like I should build my own tree implementation... + well in fact it seems that I have to! diff --git a/assets/html/foo.html b/assets/html/foo.html new file mode 100644 index 0000000..b48b623 --- /dev/null +++ b/assets/html/foo.html @@ -0,0 +1,13 @@ + + + + + This is just foo + + +

A BIG FAT FOO

+ + + + diff --git a/assets/html/main.html b/assets/html/main.html index a61e444..45241cc 100644 --- a/assets/html/main.html +++ b/assets/html/main.html @@ -4,11 +4,11 @@ My own little Web-App - - - - - + + + + +