airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From patanac...@apache.org
Subject svn commit: r1181997 - in /incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api: Axis2Registry.java impl/JCRRegistry.java
Date Tue, 11 Oct 2011 18:17:48 GMT
Author: patanachai
Date: Tue Oct 11 18:17:48 2011
New Revision: 1181997

URL: http://svn.apache.org/viewvc?rev=1181997&view=rev
Log:
AIRAVATA-137 implement a simple version of generate WSDL from ServiceDescription

Modified:
    incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/Axis2Registry.java
    incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/impl/JCRRegistry.java

Modified: incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/Axis2Registry.java
URL: http://svn.apache.org/viewvc/incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/Axis2Registry.java?rev=1181997&r1=1181996&r2=1181997&view=diff
==============================================================================
--- incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/Axis2Registry.java
(original)
+++ incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/Axis2Registry.java
Tue Oct 11 18:17:48 2011
@@ -33,7 +33,7 @@ public interface Axis2Registry extends R
      * @param service
      * @param WSDL
      */
-    public String saveWSDL(String serviceName, String WSDL);
+    public String saveWSDL(ServiceDescription service, String WSDL);
     
     /**
      * Save WSDL for Axis2
@@ -41,14 +41,14 @@ public interface Axis2Registry extends R
      * @param serviceName
      * @param service
      */
-    public String saveWSDL(String serviceName, ServiceDescription service);
+    public String saveWSDL(ServiceDescription service);
     
     
     /**
      * Load WSDL for Axis2
      * 
-     * @param serviceName
+     * @param serviceId
      * @return WSDL
      */
-    public String getWSDL(String serviceName);
+    public String getWSDL(String serviceId);
 }

Modified: incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/impl/JCRRegistry.java
URL: http://svn.apache.org/viewvc/incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/impl/JCRRegistry.java?rev=1181997&r1=1181996&r2=1181997&view=diff
==============================================================================
--- incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/impl/JCRRegistry.java
(original)
+++ incubator/airavata/trunk/modules/commons/registry-api/src/main/java/org/apache/airavata/registry/api/impl/JCRRegistry.java
Tue Oct 11 18:17:48 2011
@@ -24,7 +24,12 @@ package org.apache.airavata.registry.api
 import java.lang.reflect.Constructor;
 import java.net.URI;
 import java.sql.Timestamp;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.Calendar;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.TimeZone;
 
 import javax.jcr.Credentials;
 import javax.jcr.Node;
@@ -53,6 +58,7 @@ import org.apache.airavata.registry.api.
 import org.apache.airavata.registry.api.exception.ServiceDescriptionRetrieveException;
 import org.apache.airavata.registry.api.user.UserManager;
 import org.apache.airavata.registry.api.user.UserManagerFactory;
+import org.apache.airavata.registry.api.util.Axis2Util;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -493,13 +499,13 @@ public class JCRRegistry implements Axis
         return result;
     }
 
-    public String saveWSDL(String name, String WSDL) {
+    public String saveWSDL(ServiceDescription service, String WSDL) {
         Session session = null;
         String result = null;
         try {
             session = getSession();
             Node serviceNode = getServiceNode(session);
-            Node node = getOrAddNode(serviceNode, name);
+            Node node = getOrAddNode(serviceNode, service.getId());
             node.setProperty(WSDL_PROPERTY_NAME, WSDL);
             session.save();
 
@@ -514,9 +520,8 @@ public class JCRRegistry implements Axis
         return result;
     }
 
-    public String saveWSDL(String serviceName, ServiceDescription service) {
-        // TODO Auto-generated method stub
-        return null;
+    public String saveWSDL(ServiceDescription service) {
+        return saveWSDL(service, Axis2Util.generateWSDL(service));
     }
 
     public String getWSDL(String serviceName) {



Mime
View raw message