JBossWS SVN: r12721 - in thirdparty/cxf/branches/cxf-2.2.6: rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: fnasser(a)redhat.com
Date: 2010-08-03 11:44:06 -0400 (Tue, 03 Aug 2010)
New Revision: 12721
Modified:
thirdparty/cxf/branches/cxf-2.2.6/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/XMLBeanStreamSerializer.java
Log:
CVE-2010-2076 Fix (Alesio Soldano)
Modified: thirdparty/cxf/branches/cxf-2.2.6/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java 2010-08-03 15:15:05 UTC (rev 12720)
+++ thirdparty/cxf/branches/cxf-2.2.6/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java 2010-08-03 15:44:06 UTC (rev 12721)
@@ -38,6 +38,7 @@
import javax.xml.stream.StreamFilter;
import javax.xml.stream.XMLInputFactory;
import javax.xml.stream.XMLOutputFactory;
+import javax.xml.stream.XMLResolver;
import javax.xml.stream.XMLStreamConstants;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
@@ -135,8 +136,7 @@
private static XMLInputFactory getXMLInputFactory() {
XMLInputFactory f = NS_AWARE_INPUT_FACTORY_POOL.poll();
if (f == null) {
- f = XMLInputFactory.newInstance();
- f.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE, true);
+ f = createXMLInputFactory(true);
}
return f;
}
@@ -165,6 +165,16 @@
public static XMLInputFactory createXMLInputFactory(boolean nsAware) {
XMLInputFactory factory = XMLInputFactory.newInstance();
factory.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE, nsAware);
+ factory.setProperty(XMLInputFactory.SUPPORT_DTD, Boolean.FALSE);
+ factory.setProperty(XMLInputFactory.IS_REPLACING_ENTITY_REFERENCES, Boolean.FALSE);
+ factory.setProperty(XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES, Boolean.FALSE);
+ factory.setXMLResolver(new XMLResolver() {
+ public Object resolveEntity(String publicID, String systemID,
+ String baseURI, String namespace)
+ throws XMLStreamException {
+ throw new XMLStreamException("Reading external entities is disabled");
+ }
+ });
return factory;
}
Modified: thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/XMLBeanStreamSerializer.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/XMLBeanStreamSerializer.java 2010-08-03 15:15:05 UTC (rev 12720)
+++ thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/provider/XMLBeanStreamSerializer.java 2010-08-03 15:44:06 UTC (rev 12721)
@@ -24,12 +24,12 @@
import java.io.IOException;
import java.io.InputStream;
-import javax.xml.stream.XMLInputFactory;
import javax.xml.stream.XMLStreamConstants;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;
import javax.xml.stream.XMLStreamWriter;
+import org.apache.cxf.staxutils.StaxUtils;
import org.apache.xmlbeans.XmlObject;
/**
@@ -61,7 +61,7 @@
xObj.save(tmpFile);
InputStream tmpIn = new FileInputStream(tmpFile);
- XMLStreamReader rdr = XMLInputFactory.newInstance().createXMLStreamReader(tmpIn);
+ XMLStreamReader rdr = StaxUtils.createXMLStreamReader(tmpIn);
while (rdr.hasNext()) {
15 years, 9 months
JBossWS SVN: r12720 - in thirdparty/cxf/branches/cxf-2.2.6/rt: frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: fnasser(a)redhat.com
Date: 2010-08-03 11:15:05 -0400 (Tue, 03 Aug 2010)
New Revision: 12720
Modified:
thirdparty/cxf/branches/cxf-2.2.6/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/CheckFaultInterceptor.java
thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerInterceptor.java
Log:
Fix problem that causes JTS tests to fail (Alessio Soldano)
Modified: thirdparty/cxf/branches/cxf-2.2.6/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/CheckFaultInterceptor.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/CheckFaultInterceptor.java 2010-08-03 15:13:26 UTC (rev 12719)
+++ thirdparty/cxf/branches/cxf-2.2.6/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/CheckFaultInterceptor.java 2010-08-03 15:15:05 UTC (rev 12720)
@@ -62,7 +62,7 @@
throw new SoapFault(new Message("XML_STREAM_EXC", LOG), e,
message.getVersion().getSender());
}
- if (message.getVersion().getFault().equals(xmlReader.getName())) {
+ if (message.getVersion().getFault().equals(xmlReader.getName()) && isRequestor(message)) {
Endpoint ep = message.getExchange().get(Endpoint.class);
message.getInterceptorChain().abort();
if (ep.getInFaultObserver() != null) {
Modified: thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerInterceptor.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerInterceptor.java 2010-08-03 15:13:26 UTC (rev 12719)
+++ thirdparty/cxf/branches/cxf-2.2.6/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/soap/SOAPHandlerInterceptor.java 2010-08-03 15:15:05 UTC (rev 12720)
@@ -254,7 +254,7 @@
}
}
}
- if (msg.getSOAPPart().getEnvelope().getBody() != null
+ if (isRequestor(message) && msg.getSOAPPart().getEnvelope().getBody() != null
&& msg.getSOAPPart().getEnvelope().getBody().hasFault()) {
return null;
}
15 years, 9 months
JBossWS SVN: r12719 - in thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws: src/main/java/org/apache/cxf/tools/java2js/processor and 3 other directories.
by jbossws-commits@lists.jboss.org
Author: fnasser(a)redhat.com
Date: 2010-08-03 11:13:26 -0400 (Tue, 03 Aug 2010)
New Revision: 12719
Modified:
thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/pom.xml
thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2js/processor/JavaToJSProcessor.java
thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/JavaToWSDLProcessor.java
thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactory.java
thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactoryTest.java
Log:
Make use of Spring optional in CXF's JAXWS tooling (Alessio Soldano)
Modified: thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/pom.xml
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
+++ thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/pom.xml 2010-08-03 15:13:26 UTC (rev 12719)
@@ -140,7 +140,6 @@
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-frontend-jaxws</artifactId>
<version>${project.version}</version>
- <scope>test</scope>
<exclusions>
<exclusion>
<groupId>org.apache.cxf</groupId>
Modified: thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2js/processor/JavaToJSProcessor.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2js/processor/JavaToJSProcessor.java 2010-08-03 07:58:43 UTC (rev 12718)
+++ thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2js/processor/JavaToJSProcessor.java 2010-08-03 15:13:26 UTC (rev 12719)
@@ -37,7 +37,6 @@
import org.apache.cxf.Bus;
import org.apache.cxf.BusFactory;
-import org.apache.cxf.bus.spring.BusApplicationContext;
import org.apache.cxf.common.WSDLConstants;
import org.apache.cxf.common.i18n.Message;
import org.apache.cxf.common.logging.LogUtils;
@@ -56,42 +55,13 @@
import org.apache.cxf.tools.common.ToolException;
import org.apache.cxf.tools.java2wsdl.processor.internal.ServiceBuilderFactory;
import org.apache.cxf.tools.util.AnnotationUtil;
-import org.springframework.beans.factory.BeanDefinitionStoreException;
-import org.springframework.beans.factory.xml.XmlBeanDefinitionReader;
-import org.springframework.context.ApplicationContext;
-import org.springframework.context.support.GenericApplicationContext;
-import org.springframework.core.io.ClassPathResource;
-import org.springframework.core.io.FileSystemResource;
public class JavaToJSProcessor implements Processor {
private static final Logger LOG = LogUtils.getL7dLogger(JavaToJSProcessor.class);
private static final String JAVA_CLASS_PATH = "java.class.path";
private static final Charset UTF8 = Charset.forName("utf-8");
private ToolContext context;
- private ApplicationContext applicationContext;
- /**
- * This is factored out to permit use in a unit test.
- *
- * @param bus
- * @return
- */
- public static ApplicationContext getApplicationContext(Bus bus, List<String> additionalFilePathnames) {
- BusApplicationContext busApplicationContext = bus.getExtension(BusApplicationContext.class);
- GenericApplicationContext appContext = new GenericApplicationContext(busApplicationContext);
- XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(appContext);
- reader.loadBeanDefinitions(new ClassPathResource("META-INF/cxf/java2wsbeans.xml"));
- for (String pathname : additionalFilePathnames) {
- try {
- reader.loadBeanDefinitions(new FileSystemResource(pathname));
- } catch (BeanDefinitionStoreException bdse) {
- throw new ToolException("Unable to open bean definition file " + pathname, bdse.getCause());
- }
- }
-
- return appContext;
- }
-
public void process() throws ToolException {
String oldClassPath = System.getProperty(JAVA_CLASS_PATH);
LOG.log(Level.INFO, "OLD_CP", oldClassPath);
@@ -117,10 +87,10 @@
if (null != context.get(ToolConstants.CFG_JAVASCRIPT_UTILS)) {
JavascriptQueryHandler.writeUtilsToResponseStream(JavaToJSProcessor.class, fileOutputStream);
}
-
+
OutputStreamWriter outputStreamWriter = new OutputStreamWriter(fileOutputStream, UTF8);
BufferedWriter writer = new BufferedWriter(outputStreamWriter);
-
+
for (SchemaInfo schema : schemata) {
SchemaJavascriptBuilder jsBuilder = new SchemaJavascriptBuilder(serviceInfo
.getXmlSchemaCollection(), prefixManager, nameManager);
@@ -128,10 +98,8 @@
writer.append(allThatJavascript);
}
- ServiceJavascriptBuilder serviceBuilder = new ServiceJavascriptBuilder(serviceInfo,
- null,
- prefixManager,
- nameManager);
+ ServiceJavascriptBuilder serviceBuilder = new ServiceJavascriptBuilder(serviceInfo, null,
+ prefixManager, nameManager);
serviceBuilder.walk();
String serviceJavascript = serviceBuilder.getCode();
writer.append(serviceJavascript);
@@ -157,14 +125,13 @@
// is there a better way to avoid the warning?
beanDefinitions.addAll((List<String>)beanFilesParameter);
} else {
- String list[] = (String[]) beanFilesParameter;
+ String list[] = (String[])beanFilesParameter;
for (String b : list) {
beanDefinitions.add(b);
}
}
}
- applicationContext = getApplicationContext(getBus(), beanDefinitions);
- ServiceBuilderFactory builderFactory = ServiceBuilderFactory.getInstance();
+ ServiceBuilderFactory builderFactory = ServiceBuilderFactory.getInstance(beanDefinitions);
Class<?> clz = getServiceClass();
context.put(Class.class, clz);
if (clz.isInterface()) {
@@ -183,7 +150,7 @@
builderFactory.setDatabindingName(getDataBindingName());
// The service class determines the frontend, so no need to pass it in
// twice.
- ServiceBuilder builder = builderFactory.newBuilder(applicationContext);
+ ServiceBuilder builder = builderFactory.newBuilder();
builder.validate();
@@ -223,13 +190,12 @@
protected File getOutputDir(File wsdlLocation) {
String dir = (String)context.get(ToolConstants.CFG_OUTPUTDIR);
if (dir == null) {
- if (wsdlLocation == null
- || wsdlLocation.getParentFile() == null
+ if (wsdlLocation == null || wsdlLocation.getParentFile() == null
|| !wsdlLocation.getParentFile().exists()) {
dir = "./";
} else {
dir = wsdlLocation.getParent();
- }
+ }
}
return new File(dir);
}
Modified: thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/JavaToWSDLProcessor.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/JavaToWSDLProcessor.java 2010-08-03 07:58:43 UTC (rev 12718)
+++ thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/JavaToWSDLProcessor.java 2010-08-03 15:13:26 UTC (rev 12719)
@@ -31,7 +31,6 @@
import org.apache.cxf.Bus;
import org.apache.cxf.BusFactory;
-import org.apache.cxf.bus.spring.BusApplicationContext;
import org.apache.cxf.common.WSDLConstants;
import org.apache.cxf.common.i18n.Message;
import org.apache.cxf.common.logging.LogUtils;
@@ -49,20 +48,14 @@
import org.apache.cxf.tools.java2wsdl.generator.wsdl11.WrapperBeanGenerator;
import org.apache.cxf.tools.java2wsdl.processor.internal.ServiceBuilderFactory;
import org.apache.cxf.tools.util.AnnotationUtil;
-import org.springframework.beans.factory.BeanDefinitionStoreException;
-import org.springframework.beans.factory.xml.XmlBeanDefinitionReader;
-import org.springframework.context.ApplicationContext;
-import org.springframework.context.support.GenericApplicationContext;
-import org.springframework.core.io.ClassPathResource;
-import org.springframework.core.io.FileSystemResource;
+
public class JavaToWSDLProcessor implements Processor {
private static final Logger LOG = LogUtils.getL7dLogger(JavaToWSDLProcessor.class);
private static final String DEFAULT_ADDRESS = "http://localhost:9090/hello";
private static final String JAVA_CLASS_PATH = "java.class.path";
private ToolContext context;
private final List<AbstractGenerator> generators = new ArrayList<AbstractGenerator>();
- private ApplicationContext applicationContext;
private void customize(ServiceInfo service) {
if (context.containsKey(ToolConstants.CFG_TNS)) {
@@ -91,26 +84,6 @@
}
- /**
- * This is factored out to permit use in a unit test.
- * @param bus
- * @return
- */
- public static ApplicationContext getApplicationContext(Bus bus, List<String> additionalFilePathnames) {
- BusApplicationContext busApplicationContext = bus.getExtension(BusApplicationContext.class);
- GenericApplicationContext appContext = new GenericApplicationContext(busApplicationContext);
- XmlBeanDefinitionReader reader = new XmlBeanDefinitionReader(appContext);
- reader.loadBeanDefinitions(new ClassPathResource("META-INF/cxf/java2wsbeans.xml"));
- for (String pathname : additionalFilePathnames) {
- try {
- reader.loadBeanDefinitions(new FileSystemResource(pathname));
- } catch (BeanDefinitionStoreException bdse) {
- throw new ToolException("Unable to open bean definition file " + pathname, bdse.getCause());
- }
- }
-
- return appContext;
- }
public void process() throws ToolException {
String oldClassPath = System.getProperty(JAVA_CLASS_PATH);
@@ -199,8 +172,8 @@
}
}
}
- applicationContext = getApplicationContext(getBus(), beanDefinitions);
- ServiceBuilderFactory builderFactory = ServiceBuilderFactory.getInstance();
+
+ ServiceBuilderFactory builderFactory = ServiceBuilderFactory.getInstance(beanDefinitions);
Class<?> clz = getServiceClass();
context.put(Class.class, clz);
if (clz.isInterface()) {
@@ -218,7 +191,7 @@
builderFactory.setServiceClass(clz);
builderFactory.setDatabindingName(getDataBindingName());
// The service class determines the frontend, so no need to pass it in twice.
- ServiceBuilder builder = builderFactory.newBuilder(applicationContext);
+ ServiceBuilder builder = builderFactory.newBuilder();
builder.validate();
Modified: thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactory.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactory.java 2010-08-03 07:58:43 UTC (rev 12718)
+++ thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/main/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactory.java 2010-08-03 15:13:26 UTC (rev 12719)
@@ -19,98 +19,54 @@
package org.apache.cxf.tools.java2wsdl.processor.internal;
-import org.apache.cxf.databinding.DataBinding;
-import org.apache.cxf.frontend.AbstractServiceFactory;
+import java.util.List;
+
import org.apache.cxf.service.ServiceBuilder;
import org.apache.cxf.tools.common.ToolConstants;
-import org.apache.cxf.tools.common.ToolException;
import org.apache.cxf.tools.java2wsdl.processor.FrontendFactory;
-import org.apache.cxf.tools.util.NameUtil;
-import org.springframework.context.ApplicationContext;
/**
- * This class constructs ServiceBuilder objects. These objects are used to access the services
- * and the data bindings to generate the wsdl.
+ * This class constructs ServiceBuilder objects. These objects are used to access the services and the data
+ * bindings to generate the wsdl.
*/
-public final class ServiceBuilderFactory {
- private static ServiceBuilderFactory instance;
- private static FrontendFactory frontend;
- private static String databindingName;
- private Class serviceClass;
-
- private ServiceBuilderFactory() {
+public abstract class ServiceBuilderFactory {
+ protected FrontendFactory frontend;
+ protected String databindingName;
+ protected Class<?> serviceClass;
+
+ protected ServiceBuilderFactory() {
frontend = FrontendFactory.getInstance();
databindingName = ToolConstants.DEFAULT_DATA_BINDING_NAME;
}
-
- public static ServiceBuilderFactory getInstance() {
- if (instance == null) {
- instance = new ServiceBuilderFactory();
- }
- return instance;
- }
- public ServiceBuilder newBuilder(ApplicationContext applicationContext) {
- return newBuilder(applicationContext, getStyle());
- }
-
- /**
- * Convert a parameter value to the name of a bean we'd use for a data binding.
- * @param databindingName
- * @return
- */
- public static String databindingNameToBeanName(String dbName) {
- return NameUtil.capitalize(dbName.toLowerCase()) + ToolConstants.DATABIND_BEAN_NAME_SUFFIX;
- }
-
- public ServiceBuilder newBuilder(ApplicationContext applicationContext, FrontendFactory.Style s) {
- DataBinding dataBinding;
- String databindingBeanName = databindingNameToBeanName(databindingName);
- try {
- dataBinding = (DataBinding)applicationContext.getBean(databindingBeanName);
- } catch (RuntimeException e) {
- throw new ToolException("Cannot get databinding bean " + databindingBeanName
- + " for databinding " + databindingName);
+ public static ServiceBuilderFactory getInstance(List<String> beanDefinitions) {
+ ServiceBuilderFactory factory;
+ if (beanDefinitions == null || beanDefinitions.isEmpty()) {
+ factory = new DefaultServiceBuilderFactory();
+ } else {
+ factory = new SpringServiceBuilderFactory(beanDefinitions);
}
-
- String beanName = getBuilderBeanName(s);
- ServiceBuilder builder = null;
-
- try {
- builder = (ServiceBuilder) applicationContext.getBean(beanName, ServiceBuilder.class);
- AbstractServiceFactory serviceFactory = (AbstractServiceFactory)builder;
- serviceFactory.setDataBinding(dataBinding);
- } catch (RuntimeException e) {
- throw new ToolException("Can not get ServiceBuilder bean " + beanName
- + "to initialize the ServiceBuilder for style: " + s
- + " Reason: \n" + e.getMessage(),
- e);
- }
- builder.setServiceClass(serviceClass);
- return builder;
+ return factory;
}
- /**
- * Return the name of a prototype bean from Spring that can provide the service. The use of a bean
- * allows for the possibility of an override.
- * @param s Style of service
- * @return name of bean.
- */
- protected String getBuilderBeanName(FrontendFactory.Style s) {
- return s + "ServiceBuilderBean";
+ public ServiceBuilder newBuilder() {
+ return newBuilder(getStyle());
}
+ public abstract ServiceBuilder newBuilder(FrontendFactory.Style s);
+
public FrontendFactory.Style getStyle() {
frontend.setServiceClass(this.serviceClass);
return frontend.discoverStyle();
}
- public void setServiceClass(Class c) {
+ public void setServiceClass(Class<?> c) {
this.serviceClass = c;
}
/**
* Return the databinding name.
+ *
* @return
*/
public String getDatabindingName() {
@@ -119,6 +75,7 @@
/**
* Set the databinding name
+ *
* @param databindingName
*/
public void setDatabindingName(String arg) {
Modified: thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactoryTest.java
===================================================================
--- thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactoryTest.java 2010-08-03 07:58:43 UTC (rev 12718)
+++ thirdparty/cxf/branches/cxf-2.2.6/tools/javato/ws/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/ServiceBuilderFactoryTest.java 2010-08-03 15:13:26 UTC (rev 12719)
@@ -21,43 +21,21 @@
import java.util.ArrayList;
-import org.apache.cxf.BusFactory;
import org.apache.cxf.jaxws.JaxwsServiceBuilder;
import org.apache.cxf.service.ServiceBuilder;
import org.apache.cxf.simple.SimpleServiceBuilder;
import org.apache.cxf.tools.fortest.classnoanno.docbare.Stock;
import org.apache.cxf.tools.fortest.simple.Hello;
-import org.apache.cxf.tools.java2wsdl.processor.FrontendFactory;
-import org.apache.cxf.tools.java2wsdl.processor.JavaToWSDLProcessor;
import org.junit.Assert;
-import org.junit.Before;
import org.junit.Test;
-import org.springframework.context.ApplicationContext;
public class ServiceBuilderFactoryTest extends Assert {
- ServiceBuilderFactory factory = ServiceBuilderFactory.getInstance();
- private ApplicationContext applicationContext;
-
- @Before
- public void setUp() {
- applicationContext = JavaToWSDLProcessor.getApplicationContext(BusFactory.getDefaultBus(),
- new ArrayList<String>());
- }
-
- @Test
- public void testGetBuilderBeanName() {
- assertNotNull(factory);
- assertEquals("JaxwsServiceBuilderBean",
- factory.getBuilderBeanName(FrontendFactory.Style.Jaxws));
+ ServiceBuilderFactory factory = ServiceBuilderFactory.getInstance(new ArrayList<String>());
- assertEquals("SimpleServiceBuilderBean",
- factory.getBuilderBeanName(FrontendFactory.Style.Simple));
- }
-
@Test
public void testGetJaxwsBuilder() {
factory.setServiceClass(Stock.class);
- ServiceBuilder builder = factory.newBuilder(applicationContext);
+ ServiceBuilder builder = factory.newBuilder();
assertNotNull(builder);
assertTrue(builder instanceof JaxwsServiceBuilder);
}
@@ -65,7 +43,7 @@
@Test
public void testGetSimpleBuilder() {
factory.setServiceClass(Hello.class);
- ServiceBuilder builder = factory.newBuilder(applicationContext);
+ ServiceBuilder builder = factory.newBuilder();
assertNotNull(builder);
assertTrue(builder instanceof SimpleServiceBuilder);
}
15 years, 9 months
JBossWS SVN: r12718 - in stack/cxf/branches/cxf-2.3/modules: server and 3 other directories.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2010-08-03 03:58:43 -0400 (Tue, 03 Aug 2010)
New Revision: 12718
Modified:
stack/cxf/branches/cxf-2.3/modules/client/pom.xml
stack/cxf/branches/cxf-2.3/modules/server/pom.xml
stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-spring-tests/pom.xml
stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-tests/pom.xml
stack/cxf/branches/cxf-2.3/modules/testsuite/pom.xml
Log:
[JBWS-3080] partial fix of some of Maven 3 issues
Modified: stack/cxf/branches/cxf-2.3/modules/client/pom.xml
===================================================================
--- stack/cxf/branches/cxf-2.3/modules/client/pom.xml 2010-08-02 16:23:57 UTC (rev 12717)
+++ stack/cxf/branches/cxf-2.3/modules/client/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
@@ -27,7 +27,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-factories</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<!-- CXF dependencies -->
Modified: stack/cxf/branches/cxf-2.3/modules/server/pom.xml
===================================================================
--- stack/cxf/branches/cxf-2.3/modules/server/pom.xml 2010-08-02 16:23:57 UTC (rev 12717)
+++ stack/cxf/branches/cxf-2.3/modules/server/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
@@ -19,7 +19,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-client</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<dependency>
@@ -42,7 +42,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-factories</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<!-- CXF dependencies -->
<dependency>
Modified: stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-spring-tests/pom.xml
===================================================================
--- stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-spring-tests/pom.xml 2010-08-02 16:23:57 UTC (rev 12717)
+++ stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-spring-tests/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
@@ -18,7 +18,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-server</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.picketbox</groupId>
Modified: stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-tests/pom.xml
===================================================================
--- stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-tests/pom.xml 2010-08-02 16:23:57 UTC (rev 12717)
+++ stack/cxf/branches/cxf-2.3/modules/testsuite/cxf-tests/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
@@ -18,7 +18,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-server</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.picketbox</groupId>
Modified: stack/cxf/branches/cxf-2.3/modules/testsuite/pom.xml
===================================================================
--- stack/cxf/branches/cxf-2.3/modules/testsuite/pom.xml 2010-08-02 16:23:57 UTC (rev 12717)
+++ stack/cxf/branches/cxf-2.3/modules/testsuite/pom.xml 2010-08-03 07:58:43 UTC (rev 12718)
@@ -56,7 +56,7 @@
<dependency>
<groupId>org.jboss.ws.cxf</groupId>
<artifactId>jbossws-cxf-client</artifactId>
- <version>${version}</version>
+ <version>${project.version}</version>
</dependency>
<dependency>
<groupId>junit</groupId>
15 years, 9 months
JBossWS SVN: r12717 - stack/cxf/trunk/modules/testsuite/cxf-tests/scripts.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-08-02 12:23:57 -0400 (Mon, 02 Aug 2010)
New Revision: 12717
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
Log:
[JBWS-3085] removing useless lines from build
Modified: stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2010-08-02 16:14:11 UTC (rev 12716)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2010-08-02 16:23:57 UTC (rev 12717)
@@ -90,9 +90,6 @@
<classes dir="${tests.output.dir}/test-classes">
<include name="org/jboss/test/ws/jaxws/samples/wsrm/service/**"/>
</classes>
- <webinf dir="${tests.output.dir}/test-resources/jaxws/samples/wsrm/WEB-INF">
- <include name="jbossws-cxf.xml"/>
- </webinf>
<zipfileset
dir="${tests.output.dir}/test-resources/jaxws/samples/wsrm/WEB-INF/wsdl"
prefix="WEB-INF/wsdl"/>
15 years, 9 months
JBossWS SVN: r12716 - stack/cxf/trunk/modules/testsuite.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-08-02 12:14:11 -0400 (Mon, 02 Aug 2010)
New Revision: 12716
Modified:
stack/cxf/trunk/modules/testsuite/test-excludes-jboss501.txt
stack/cxf/trunk/modules/testsuite/test-excludes-jboss510.txt
stack/cxf/trunk/modules/testsuite/test-excludes-jboss600.txt
stack/cxf/trunk/modules/testsuite/test-excludes-jboss601.txt
Log:
[JBWS-3085][JBWS-3075] Excluding tests
Modified: stack/cxf/trunk/modules/testsuite/test-excludes-jboss501.txt
===================================================================
--- stack/cxf/trunk/modules/testsuite/test-excludes-jboss501.txt 2010-08-02 16:10:30 UTC (rev 12715)
+++ stack/cxf/trunk/modules/testsuite/test-excludes-jboss501.txt 2010-08-02 16:14:11 UTC (rev 12716)
@@ -55,6 +55,9 @@
# [JBWS-3028] Complete UsernameToken JAAS integration: PicketBox not available on AS 5.x
org/jboss/test/ws/jaxws/samples/wsse/UsernameAuthorizationCustomFileTestCase.*
+# [JBWS-3075][CXF-2912] EndpointPolicy is not ignoring empty Policies in its updatePolicy() method
+org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.*
+
# [JBWS-3086] This have been merged to AS 600M3 and upstream only
org/jboss/test/ws/jaxws/samples/jmsendpoints/**
Modified: stack/cxf/trunk/modules/testsuite/test-excludes-jboss510.txt
===================================================================
--- stack/cxf/trunk/modules/testsuite/test-excludes-jboss510.txt 2010-08-02 16:10:30 UTC (rev 12715)
+++ stack/cxf/trunk/modules/testsuite/test-excludes-jboss510.txt 2010-08-02 16:14:11 UTC (rev 12716)
@@ -55,6 +55,9 @@
# [JBWS-3028] Complete UsernameToken JAAS integration: PicketBox not available on AS 5.x
org/jboss/test/ws/jaxws/samples/wsse/UsernameAuthorizationCustomFileTestCase.*
+# [JBWS-3075][CXF-2912] EndpointPolicy is not ignoring empty Policies in its updatePolicy() method
+org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.*
+
# [JBWS-3086] This have been merged to AS 600M3 and upstream only
org/jboss/test/ws/jaxws/samples/jmsendpoints/**
Modified: stack/cxf/trunk/modules/testsuite/test-excludes-jboss600.txt
===================================================================
--- stack/cxf/trunk/modules/testsuite/test-excludes-jboss600.txt 2010-08-02 16:10:30 UTC (rev 12715)
+++ stack/cxf/trunk/modules/testsuite/test-excludes-jboss600.txt 2010-08-02 16:14:11 UTC (rev 12716)
@@ -46,3 +46,5 @@
# [JBWS-3001] Verify @PostConstruct and @PreDestroy annotations support for POJO based endpoints
org/jboss/test/ws/jaxws/jbws2268/**
+# [JBWS-3075][CXF-2912] EndpointPolicy is not ignoring empty Policies in its updatePolicy() method
+org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.*
Modified: stack/cxf/trunk/modules/testsuite/test-excludes-jboss601.txt
===================================================================
--- stack/cxf/trunk/modules/testsuite/test-excludes-jboss601.txt 2010-08-02 16:10:30 UTC (rev 12715)
+++ stack/cxf/trunk/modules/testsuite/test-excludes-jboss601.txt 2010-08-02 16:14:11 UTC (rev 12716)
@@ -46,6 +46,9 @@
# [JBWS-3001] Verify @PostConstruct and @PreDestroy annotations support for POJO based endpoints
org/jboss/test/ws/jaxws/jbws2268/**
+# [JBWS-3075][CXF-2912] EndpointPolicy is not ignoring empty Policies in its updatePolicy() method
+org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.*
+
# [JBWS-3086] TODO: merge to AS IL trunk once SPI, COMMON and FRAMEWORK are updated there
org/jboss/test/ws/jaxws/samples/jmsendpoints/**
15 years, 9 months
JBossWS SVN: r12715 - in stack/cxf/trunk/modules/testsuite/cxf-tests: src/test/java/org/jboss/test/ws/jaxws/samples and 9 other directories.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-08-02 12:10:30 -0400 (Mon, 02 Aug 2010)
New Revision: 12715
Added:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/client/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Echo.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/EchoResponse.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/ObjectFactory.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Ping.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService_Service.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/package-info.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/RMCheckInterceptor.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/SimpleServiceImpl.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Echo.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/EchoResponse.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Ping.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/web.xml
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/wsdl/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/wsdl/SimpleService.wsdl
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
Log:
[JBWS-3085] Adding testcase for WS-RM usage through policy / api only
Modified: stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2010-08-02 08:00:55 UTC (rev 12714)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/scripts/cxf-jars-jaxws.xml 2010-08-02 16:10:30 UTC (rev 12715)
@@ -83,6 +83,21 @@
prefix="WEB-INF/wsdl"/>
</war>
+ <!-- jaxws-samples-wsrm -->
+ <war
+ warfile="${tests.output.dir}/test-libs/jaxws-samples-wsrm-api.war"
+ webxml="${tests.output.dir}/test-resources/jaxws/samples/wsrm/WEB-INF/web.xml">
+ <classes dir="${tests.output.dir}/test-classes">
+ <include name="org/jboss/test/ws/jaxws/samples/wsrm/service/**"/>
+ </classes>
+ <webinf dir="${tests.output.dir}/test-resources/jaxws/samples/wsrm/WEB-INF">
+ <include name="jbossws-cxf.xml"/>
+ </webinf>
+ <zipfileset
+ dir="${tests.output.dir}/test-resources/jaxws/samples/wsrm/WEB-INF/wsdl"
+ prefix="WEB-INF/wsdl"/>
+ </war>
+
<!-- Please add alphabetically -->
</target>
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/client/WSReliableMessagingWithAPITestCase.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,68 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.client;
+
+import java.net.URL;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+
+import junit.framework.Test;
+
+import org.jboss.test.ws.jaxws.samples.wsrm.generated.SimpleService;
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+/**
+ * Client invoking web service with WS-RM and using no xml descriptor
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 02-Aug-2010
+ *
+ */
+public final class WSReliableMessagingWithAPITestCase extends JBossWSTest
+{
+ private final String serviceURL = "http://" + getServerHost() + ":8080/jaxws-samples-wsrm-api/SimpleService";
+ private SimpleService proxy;
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(WSReliableMessagingWithAPITestCase.class, "jaxws-samples-wsrm-api.war");
+ }
+
+ @Override
+ protected void setUp() throws Exception
+ {
+ super.setUp();
+ QName serviceName = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "SimpleService");
+ URL wsdlURL = new URL(serviceURL + "?wsdl");
+ Service service = Service.create(wsdlURL, serviceName);
+ proxy = (SimpleService)service.getPort(SimpleService.class);
+ }
+
+ public void test() throws Exception
+ {
+ proxy.ping(); // one way call
+ assertEquals("Hello World!", proxy.echo("Hello World!")); // request response call
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Echo.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Echo.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Echo.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,62 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * <p>Java class for echo complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * <complexType name="echo">
+ * <complexContent>
+ * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * <sequence>
+ * <element name="arg0" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * </sequence>
+ * </restriction>
+ * </complexContent>
+ * </complexType>
+ * </pre>
+ */
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "echo", propOrder = { "arg0" })
+public class Echo
+{
+
+ protected String arg0;
+
+ public String getArg0()
+ {
+ return arg0;
+ }
+
+ public void setArg0(String value)
+ {
+ this.arg0 = value;
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/EchoResponse.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/EchoResponse.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/EchoResponse.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,64 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * <p>Java class for echoResponse complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * <complexType name="echoResponse">
+ * <complexContent>
+ * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * <sequence>
+ * <element name="return" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/>
+ * </sequence>
+ * </restriction>
+ * </complexContent>
+ * </complexType>
+ * </pre>
+ */
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "echoResponse", propOrder = { "_return" })
+public class EchoResponse
+{
+
+ @XmlElement(name = "return")
+ protected String _return;
+
+ public String getReturn()
+ {
+ return _return;
+ }
+
+ public void setReturn(String value)
+ {
+ this._return = value;
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/ObjectFactory.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/ObjectFactory.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/ObjectFactory.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import javax.xml.bind.JAXBElement;
+import javax.xml.bind.annotation.XmlElementDecl;
+import javax.xml.bind.annotation.XmlRegistry;
+import javax.xml.namespace.QName;
+
+/**
+ * This object contains factory methods for each
+ * Java content interface and Java element interface
+ * generated in the org.jboss.test.ws.jaxws.samples.wsrm.generated package.
+ * <p>An ObjectFactory allows you to programatically
+ * construct new instances of the Java representation
+ * for XML content. The Java representation of XML
+ * content can consist of schema derived interfaces
+ * and classes representing the binding of schema
+ * type definitions, element declarations and model
+ * groups. Factory methods for each of these are
+ * provided in this class.
+ *
+ */
+@XmlRegistry
+public class ObjectFactory {
+
+ private final static QName _EchoResponse_QNAME = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "echoResponse");
+ private final static QName _Echo_QNAME = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "echo");
+ private final static QName _Ping_QNAME = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "ping");
+
+ /**
+ * Create a new ObjectFactory that can be used to create new instances of schema derived classes for package: org.jboss.test.ws.jaxws.samples.wsrm.generated
+ *
+ */
+ public ObjectFactory() {
+ }
+
+ /**
+ * Create an instance of {@link Ping }
+ *
+ */
+ public Ping createPing() {
+ return new Ping();
+ }
+
+ /**
+ * Create an instance of {@link Echo }
+ *
+ */
+ public Echo createEcho() {
+ return new Echo();
+ }
+
+ /**
+ * Create an instance of {@link EchoResponse }
+ *
+ */
+ public EchoResponse createEchoResponse() {
+ return new EchoResponse();
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link EchoResponse }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", name = "echoResponse")
+ public JAXBElement<EchoResponse> createEchoResponse(EchoResponse value) {
+ return new JAXBElement<EchoResponse>(_EchoResponse_QNAME, EchoResponse.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Echo }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", name = "echo")
+ public JAXBElement<Echo> createEcho(Echo value) {
+ return new JAXBElement<Echo>(_Echo_QNAME, Echo.class, null, value);
+ }
+
+ /**
+ * Create an instance of {@link JAXBElement }{@code <}{@link Ping }{@code >}}
+ *
+ */
+ @XmlElementDecl(namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", name = "ping")
+ public JAXBElement<Ping> createPing(Ping value) {
+ return new JAXBElement<Ping>(_Ping_QNAME, Ping.class, null, value);
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Ping.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Ping.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/Ping.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * <p>Java class for ping complex type.
+ *
+ * <p>The following schema fragment specifies the expected content contained within this class.
+ *
+ * <pre>
+ * <complexType name="ping">
+ * <complexContent>
+ * <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
+ * <sequence>
+ * </sequence>
+ * </restriction>
+ * </complexContent>
+ * </complexType>
+ * </pre>
+ */
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "ping")
+public class Ping {}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,52 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebResult;
+import javax.jws.WebService;
+import javax.xml.ws.RequestWrapper;
+import javax.xml.ws.ResponseWrapper;
+
+/**
+ * This class was generated by Apache CXF (incubator) 2.0.5-incubator
+ * Wed Apr 16 14:19:06 CEST 2008
+ * Generated source version: 2.0.5-incubator
+ */
+@WebService(targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", name = "SimpleService")
+public interface SimpleService
+{
+
+ @Oneway
+ @RequestWrapper(localName = "ping", targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", className = "org.jboss.test.ws.jaxws.samples.wsrm.generated.Ping")
+ @WebMethod
+ public void ping();
+
+ @ResponseWrapper(localName = "echoResponse", targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", className = "org.jboss.test.ws.jaxws.samples.wsrm.generated.EchoResponse")
+ @RequestWrapper(localName = "echo", targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm", className = "org.jboss.test.ws.jaxws.samples.wsrm.generated.Echo")
+ @WebResult(name = "return", targetNamespace = "")
+ @WebMethod
+ public java.lang.String echo(@WebParam(name = "arg0", targetNamespace = "") java.lang.String arg0);
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService_Service.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService_Service.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/SimpleService_Service.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,84 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
+
+import java.net.MalformedURLException;
+import java.net.URL;
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import javax.xml.ws.WebEndpoint;
+import javax.xml.ws.WebServiceClient;
+import org.jboss.test.ws.jaxws.samples.wsrm.generated.SimpleService;
+
+/**
+ * This class was generated by Apache CXF (incubator) 2.0.5-incubator
+ * Wed Apr 16 14:19:06 CEST 2008
+ * Generated source version: 2.0.5-incubator
+ */
+@WebServiceClient
+(
+ name = "SimpleService",
+ targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm",
+ wsdlLocation = "file:/home/opalka/TODO/TUTORIAL/cxf/step1/java2wsdl/generated/wsdl/SimpleService.wsdl"
+)
+public class SimpleService_Service extends Service {
+
+ public final static URL WSDL_LOCATION;
+ public final static QName SERVICE = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "SimpleService");
+ public final static QName SimpleServicePort = new QName("http://www.jboss.org/jbossws/ws-extensions/wsrm", "SimpleServicePort");
+ static
+ {
+ URL url = null;
+ try
+ {
+ url = new URL("file:/home/opalka/TODO/TUTORIAL/cxf/step1/java2wsdl/generated/wsdl/SimpleService.wsdl");
+ }
+ catch (MalformedURLException e)
+ {
+ System.err.println("Can not initialize the default wsdl from file:/home/opalka/TODO/TUTORIAL/cxf/step1/java2wsdl/generated/wsdl/SimpleService.wsdl");
+ // e.printStackTrace();
+ }
+ WSDL_LOCATION = url;
+ }
+
+ public SimpleService_Service(URL wsdlLocation)
+ {
+ super(wsdlLocation, SERVICE);
+ }
+
+ public SimpleService_Service(URL wsdlLocation, QName serviceName)
+ {
+ super(wsdlLocation, serviceName);
+ }
+
+ public SimpleService_Service()
+ {
+ super(WSDL_LOCATION, SERVICE);
+ }
+
+ @WebEndpoint(name = "SimpleServicePort")
+ public SimpleService getSimpleServicePort()
+ {
+ return super.getPort(SimpleServicePort, SimpleService.class);
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/package-info.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/package-info.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/generated/package-info.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,23 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+(a)javax.xml.bind.annotation.XmlSchema(namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+package org.jboss.test.ws.jaxws.samples.wsrm.generated;
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/RMCheckInterceptor.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/RMCheckInterceptor.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/RMCheckInterceptor.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,78 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2010, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.service;
+
+import java.io.IOException;
+import java.io.InputStream;
+
+import org.apache.cxf.helpers.IOUtils;
+import org.apache.cxf.interceptor.Fault;
+import org.apache.cxf.io.CachedOutputStream;
+import org.apache.cxf.message.Message;
+import org.apache.cxf.phase.AbstractPhaseInterceptor;
+import org.apache.cxf.phase.Phase;
+
+/**
+ * A server side interceptor that verifies every incoming message has WS-RM stuff
+ * (meaning the client successfully understood server's policy enforcing ws-rm)
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 02-Aug-2010
+ */
+public class RMCheckInterceptor extends AbstractPhaseInterceptor<Message>
+{
+ private static final String RM_NS = "http://schemas.xmlsoap.org/ws/2005/02/rm";
+
+ public RMCheckInterceptor()
+ {
+ super(Phase.RECEIVE);
+ }
+
+ public void handleMessage(Message message) throws Fault
+ {
+ StringBuilder sb = new StringBuilder();
+ InputStream is = message.getContent(InputStream.class);
+ if (is != null)
+ {
+ CachedOutputStream bos = new CachedOutputStream();
+ try
+ {
+ IOUtils.copy(is, bos);
+ bos.flush();
+ is.close();
+ message.setContent(InputStream.class, bos.getInputStream());
+ bos.writeCacheTo(sb);
+ bos.close();
+ }
+ catch (IOException e)
+ {
+ throw new Fault(e);
+ }
+ }
+ if (!sb.toString().contains(RM_NS))
+ {
+ throw new Fault("Could not find any reference to namespace '" + RM_NS + "' in handled message.",
+ java.util.logging.Logger.getLogger(RMCheckInterceptor.class.getName()));
+ }
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/SimpleServiceImpl.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/SimpleServiceImpl.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/SimpleServiceImpl.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.service;
+
+import javax.jws.Oneway;
+import javax.jws.WebMethod;
+import javax.jws.WebService;
+
+import org.apache.cxf.feature.Features;
+import org.apache.cxf.interceptor.InInterceptors;
+
+@WebService
+(
+ name = "SimpleService",
+ serviceName = "SimpleService",
+ wsdlLocation = "WEB-INF/wsdl/SimpleService.wsdl",
+ targetNamespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm"
+)
+@Features(features = "org.apache.cxf.ws.policy.WSPolicyFeature")
+@InInterceptors(interceptors="org.jboss.test.ws.jaxws.samples.wsrm.service.RMCheckInterceptor")
+public class SimpleServiceImpl
+{
+ @Oneway
+ @WebMethod
+ public void ping()
+ {
+ System.out.println("ping()");
+ }
+
+ @WebMethod
+ public String echo(String s)
+ {
+ System.out.println("echo(" + s + ")");
+ return s;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Echo.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Echo.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Echo.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.service.jaxws;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * This class was generated by the CXF 2.0.5-incubator
+ * Wed Apr 16 13:57:06 CEST 2008
+ * Generated source version: 2.0.5-incubator
+ */
+@XmlRootElement(name = "echo", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "echo", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+public class Echo
+{
+
+ @XmlElement(name = "arg0")
+ private java.lang.String arg0;
+
+ public java.lang.String getArg0()
+ {
+ return this.arg0;
+ }
+
+ public void setArg0( java.lang.String newArg0 )
+ {
+ this.arg0 = newArg0;
+ }
+
+}
+
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/EchoResponse.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/EchoResponse.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/EchoResponse.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.service.jaxws;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * This class was generated by the CXF 2.0.5-incubator
+ * Wed Apr 16 13:57:06 CEST 2008
+ * Generated source version: 2.0.5-incubator
+ */
+@XmlRootElement(name = "echoResponse", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "echoResponse", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+public class EchoResponse
+{
+
+ @XmlElement(name = "return")
+ private java.lang.String _return;
+
+ public java.lang.String get_return()
+ {
+ return this._return;
+ }
+
+ public void set_return( java.lang.String new_return )
+ {
+ this._return = new_return;
+ }
+
+}
+
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Ping.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Ping.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsrm/service/jaxws/Ping.java 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,37 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.test.ws.jaxws.samples.wsrm.service.jaxws;
+
+import javax.xml.bind.annotation.XmlAccessType;
+import javax.xml.bind.annotation.XmlAccessorType;
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlType;
+
+/**
+ * This class was generated by the CXF 2.0.5-incubator
+ * Wed Apr 16 13:57:06 CEST 2008
+ * Generated source version: 2.0.5-incubator
+ */
+@XmlRootElement(name = "ping", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+(a)XmlAccessorType(XmlAccessType.FIELD)
+@XmlType(name = "ping", namespace = "http://www.jboss.org/jbossws/ws-extensions/wsrm")
+public class Ping {}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/web.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/web.xml (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/web.xml 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<web-app
+ version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
+ <servlet>
+ <servlet-name>SimpleService</servlet-name>
+ <servlet-class>org.jboss.test.ws.jaxws.samples.wsrm.service.SimpleServiceImpl</servlet-class>
+ </servlet>
+ <servlet-mapping>
+ <servlet-name>SimpleService</servlet-name>
+ <url-pattern>/*</url-pattern>
+ </servlet-mapping>
+</web-app>
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/wsdl/SimpleService.wsdl
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/wsdl/SimpleService.wsdl (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsrm/WEB-INF/wsdl/SimpleService.wsdl 2010-08-02 16:10:30 UTC (rev 12715)
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<wsdl:definitions name="SimpleService" targetNamespace="http://www.jboss.org/jbossws/ws-extensions/wsrm" xmlns:tns="http://www.jboss.org/jbossws/ws-extensions/wsrm" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
+
+ <wsdl:types>
+<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:tns="http://www.jboss.org/jbossws/ws-extensions/wsrm" attributeFormDefault="unqualified" elementFormDefault="unqualified" targetNamespace="http://www.jboss.org/jbossws/ws-extensions/wsrm">
+<xsd:element name="ping" type="tns:ping"/>
+<xsd:complexType name="ping">
+<xsd:sequence/>
+</xsd:complexType>
+<xsd:element name="echo" type="tns:echo"/>
+<xsd:complexType name="echo">
+<xsd:sequence>
+<xsd:element minOccurs="0" name="arg0" type="xsd:string"/>
+</xsd:sequence>
+</xsd:complexType>
+<xsd:element name="echoResponse" type="tns:echoResponse"/>
+<xsd:complexType name="echoResponse">
+<xsd:sequence>
+<xsd:element minOccurs="0" name="return" type="xsd:string"/>
+</xsd:sequence>
+</xsd:complexType>
+</xsd:schema>
+ </wsdl:types>
+ <wsdl:message name="echoResponse">
+ <wsdl:part name="parameters" element="tns:echoResponse">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="echo">
+ <wsdl:part name="parameters" element="tns:echo">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:message name="ping">
+ <wsdl:part name="parameters" element="tns:ping">
+ </wsdl:part>
+ </wsdl:message>
+ <wsdl:portType name="SimpleService">
+ <wsdl:operation name="ping">
+ <wsdl:input name="ping" message="tns:ping">
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="echo">
+ <wsdl:input name="echo" message="tns:echo">
+ </wsdl:input>
+ <wsdl:output name="echoResponse" message="tns:echoResponse">
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:portType>
+ <wsdl:binding name="SimpleServiceSoapBinding" type="tns:SimpleService">
+ <wsp:Policy>
+ <wswa:UsingAddressing xmlns:wswa="http://www.w3.org/2006/05/addressing/wsdl"/>
+ <wsrmp:RMAssertion xmlns:wsrmp="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"/>
+ </wsp:Policy>
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+ <wsdl:operation name="ping">
+ <soap:operation soapAction="" style="document"/>
+ <wsdl:input name="ping">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ </wsdl:operation>
+ <wsdl:operation name="echo">
+ <soap:operation soapAction="" style="document"/>
+ <wsdl:input name="echo">
+ <soap:body use="literal"/>
+ </wsdl:input>
+ <wsdl:output name="echoResponse">
+ <soap:body use="literal"/>
+ </wsdl:output>
+ </wsdl:operation>
+ </wsdl:binding>
+ <wsdl:service name="SimpleService">
+ <wsdl:port name="SimpleServicePort" binding="tns:SimpleServiceSoapBinding">
+ <soap:address location="http://localhost:9090/hello"/>
+ </wsdl:port>
+ </wsdl:service>
+</wsdl:definitions>
15 years, 9 months
JBossWS SVN: r12714 - stack/native/trunk.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2010-08-02 04:00:55 -0400 (Mon, 02 Aug 2010)
New Revision: 12714
Modified:
stack/native/trunk/profiles.xml.example
Log:
as m3 -> m4
Modified: stack/native/trunk/profiles.xml.example
===================================================================
--- stack/native/trunk/profiles.xml.example 2010-08-02 08:00:11 UTC (rev 12713)
+++ stack/native/trunk/profiles.xml.example 2010-08-02 08:00:55 UTC (rev 12714)
@@ -13,7 +13,7 @@
<properties>
<jboss501.home>/home/opalka/svn/jbossas/tags/JBoss_5_0_1_GA/build/output/jboss-5.0.1.GA</jboss501.home>
<jboss510.home>/home/opalka/svn/jbossas/tags/JBoss_5_1_0_GA/build/output/jboss-5.1.0.GA</jboss510.home>
- <jboss600.home>/home/opalka/svn/jbossas/tags/6.0.0.20100429-M3/build/target/jboss-6.0.0.20100429-M3</jboss600.home>
+ <jboss600.home>/home/opalka/svn/jbossas/tags/6.0.0.20100721-M4/build/target/6.0.0.20100721-M4</jboss600.home>
<jboss601.home>/home/opalka/svn/jbossas/trunk/build/output/jboss-6.0.0-SNAPSHOT</jboss601.home>
</properties>
</profile>
15 years, 9 months
JBossWS SVN: r12713 - stack/metro/trunk.
by jbossws-commits@lists.jboss.org
Author: richard.opalka(a)jboss.com
Date: 2010-08-02 04:00:11 -0400 (Mon, 02 Aug 2010)
New Revision: 12713
Modified:
stack/metro/trunk/profiles.xml.example
Log:
AS m3 -> m4
Modified: stack/metro/trunk/profiles.xml.example
===================================================================
--- stack/metro/trunk/profiles.xml.example 2010-08-02 07:29:55 UTC (rev 12712)
+++ stack/metro/trunk/profiles.xml.example 2010-08-02 08:00:11 UTC (rev 12713)
@@ -13,7 +13,7 @@
<properties>
<jboss501.home>/home/opalka/svn/jbossas/tags/JBoss_5_0_1_GA/build/output/jboss-5.0.1.GA</jboss501.home>
<jboss510.home>/home/opalka/svn/jbossas/tags/JBoss_5_1_0_GA/build/output/jboss-5.1.0.GA</jboss510.home>
- <jboss600.home>/home/opalka/svn/jbossas/tags/6.0.0.20100429-M3/build/target/jboss-6.0.0.20100429-M3</jboss600.home>
+ <jboss600.home>/home/opalka/svn/jbossas/tags/6.0.0.20100721-M4/build/target/6.0.0.20100721-M4</jboss600.home>
<jboss601.home>/home/opalka/svn/jbossas/trunk/build/output/jboss-6.0.0-SNAPSHOT</jboss601.home>
</properties>
</profile>
15 years, 9 months
JBossWS SVN: r12712 - framework/trunk/hudson/hudson-home/jobs/AS-TESTS-AS-6.0.0.
by jbossws-commits@lists.jboss.org
Author: alessio.soldano(a)jboss.com
Date: 2010-08-02 03:29:55 -0400 (Mon, 02 Aug 2010)
New Revision: 12712
Modified:
framework/trunk/hudson/hudson-home/jobs/AS-TESTS-AS-6.0.0/config.xml
Log:
AS 6 M4 has cxf stack, updating AS 600 tests on hudson
Modified: framework/trunk/hudson/hudson-home/jobs/AS-TESTS-AS-6.0.0/config.xml
===================================================================
--- framework/trunk/hudson/hudson-home/jobs/AS-TESTS-AS-6.0.0/config.xml 2010-08-02 07:09:25 UTC (rev 12711)
+++ framework/trunk/hudson/hudson-home/jobs/AS-TESTS-AS-6.0.0/config.xml 2010-08-02 07:29:55 UTC (rev 12712)
@@ -10,7 +10,7 @@
WORKSPACE=`pwd`
HUDSON_DIR=$WORKSPACE/framework-hudson
-STACK_DIR=$WORKSPACE/stack-native
+STACK_DIR=$WORKSPACE/stack-cxf
JBOSS_TARGET=jboss600
JBOSS_BIND_ADDRESS=(a)jboss.bind.address@
JBOSS_INSTANCE=@hudson.home@/jobs/AS-6.0.0/workspace/JBossAS-6.0.0/build/target/(a)hudson.jboss600.build@
@@ -100,8 +100,8 @@
<local>framework-hudson</local>
</hudson.scm.SubversionSCM-ModuleLocation>
<hudson.scm.SubversionSCM-ModuleLocation>
- <remote>@hudson.native.url@</remote>
- <local>stack-native</local>
+ <remote>@hudson.cxf.url@</remote>
+ <local>stack-cxf</local>
</hudson.scm.SubversionSCM-ModuleLocation>
</locations>
<useUpdate>true</useUpdate>
15 years, 9 months