Lock lock = container.getInvocationLock();
// We intentionally do not use tryLock() since it does not respect lock fairness
if (!lock.tryLock(0, TimeUnit.SECONDS))
{
throw new DispatcherConnectException("EJB container is not completely started, or is stopped.");
}
try
{
return invocation.invokeNext();