This is an automated email from the ASF dual-hosted git repository. yasith pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/airavata.git
commit 348b5267da7579880a2cfa6da6d534def9813360 Author: karanrk <[email protected]> AuthorDate: Thu Nov 22 01:07:19 2018 -0500 adding debug logs for profiling airavata --- .../apache/airavata/api/server/handler/AiravataServerHandler.java | 7 +++++++ 1 file changed, 7 insertions(+) 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 dc62989604..669de75068 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 @@ -327,6 +327,7 @@ public class AiravataServerHandler implements Airavata.Iface { RegistryService.Client client = registryClientPool.getResource(); try { boolean isExists = client.isUserExists(gatewayId, userName); + logger.debug("Checking if the user" + userName + "exists in the gateway" + gatewayId); registryClientPool.returnResource(client); return isExists; } catch (Exception e) { @@ -413,6 +414,7 @@ public class AiravataServerHandler implements Airavata.Iface { registryClientPool.returnResource(registryClient); sharingClientPool.returnResource(sharingClient); + logger.debug("Airavata successfully created the gateway with " + gatewayId); return gatewayId; } catch (Exception e) { @@ -483,6 +485,7 @@ public class AiravataServerHandler implements Airavata.Iface { Gateway result = regClient.getGateway(gatewayId); registryClientPool.returnResource(regClient); return result; + logger.debug("Airavata found the gateway with " + gatewayId); } catch (Exception e) { logger.error("Error while getting the gateway", e); AiravataSystemException exception = new AiravataSystemException(); @@ -518,6 +521,7 @@ public class AiravataServerHandler implements Airavata.Iface { AiravataSystemException, AuthorizationException, TException { RegistryService.Client regClient = registryClientPool.getResource(); try { + logger.debug("Airavata searching for all gateways"); List<Gateway> result = regClient.getAllGateways(); registryClientPool.returnResource(regClient); return result; @@ -537,6 +541,7 @@ public class AiravataServerHandler implements Airavata.Iface { AiravataClientException, AiravataSystemException, AuthorizationException, TException { RegistryService.Client regClient = registryClientPool.getResource(); try { + logger.debug("Airavata verifying if the gateway with " + gatewayId + "exits") boolean result = regClient.isGatewayExist(gatewayId); registryClientPool.returnResource(regClient); return result; @@ -770,6 +775,7 @@ public class AiravataServerHandler implements Airavata.Iface { CredentialSummary credentialSummary = csClient.getCredentialSummary(tokenId, gatewayId); csClientPool.returnResource(csClient); sharingClientPool.returnResource(sharingClient); + logger.debug("Airavata retrived the credential summary for token " + tokenId + "GatewayId: "+ gatewayId); return credentialSummary; } catch (AuthorizationException ae) { String userName = authzToken.getClaimsMap().get(Constants.USER_NAME); @@ -809,6 +815,7 @@ public class AiravataServerHandler implements Airavata.Iface { List<CredentialSummary> credentialSummaries = csClient.getAllCredentialSummaries(type, accessibleTokenIds, gatewayId); csClientPool.returnResource(csClient); sharingClientPool.returnResource(sharingClient); + logger.debug("Airavata successfully retrived credential summaries of type " + type + " GatewayId: " + gatewayId); return credentialSummaries; } catch (Exception e) { String msg = "Error retrieving credential summaries of type " + type + ". GatewayId: "+ gatewayId;
