Example usage for org.springframework.remoting RemoteLookupFailureException getStackTrace

List of usage examples for org.springframework.remoting RemoteLookupFailureException getStackTrace

Introduction

In this page you can find the example usage for org.springframework.remoting RemoteLookupFailureException getStackTrace.

Prototype

public StackTraceElement[] getStackTrace() 

Source Link

Document

Provides programmatic access to the stack trace information printed by #printStackTrace() .

Usage

From source file:org.javassonne.networking.impl.ClientResolver.java

public static RemoteClient attemptToResolveClient(String clientURI) {
    RemoteClient rc = null;/* w ww .  j a v a  2 s.c o m*/
    try {
        rc = (RemoteClient) RemotingUtils.lookupRMIService(clientURI, RemoteClient.class);
    } catch (RemoteLookupFailureException e) {

        LogSender.sendInfo("ClientResolver could not resolve client at uri: " + clientURI);
        return null;

    } catch (RuntimeException e) {
        String err = "LocalHostImpl - A RuntimeException occurred while adding " + "a client at URI: "
                + clientURI;
        err += "\n" + e.getMessage();
        err += "\nStack Trace: \n";
        for (int i = 0; i < e.getStackTrace().length; i++)
            err += e.getStackTrace()[i] + "\n";

        LogSender.sendErr(err);

        return null;
    }
    return rc;
}