Comments (6)
Perhaps safeClose(Socket)
needs tweaking to cope with java.net.SocketException: Broken pipe
? Hmm, guess not as SocketException
is a subclass of IOException
.
There's a lot of this too:
java.net.SocketException: Socket closed
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:116)
at java.net.SocketOutputStream.write(SocketOutputStream.java:141)
at tinycdxserver.NanoHTTPD$Response.send(NanoHTTPD.java:535)
at tinycdxserver.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:840)
at tinycdxserver.NanoHTTPD$1$1.run(NanoHTTPD.java:205)
at java.lang.Thread.run(Thread.java:745)
from outbackcdx.
When it's looping is it repeating those same two exceptions over and over?
from outbackcdx.
I can reproduce the IllegalArgumentException like this against the latest version but it doesn't loop:
$ curl 'http://localhost:8080/myindex?q=%'
curl: (52) Empty reply from server
from outbackcdx.
It's hard to tell, and we've deleted the log file now, and it's not erroring at the moment. Here's the largest chunk of errors I could find in my console history:
java.lang.IllegalArgumentException: URLDecoder: Incomplete trailing escape (%) p attern
at java.net.URLDecoder.decode(URLDecoder.java:187)
at tinycdxserver.XmlQuery.decodeQueryString(XmlQuery.java:49)
at tinycdxserver.XmlQuery.<init>(XmlQuery.java:32)
at tinycdxserver.XmlQuery.query(XmlQuery.java:192)
at tinycdxserver.Server.query(Server.java:182)
at tinycdxserver.Server.serve(Server.java:126)
at tinycdxserver.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:831)
at tinycdxserver.NanoHTTPD$1$1.run(NanoHTTPD.java:205)
at java.lang.Thread.run(Thread.java:745)
java.net.SocketException: Broken pipe
at java.net.SocketOutputStream.socketWrite0(Native Method)
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:109)
at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
at tinycdxserver.NanoHTTPD$Response.sendAsFixedLength(NanoHTTPD.java:598 )
at tinycdxserver.NanoHTTPD$Response.send(NanoHTTPD.java:546)
at tinycdxserver.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:840)
at tinycdxserver.NanoHTTPD$1$1.run(NanoHTTPD.java:205)
at java.lang.Thread.run(Thread.java:745)
java.net.SocketException: Broken pipe
at java.net.SocketOutputStream.socketWrite0(Native Method)
at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:109)
at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
at tinycdxserver.NanoHTTPD$Response.sendAsFixedLength(NanoHTTPD.java:598 )
at tinycdxserver.NanoHTTPD$Response.send(NanoHTTPD.java:546)
at tinycdxserver.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:840)
at tinycdxserver.NanoHTTPD$1$1.run(NanoHTTPD.java:205)
at java.lang.Thread.run(Thread.java:745)
[snip]
(Edit by @ato: I moved the rest here for my issue reading sanity: https://gist.github.com/ato/d1b57f7401603fce736a153539770be1 )
(Edit by @anjackson: Ah good idea should have thought of that....)
from outbackcdx.
I think the looping is caused by a request larger than the httpd request buffer: NanoHttpd/nanohttpd#362
I've put in a workaround to reject too large requests. If you actually need to query for URLs large than 8000 characters we might need a different solution though.
from outbackcdx.
No, URLs over 8000 chars can be ignored. Maybe our systems are mis-handling some discovered data:
URIs.
from outbackcdx.
Related Issues (20)
- OWB compat: annotate 'closest' capture for BubbleCalendar
- Access rule editor: clearing 'accessed between' fields doesn't work
- CDXJ: Error: no such capture field: method HOT 7
- URL:s ending with an asterisk isn't found when searching for the same URL HOT 3
- Upgrade rocksdb
- Pasting a URL in the query field in the dashboard doesn't work
- Document index upgrades HOT 1
- ArrayIndexOutOfBoundsException, NumberFormatException when loading indexed ARC-files HOT 2
- Releases HOT 1
- API to scan all records HOT 3
- Handling of `+` characters in queries HOT 1
- CDX11+3 support HOT 2
- Replication secondary applies the last batch over and over HOT 3
- resolving a surt-timestamp collision should not replace a non-revisit record with a revisit record HOT 9
- Signed WARC URL generation
- Handle invalid dates HOT 4
- Report exception to client in WbCdxApi HOT 2
- Possible race condition under load HOT 8
- XML protocol: numreturned and numresults
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from outbackcdx.