Where should I put the predicate? I could put it in `mod_bosh_socket` for now, and we could move it to a more general place in case it turns out to be useful somewhere else.