Package org.springframework.core

Examples of org.springframework.core.NestedCheckedException


      throw new SockJsTransportFailureException("Failed to write " + frame, this.getId(), ex);
    }
  }

  private void logWriteFrameFailure(Throwable failure) {
    @SuppressWarnings("serial")
    NestedCheckedException nestedException = new NestedCheckedException("", failure) {};

    if ("Broken pipe".equalsIgnoreCase(nestedException.getMostSpecificCause().getMessage()) ||
        disconnectedClientExceptions.contains(failure.getClass().getSimpleName())) {

      if (disconnectedClientLogger.isTraceEnabled()) {
        disconnectedClientLogger.trace("Looks like the client has gone away", failure);
      }
      else if (disconnectedClientLogger.isDebugEnabled()) {
        disconnectedClientLogger.debug("Looks like the client has gone away: " +
            nestedException.getMessage() + " (For full stack trace, set the '" +
            DISCONNECTED_CLIENT_LOG_CATEGORY + "' log category to TRACE level)");
      }
    }
    else {
      logger.debug("Terminating connection after failure to send message to client.", failure);
View Full Code Here


    assertTrue("Wrong output: " + output, output.contains("name=Sony Playstation"));
  }

  private boolean serverNotRunning(IllegalStateException ex) {

    @SuppressWarnings("serial")
    NestedCheckedException nested = new NestedCheckedException("failed", ex) {
    };
    Throwable root = nested.getRootCause();
    if (root.getMessage().contains("Connection refused")) {
      return true;
    }
    return false;
  }
View Full Code Here

    assertTrue("Wrong output: " + output,
        output.contains("firstName='Alice', lastName='Smith'"));
  }

  private boolean serverNotRunning(IllegalStateException ex) {
    @SuppressWarnings("serial")
    NestedCheckedException nested = new NestedCheckedException("failed", ex) {
    };
    Throwable root = nested.getRootCause();
    if (root instanceof MongoServerSelectionException
        || root instanceof MongoTimeoutException) {
      if (root.getMessage().contains("Unable to connect to any server")) {
        return true;
      }
View Full Code Here

    assertTrue("Wrong output: " + output,
        output.contains("firstName='Alice', lastName='Smith'"));
  }

  private boolean serverNotRunning(IllegalStateException ex) {
    @SuppressWarnings("serial")
    NestedCheckedException nested = new NestedCheckedException("failed", ex) {
    };
    if (nested.contains(ConnectException.class)) {
      Throwable root = nested.getRootCause();
      if (root.getMessage().contains("Connection refused")) {
        return true;
      }
    }
    return false;
View Full Code Here

                + "marceloverdijk ran successfully")
            && output.contains("Successfully released change log lock"));
  }

  private boolean serverNotRunning(IllegalStateException ex) {
    @SuppressWarnings("serial")
    NestedCheckedException nested = new NestedCheckedException("failed", ex) {
    };
    if (nested.contains(ConnectException.class)) {
      Throwable root = nested.getRootCause();
      if (root.getMessage().contains("Connection refused")) {
        return true;
      }
    }
    return false;
View Full Code Here

TOP

Related Classes of org.springframework.core.NestedCheckedException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.