Examples of FaultLocation


Examples of org.apache.cxf.greeter_control.types.FaultLocation

        setupGreeter("org/apache/cxf/systest/interceptor/no-addr.xml", false);

        control.setRobustInOnlyMode(true);

        // behaviour is identicial for all phases
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();
        location.setPhase("user-logical");
       
        control.setFaultLocation(location);

        try {
            // writer to grab the content of soap fault.
            // robust is not yet used at client's side, but I think it should
            StringWriter writer = new StringWriter();
            Client client = ClientProxy.getClient(greeter);
            client.getInInterceptors().add(new LoggingInInterceptor());
            ((LoggingInInterceptor)greeterBus.getInInterceptors().get(0)).setPrintWriter(new PrintWriter(writer));
            // it should tell CXF to convert one-way robust out faults into real SoapFaultException
            client.getEndpoint().put(Message.ROBUST_ONEWAY, true);
            greeter.greetMeOneWay("oneway");
            fail("Oneway operation unexpectedly succeded for phase " + location.getPhase());
        } catch (SOAPFaultException ex) {
            //expected
        }
    }
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

        // all interceptors pass
        testInterceptorsPass(robust);

        // behaviour is identicial for all phases
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();       
       
        // test failure occuring before and after logical addressing interceptor
        // won't get a fault in case of oneways non-robust for the latter (partial response already sent)
        testInterceptorFail(inPhases, location, robust);
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

       
        // all interceptors pass
        testInterceptorsPass(robust);
       
        // test failure in phases <= Phase.UNMARSHALL
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();
        location.setAfter(MAPAggregator.class.getName());
       
        // test failure occuring before and after logical addressing interceptor
        // won't get a fault in case of oneways non-robust for the latter (partial response already sent)
        testInterceptorFail(inPhases, location, robust);
    }
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

        // behaviour is identicial for all phases
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();       
       
        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.INVOKE.equals(p.getName())) {
                break;
            }            
            testFail(location);
        }
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

       
        // test failure in phases before Phase.PRE_LOGICAL
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();
        location.setAfter(MAPAggregator.class.getName());
       
        // test failure occuring before logical addressing interceptor

        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.PRE_LOGICAL.equals(p.getName())) {
                break;
            }  
            testFail(location, true);
        }
       
        // test failure occuring after logical addressing interceptor -
        // won't get a fault in case of oneways (partial response already sent)
       
        do
            location.setPhase(p.getName());
            if (Phase.INVOKE.equals(p.getName())) {
                break;
            }            
            testFail(location, true);
            p = it.hasNext() ? it.next() : null;
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

        // behaviour is identicial for all phases
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();       
       
        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.PRE_LOGICAL.equals(p.getName())) {
                break;
            }            
            testFail(location);
        }
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

       
        // test failure in phases before Phase.PRE_LOGICAL
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();
        location.setAfter(MAPAggregator.class.getName());
       
        // test failure occuring before logical addressing interceptor

        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.PRE_LOGICAL.equals(p.getName())) {
                break;
            }  
            testFail(location, true);
        }
       
        // test failure occuring after logical addressing interceptor -
        // won't get a fault in case of oneways (partial response already sent)
       
        do
            location.setPhase(p.getName());
            if (Phase.INVOKE.equals(p.getName())) {
                //faults from the PRE_LOGICAL and later phases won't make
                //it back to the client, the 200/202 response has already
                //been returned.  The server has accepted the message
                break;
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

        setupGreeter("org/apache/cxf/systest/interceptor/no-addr.xml", false);

        // behaviour is identicial for all phases
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();       
       
        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.PRE_LOGICAL.equals(p.getName())) {
                break;
            }            
            testFail(location);
        }
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

       
        // test failure in phases before Phase.PRE_LOGICAL
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();
        location.setAfter(MAPAggregator.class.getName());
       
        // test failure occuring before logical addressing interceptor

        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.PRE_LOGICAL.equals(p.getName())) {
                break;
            }  
            testFail(location, true);
        }
       
        // test failure occuring after logical addressing interceptor -
        // won't get a fault in case of oneways (partial response already sent)
       
        do
            location.setPhase(p.getName());
            if (Phase.INVOKE.equals(p.getName())) {
                //faults from the PRE_LOGICAL and later phases won't make
                //it back to the client, the 200/202 response has already
                //been returned.  The server has accepted the message
                break;
View Full Code Here

Examples of org.apache.cxf.greeter_control.types.FaultLocation

        // behaviour is identicial for all phases
       
        Iterator<Phase> it = inPhases.iterator();
        Phase p = null;
        FaultLocation location = new org.apache.cxf.greeter_control.types.ObjectFactory()
            .createFaultLocation();       
       
        while (it.hasNext()) {
            p = it.next();
            location.setPhase(p.getName());
            if (Phase.INVOKE.equals(p.getName())) {
                break;
            }            
            testFail(location);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.