Package org.apache.cxf.message

Examples of org.apache.cxf.message.FaultMode


                                                 false)) {
            processFaultDetail(fault, msg);
            setStackTrace(fault, msg);
        }

        FaultMode faultMode = FaultMode.UNCHECKED_APPLICATION_FAULT;

        // Check if the raised exception is declared in the WSDL or by the JAX-RS resource
        Method m = msg.getExchange().get(Method.class);
        if (m != null) {
            Exception e = msg.getContent(Exception.class);
View Full Code Here


    }   
   
    @Override
    public void handleFault(Message message) {
        Exchange ex = message.getExchange();
        FaultMode mode = message.get(FaultMode.class);
        if (mode == null) {
            mode = FaultMode.RUNTIME_FAULT;
        }
        ex.put(FaultMode.class, mode);
        endHandlingMessage(ex);
View Full Code Here

            } catch (RuntimeException ex) {
                if (!faultOccurred) {
                    faultOccurred = true;
                   
                    FaultMode mode = message.get(FaultMode.class);
                    if (mode == FaultMode.CHECKED_APPLICATION_FAULT) {
                        if (LOG.isLoggable(Level.FINE)) {
                            LogUtils.log(LOG, Level.FINE,
                                         "Application has thrown exception, unwinding now", ex);
                        } else if (LOG.isLoggable(Level.INFO)) {
View Full Code Here

            if (isOutboundObserver()) {
                Exception ex = message.getContent(Exception.class);
                if (!(ex instanceof Fault)) {
                    ex = new Fault(ex);
                }
                FaultMode mode = (FaultMode)message.get(FaultMode.class);
               
                faultMessage = exchange.getOutMessage();
                if (null == faultMessage) {
                    faultMessage = exchange.get(Endpoint.class).getBinding().createMessage();
                }
View Full Code Here

            CURRENT_MESSAGE.set(oldMessage);
        }
    }

    private void doDefaultLogging(Message message, Exception ex, StringBuilder description) {
        FaultMode mode = message.get(FaultMode.class);
        if (mode == FaultMode.CHECKED_APPLICATION_FAULT) {
            if (isFineLogging) {
                LogUtils.log(LOG, Level.FINE,
                             "Application " + description
                             + "has thrown exception, unwinding now", ex);
View Full Code Here

            queue.start();
        }
    }
   
    boolean isRuntimeFault(Message message) {
        FaultMode mode = MessageUtils.getFaultMode(message);
        if (null == mode) {
            return false;
        }
        return FaultMode.CHECKED_APPLICATION_FAULT != mode;
    }
View Full Code Here

        }
        return wsaNamespace;
    }
   
    boolean isRuntimeFault(Message message) {
        FaultMode mode = MessageUtils.getFaultMode(message);
        if (null == mode) {
            return false;
        }
        return FaultMode.CHECKED_APPLICATION_FAULT != mode;
    }
View Full Code Here

            CURRENT_MESSAGE.set(oldMessage);
        }
    }

    private void doDefaultLogging(Message message, Exception ex, StringBuilder description) {
        FaultMode mode = message.get(FaultMode.class);
        if (mode == FaultMode.CHECKED_APPLICATION_FAULT) {
            if (isFineLogging) {
                LogUtils.log(LOG, Level.FINE,
                             "Application " + description
                             + "has thrown exception, unwinding now", ex);
View Full Code Here

            if (isOutboundObserver()) {
                Exception ex = message.getContent(Exception.class);
                if (!(ex instanceof Fault)) {
                    ex = new Fault(ex);
                }
                FaultMode mode = (FaultMode)message.get(FaultMode.class);
               
                faultMessage = exchange.getOutMessage();
                if (null == faultMessage) {
                    faultMessage = new MessageImpl();
                    faultMessage.setExchange(exchange);
View Full Code Here

            } catch (RuntimeException ex) {
                if (!faultOccurred) {
                    faultOccurred = true;
                                       
                    FaultMode mode = message.get(FaultMode.class);
                    if (mode == FaultMode.CHECKED_APPLICATION_FAULT) {
                        if (LOG.isLoggable(Level.FINE)) {
                            LogUtils.log(LOG, Level.FINE,
                                         "Application has thrown exception, unwinding now", ex);
                        } else if (LOG.isLoggable(Level.INFO)) {
View Full Code Here

TOP

Related Classes of org.apache.cxf.message.FaultMode

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.