public boolean hasProcess(@Nonnull final DomainPair domainPair) {
        final PacketsProcessor processor = packetsProcessors.get(domainPair);
        return processor != null && !processor.isDone();
    }
Checks if an outgoing session is in process of being created, which includes both establishment of the (possibly
authenticated) connection as well as delivery of all queued stanzas.

@param domainPair The connection to check.
@return true if an outgoing session is currently being created, otherwise false.
xmppserver/src/main/java/org/jivesoftware/openfire/server/OutgoingSessionPromise.java