synchronized (cont) { if (cont.isPending()) { cont.resume(); } }
cont.resume();
    public void process(MessageExchange exchange) throws Exception {        Continuation cont = (Continuation) locks.remove(exchange.getExchangeId());        if (cont != null) {            synchronized (cont) {                if (cont.isPending()) {                    cont.resume();                }            }        } else {            throw new IllegalStateException("Exchange not found");        }    }