JBOSH does not detect compression header

jbosh/ApacheHTTPResponse.java at master · igniterealtime/jbosh · GitHub

Line number 135

it seems there is no use case to make this condition true,

I would recommend a code re-visit for reading the accepted zip format from server

may be we need to programmatically set it, while doing the parseFeatures in the XMPP life cycle inside smack-bosh

I’m sorry, I don’t understand. Could you elaborate a bit more? Why can the condition (which condition?) not be true? “core re-visit for reading the accepted zip format from server”?

line 135 jbosh/ApacheHTTPResponse.java at master · igniterealtime/jbosh · GitHub

if (cfg.isCompressionEnabled() && params != null) {https://github.com/igniterealtime/jbosh/blob/master/src/main/java/org/ignitereal time/jbosh/ApacheHTTPResponse.java

AttrAccept accept = params.getAccept();

if (accept != null) {////this condition

it seems the “accept != null” always null regardless of the compression enabled or disabled in openfire server

line 80 – “fromSessionInit” ----- is a function in jbosh/CMSessionParams.java at master · igniterealtime/jbosh · GitHub

which is responsible for collecting the session parameters which puts the value “accept” assuming server will respond with such stanza

CMSessionParams.java ---- I assume this code needs to be revisited or the session params should be updated somewhere else based on the XMPP SASL lifecycle