airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From machris...@apache.org
Subject [airavata] 01/02: AIRAVATA-2842 Deprecating a couple API methods
Date Mon, 16 Jul 2018 22:45:28 GMT
This is an automated email from the ASF dual-hosted git repository.

machristie pushed a commit to branch group-based-auth
in repository https://gitbox.apache.org/repos/asf/airavata.git

commit e3c45d1bad447db52561e7a0eb9d24cca4bea9fb
Author: Marcus Christie <machristie@apache.org>
AuthorDate: Mon Jul 16 18:44:09 2018 -0400

    AIRAVATA-2842 Deprecating a couple API methods
---
 .../apache/airavata/api/server/handler/AiravataServerHandler.java   | 6 ++++--
 thrift-interface-descriptions/airavata-apis/airavata_api.thrift     | 6 +++---
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/airavata-api/airavata-api-server/src/main/java/org/apache/airavata/api/server/handler/AiravataServerHandler.java
b/airavata-api/airavata-api-server/src/main/java/org/apache/airavata/api/server/handler/AiravataServerHandler.java
index df738ca..dc019ef 100644
--- a/airavata-api/airavata-api-server/src/main/java/org/apache/airavata/api/server/handler/AiravataServerHandler.java
+++ b/airavata-api/airavata-api-server/src/main/java/org/apache/airavata/api/server/handler/AiravataServerHandler.java
@@ -2267,7 +2267,7 @@ public class AiravataServerHandler implements Airavata.Iface {
      */
     @Override
     @SecurityCheck
-    public List<ApplicationModule> getAccessibleAppModules(AuthzToken authzToken, String
gatewayId, ResourcePermissionType permissionType) throws InvalidRequestException,
+    public List<ApplicationModule> getAccessibleAppModules(AuthzToken authzToken, String
gatewayId) throws InvalidRequestException,
             AiravataClientException, AiravataSystemException, AuthorizationException, TException
{
         RegistryService.Client regClient = registryClientPool.getResource();
         String userName = authzToken.getClaimsMap().get(Constants.USER_NAME);
@@ -2284,7 +2284,7 @@ public class AiravataServerHandler implements Airavata.Iface {
                 SearchCriteria permissionTypeFilter = new SearchCriteria();
                 permissionTypeFilter.setSearchField(EntitySearchField.PERMISSION_TYPE_ID);
                 permissionTypeFilter.setSearchCondition(SearchCondition.EQUAL);
-                permissionTypeFilter.setValue(gatewayId + ":" + permissionType.name());
+                permissionTypeFilter.setValue(gatewayId + ":" + ResourcePermissionType.READ);
                 sharingFilters.add(permissionTypeFilter);
                 sharingClient.searchEntities(authzToken.getClaimsMap().get(Constants.GATEWAY_ID),
                         userName + "@" + gatewayId, sharingFilters, 0, -1).forEach(a ->
accessibleAppDeploymentIds.add(a.entityId));
@@ -2561,6 +2561,7 @@ public class AiravataServerHandler implements Airavata.Iface {
      */
     @Override
     @SecurityCheck
+    @Deprecated
     public List<String> getAppModuleDeployedResources(AuthzToken authzToken, String
appModuleId) throws InvalidRequestException,
             AiravataClientException, AiravataSystemException, AuthorizationException, TException
{
         RegistryService.Client regClient = registryClientPool.getResource();
@@ -2889,6 +2890,7 @@ public class AiravataServerHandler implements Airavata.Iface {
      */
     @Override
     @SecurityCheck
+    @Deprecated
     public Map<String, String> getAvailableAppInterfaceComputeResources(AuthzToken
authzToken, String appInterfaceId)
             throws InvalidRequestException, AiravataClientException, AiravataSystemException,
AuthorizationException, TException {
         RegistryService.Client regClient = registryClientPool.getResource();
diff --git a/thrift-interface-descriptions/airavata-apis/airavata_api.thrift b/thrift-interface-descriptions/airavata-apis/airavata_api.thrift
index 6b64223..4b5d787 100644
--- a/thrift-interface-descriptions/airavata-apis/airavata_api.thrift
+++ b/thrift-interface-descriptions/airavata-apis/airavata_api.thrift
@@ -1405,15 +1405,13 @@ service Airavata {
    *
    * @param gatewayId
    *    ID of the gateway which need to list all accessible application deployment documentation.
-   * @param permissionType
-   *    ResourcePermissionType to check for this user
    *
    * @return list
    *    Returns the list of all Application Module Objects that are accessible to the user.
    *
   */
   list<application_deployment_model.ApplicationModule> getAccessibleAppModules (1:
required security_model.AuthzToken authzToken,
-                2: required string gatewayId, 3: required group_manager_model.ResourcePermissionType
permissionType)
+                2: required string gatewayId)
         throws (1: airavata_errors.InvalidRequestException ire,
                 2: airavata_errors.AiravataClientException ace,
                 3: airavata_errors.AiravataSystemException ase,
@@ -1573,6 +1571,7 @@ service Airavata {
    *   Returns a list of Deployed Resources.
    *
   */
+  // FIXME: Deprecated, use getApplicationDeploymentsForAppModuleAndGroupResourceProfile
instead
   list<string> getAppModuleDeployedResources(1: required security_model.AuthzToken
authzToken, 2: required string appModuleId)
       	throws (1: airavata_errors.InvalidRequestException ire,
                 2: airavata_errors.AiravataClientException ace,
@@ -1785,6 +1784,7 @@ service Airavata {
    *   Deployments of each modules listed within the interfaces will be listed.
    *
   */
+  // FIXME: Deprecated, use getApplicationDeploymentsForAppModuleAndGroupResourceProfile
instead
   map<string, string> getAvailableAppInterfaceComputeResources(1: required security_model.AuthzToken
authzToken, 2: required string appInterfaceId)
       	throws (1: airavata_errors.InvalidRequestException ire,
                 2: airavata_errors.AiravataClientException ace,


Mime
View raw message