Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
zamalek
· 4y ago · 0 comments
It's possible by blocking the thread that's reading the XML, but now you're in thread-per-client territory, and that doesn't scale.
Comments
[–]
Flowdalic
4y ago
Smack uses an XML pull parser
and
non-blocking I/O. It does so by splitting the XMPP stream top-level elements first and only feeding complete elements to the pull parser.
[–]
forty
4y ago
https://github.com/igniterealtime/Smack/blob/master/smack-xm...
I don't see any opportunity not to block when calling "next"