cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r753584 - in /cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc: build.xml download_wsdl.xml pom.xml src/main/java/interop/client/Client.java src/main/java/interop/server/Server.java
Date Sat, 14 Mar 2009 02:11:56 GMT
Author: dkulp
Date: Sat Mar 14 02:11:56 2009
New Revision: 753584

URL: http://svn.apache.org/viewvc?rev=753584&view=rev
Log:
Updates to get wssc working well from command line

Added:
    cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/download_wsdl.xml
      - copied unchanged from r753480, cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/build.xml
Removed:
    cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/build.xml
Modified:
    cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/pom.xml
    cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/client/Client.java
    cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/server/Server.java

Modified: cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/pom.xml
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/pom.xml?rev=753584&r1=753583&r2=753584&view=diff
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/pom.xml (original)
+++ cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/pom.xml Sat
Mar 14 02:11:56 2009
@@ -24,7 +24,8 @@
     <version>1.0</version>
     <properties>
         <cxf.version>[2,)</cxf.version>
-        <test.method></test.method>
+        <test.method>ALL</test.method>
+        <test.server>MS</test.server>
         <baseLocation>http://131.107.153.205/Security_WsSecurity_Service_Indigo/WSSecureConversation.svc</baseLocation>
     </properties>
     <build>
@@ -63,7 +64,7 @@
                         </goals>
                         <configuration>
                             <tasks>
-                                <ant inheritRefs="true" antfile="${basedir}/build.xml">
+                                <ant inheritRefs="true" antfile="${basedir}/download_wsdl.xml">
                                     <property value="${basedir}/target" name="build.dir"
/>
                                     <property name="baseLocation" value="${baseLocation}"/>
                                     <target name="download" />
@@ -132,7 +133,8 @@
                                     <goal>java</goal>
                                 </goals>
                                 <configuration>
-                                    <mainClass>demo.hw.server.Server</mainClass>
+                                    <classpathScope>test</classpathScope>
+                                    <mainClass>interop.server.Server</mainClass>
                                 </configuration>
                             </execution>
                         </executions>
@@ -158,6 +160,7 @@
                                     <classpathScope>test</classpathScope>
                                     <mainClass>interop.client.Client</mainClass>
                                     <arguments>
+                                        <argument>${test.server}</argument>
                                         <argument>${test.method}</argument>
                                     </arguments>
                                 </configuration>

Modified: cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/client/Client.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/client/Client.java?rev=753584&r1=753583&r2=753584&view=diff
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/client/Client.java
(original)
+++ cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/client/Client.java
Sat Mar 14 02:11:56 2009
@@ -51,8 +51,21 @@
         throws Exception {
 
         boolean useLocalWCFServices = false;
+        boolean local = false;
 
-        if (argv.length < 1 || "".equals(argv[0]) || argv[0] == null) {
+        if (argv.length > 0 && "local".equalsIgnoreCase(argv[0])) {
+            local = true;
+        }
+        if (argv.length > 0 && "local".equalsIgnoreCase(argv[0])
+            || "ms".equalsIgnoreCase(argv[0])) {        
+            String tmp[] = new String[argv.length - 1];
+            System.arraycopy(argv, 1, tmp, 0, tmp.length);
+            argv = tmp;
+        }
+        System.out.println(argv[0] + "    " + local);
+
+        if (argv.length < 1 || "".equals(argv[0]) 
+            || argv[0] == null || "ALL".equals(argv[0])) {
             argv = new String[] {
                 //"SecureConversation_UserNameOverTransport_IPingService", 
                              //service not running on the https port
@@ -98,6 +111,7 @@
         //argv = new String[] {argv[4]};
         //argv = new String[] {"_X10_IPingService"};
         
+        
         new SpringBusFactory().createBus("etc/client.xml");
         List<String> results = new ArrayList<String>(argv.length);
         URL wsdlLocation = null;
@@ -105,7 +119,9 @@
         for (String portPrefix : argv) {
             try {
                 PingService svc;
-                //wsdlLocation = new URL("http://localhost:9001/" + portPrefix + "?wsdl");
+                if (local) {
+                    wsdlLocation = new URL("http://localhost:9001/" + portPrefix + "?wsdl");
+                }
                 boolean isLocal = false;
                 try {
                     if (wsdlLocation != null) {

Modified: cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/server/Server.java
URL: http://svn.apache.org/viewvc/cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/server/Server.java?rev=753584&r1=753583&r2=753584&view=diff
==============================================================================
--- cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/server/Server.java
(original)
+++ cxf/trunk/distribution/src/main/release/samples/ws_security/interopfest/wssc/src/main/java/interop/server/Server.java
Sat Mar 14 02:11:56 2009
@@ -25,11 +25,12 @@
 
 import org.apache.cxf.bus.spring.SpringBusFactory;
 import org.apache.cxf.ws.security.SecurityConstants;
+import org.apache.ws.security.WSSConfig;
 
 
 public class Server {
     protected Server(String baseUrl) throws Exception {
-        
+        WSSConfig.getDefaultWSConfig();
         new SpringBusFactory().createBus("etc/server.xml");
         
         //"SecureConversation_UserNameOverTransport_IPingService",



Mime
View raw message