The new bandwidth limiting code is nice, but it is not working very well. It seems to me that it chokes the bandwidth too violently, which causes the node to lock up completely (if you try to access the nodes http interfaces and the connection just sits there that is almost certainly the cause).
Also, looking it over, it looks like the ThrottledInputStream will block - which is a big problem because we rely on setSoTimeout() to be able to close Connections when they timeout or need to be displaced. If a locking ThrottledInputStream is implemented, it MUST have some way of obeying tcpConnection.setSoTimeout(). When bandwidth limiting kicked in on hawk, it managed to grow by 100 threads in 10 minutes because it kept accepting connections but was not able to destroy any (presumably because they were all locked waiting for bandwidth.) I think that a bandwidth limiter has to play nicely with a limit on the number of open connections somehow - we cannot just keep opening connections and spreading the water thinner and thinner. Also, why is ThrottledInputStream only wrapped around Input on incoming connections? -- Oskar Sandberg [EMAIL PROTECTED] _______________________________________________ devl mailing list [EMAIL PROTECTED] http://hawk.freenetproject.org/cgi-bin/mailman/listinfo/devl
