airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chath...@apache.org
Subject svn commit: r1419518 - in /airavata/trunk/modules/rest: client/src/main/java/org/apache/airavata/rest/client/ service/src/main/java/org/apache/airavata/services/registry/rest/resources/
Date Mon, 10 Dec 2012 15:24:30 GMT
Author: chathuri
Date: Mon Dec 10 15:24:28 2012
New Revision: 1419518

URL: http://svn.apache.org/viewvc?rev=1419518&view=rev
Log:
updating REST client and REST service

Modified:
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/DescriptorResourceClient.java
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ExperimentResourceClient.java
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProjectResourceClient.java
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProvenanceResourceClient.java
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/PublishedWorkflowResourceClient.java
    airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/UserWorkflowResourceClient.java
    airavata/trunk/modules/rest/service/src/main/java/org/apache/airavata/services/registry/rest/resources/PublishWorkflowRegistryResource.java

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/DescriptorResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/DescriptorResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/DescriptorResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/DescriptorResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -114,7 +114,9 @@ public class DescriptorResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
 
 
@@ -404,7 +406,9 @@ public class DescriptorResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ExperimentResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ExperimentResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ExperimentResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ExperimentResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -388,7 +388,9 @@ public class ExperimentResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -434,7 +436,9 @@ public class ExperimentResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProjectResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProjectResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProjectResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProjectResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -108,7 +108,9 @@ public class ProjectResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -150,7 +152,9 @@ public class ProjectResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProvenanceResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProvenanceResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProvenanceResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/ProvenanceResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -190,7 +190,9 @@ public class ProvenanceResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -487,7 +489,9 @@ public class ProvenanceResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -525,7 +529,9 @@ public class ProvenanceResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -1313,7 +1319,9 @@ public class ProvenanceResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 
@@ -1353,7 +1361,9 @@ public class ProvenanceResourceClient {
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/PublishedWorkflowResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/PublishedWorkflowResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/PublishedWorkflowResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/PublishedWorkflowResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -86,7 +86,7 @@ public class PublishedWorkflowResourceCl
         webResource = getPublishedWFRegistryBaseResource().path(
                 ResourcePathConstants.PublishedWFConstants.PUBLISHWF_EXIST);
         MultivaluedMap queryParams = new MultivaluedMapImpl();
-        queryParams.add("workflowname", workflowName);
+        queryParams.add("workflowName", workflowName);
         ClientResponse response = webResource.queryParams(queryParams).accept(
                 MediaType.TEXT_PLAIN).get(ClientResponse.class);
         int status = response.getStatus();
@@ -116,7 +116,9 @@ public class PublishedWorkflowResourceCl
             }
         }
         else {
-            return false;
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/UserWorkflowResourceClient.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/UserWorkflowResourceClient.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/UserWorkflowResourceClient.java
(original)
+++ airavata/trunk/modules/rest/client/src/main/java/org/apache/airavata/rest/client/UserWorkflowResourceClient.java
Mon Dec 10 15:24:28 2012
@@ -112,9 +112,10 @@ public class UserWorkflowResourceClient 
             } else {
                 return false;
             }
-        }
-        else {
-            return false;
+        }else {
+            logger.error(response.getEntity(String.class));
+            throw new RuntimeException("Failed : HTTP error code : "
+                    + status);
         }
     }
 

Modified: airavata/trunk/modules/rest/service/src/main/java/org/apache/airavata/services/registry/rest/resources/PublishWorkflowRegistryResource.java
URL: http://svn.apache.org/viewvc/airavata/trunk/modules/rest/service/src/main/java/org/apache/airavata/services/registry/rest/resources/PublishWorkflowRegistryResource.java?rev=1419518&r1=1419517&r2=1419518&view=diff
==============================================================================
--- airavata/trunk/modules/rest/service/src/main/java/org/apache/airavata/services/registry/rest/resources/PublishWorkflowRegistryResource.java
(original)
+++ airavata/trunk/modules/rest/service/src/main/java/org/apache/airavata/services/registry/rest/resources/PublishWorkflowRegistryResource.java
Mon Dec 10 15:24:28 2012
@@ -62,7 +62,7 @@ public class PublishWorkflowRegistryReso
     @GET
     @Path(ResourcePathConstants.PublishedWFConstants.PUBLISHWF_EXIST)
     @Produces(MediaType.TEXT_PLAIN)
-    public Response isPublishedWorkflowExists(@QueryParam("workflowname") String workflowname)
{
+    public Response isPublishedWorkflowExists(@QueryParam("workflowName") String workflowname)
{
         AiravataRegistry2 airavataRegistry = RegPoolUtils.acquireRegistry(context);
         try {
             boolean workflowExists = airavataRegistry.isPublishedWorkflowExists(workflowname);



Mime
View raw message