Rename gatewayservice to tenantservice in thrift interfaces
Project: http://git-wip-us.apache.org/repos/asf/airavata/repo Commit: http://git-wip-us.apache.org/repos/asf/airavata/commit/2eb3ee7c Tree: http://git-wip-us.apache.org/repos/asf/airavata/tree/2eb3ee7c Diff: http://git-wip-us.apache.org/repos/asf/airavata/diff/2eb3ee7c Branch: refs/heads/user-profile Commit: 2eb3ee7c68065c2dc5931091a5d280cb0ec74523 Parents: 45bacd6 Author: Gourav Shenoy <[email protected]> Authored: Wed Mar 8 17:48:15 2017 -0500 Committer: Gourav Shenoy <[email protected]> Committed: Wed Mar 8 17:48:15 2017 -0500 ---------------------------------------------------------------------- .../commons/tenant/entities/Gateway.java | 255 - .../commons/tenant/entities/GatewayEntity.java | 255 + .../tenant/cpi/TenantProfileService.java | 6760 ++++++++++++++++++ .../TenantProfileServiceException.java | 407 ++ .../tenant/cpi/profile_tenant_cpiConstants.java | 59 + .../profile/user/cpi/UserProfileService.java | 2 +- .../exception/UserProfileServiceException.java | 2 +- .../profile-gateway/profile-gateway-cpi.thrift | 56 - .../profile_gateway_cpi_errors.thrift | 32 - .../profile-service/profile-service-cpi.thrift | 2 +- .../profile-tenant/profile-tenant-cpi.thrift | 56 + .../profile_tenant_cpi_errors.thrift | 32 + 12 files changed, 7572 insertions(+), 346 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/airavata/blob/2eb3ee7c/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/Gateway.java ---------------------------------------------------------------------- diff --git a/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/Gateway.java b/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/Gateway.java deleted file mode 100644 index 0a67383..0000000 --- a/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/Gateway.java +++ /dev/null @@ -1,255 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * -*/ -package org.apache.airavata.service.profile.commons.tenant.entities; - -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -import javax.persistence.*; -import java.sql.Timestamp; -import java.util.Date; - -@Entity -@Table(name = "GATEWAY") -public class Gateway { - private final static Logger logger = LoggerFactory.getLogger(Gateway.class); - private String gatewayId; - private String gatewayName; - private String domain; - private String emailAddress; - private String gatewayApprovalStatus; - private String gatewayAcronym; - private String gatewayUrl; - private String gatewayPublicAbstract; - private String reviewProposalDescription; - private String gatewayAdminFirstName; - private String getGatewayAdminLastName; - private String gatewayAdminEmail; - private String identityServerUserName; - private String identityServerPasswordToken; - private String declinedReason; - private String oauthClientId; - private String getOauthClientSecret; - private long requestCreationTime; - private String requesterUsername; - - @Id - @Column(name = "GATEWAY_ID") - public String getGatewayId() { - return gatewayId; - } - - public void setGatewayId(String gatewayId) { - this.gatewayId = gatewayId; - } - - @Column(name = "GATEWAY_NAME") - public String getGatewayName() { - return gatewayName; - } - - public void setGatewayName(String gatewayName) { - this.gatewayName = gatewayName; - } - - @Column(name = "GATEWAY_DOMAIN") - public String getDomain() { - return domain; - } - - public void setDomain(String domain) { - this.domain = domain; - } - - @Column(name = "EMAIL_ADDRESS") - public String getEmailAddress() { - return emailAddress; - } - - public void setEmailAddress(String emailAddress) { - this.emailAddress = emailAddress; - } - - @Column(name = "GATEWAY_APPROVAL_STATUS") - public String getGatewayApprovalStatus() { - return gatewayApprovalStatus; - } - - public void setGatewayApprovalStatus(String gatewayApprovalStatus) { - this.gatewayApprovalStatus = gatewayApprovalStatus; - } - - @Column(name = "GATEWAY_ACRONYM") - public String getGatewayAcronym() { - return gatewayAcronym; - } - - public void setGatewayAcronym(String gatewayAcronym) { - this.gatewayAcronym = gatewayAcronym; - } - - @Column(name = "GATEWAY_URL") - public String getGatewayUrl() { - return gatewayUrl; - } - - public void setGatewayUrl(String gatewayUrl) { - this.gatewayUrl = gatewayUrl; - } - - @Column(name = "GATEWAY_PUBLIC_ABSTRACT") - public String getGatewayPublicAbstract() { - return gatewayPublicAbstract; - } - - public void setGatewayPublicAbstract(String gatewayPublicAbstract) { - this.gatewayPublicAbstract = gatewayPublicAbstract; - } - - @Column(name = "GATEWAY_REVIEW_PROPOSAL_DESCRIPTION") - public String getReviewProposalDescription() { - return reviewProposalDescription; - } - - public void setReviewProposalDescription(String reviewProposalDescription) { - this.reviewProposalDescription = reviewProposalDescription; - } - - @Column(name = "GATEWAY_ADMIN_FIRST_NAME") - public String getGatewayAdminFirstName() { - return gatewayAdminFirstName; - } - - public void setGatewayAdminFirstName(String gatewayAdminFirstName) { - this.gatewayAdminFirstName = gatewayAdminFirstName; - } - - @Column(name = "GATEWAY_ADMIN_LAST_NAME") - public String getGetGatewayAdminLastName() { - return getGatewayAdminLastName; - } - - public void setGetGatewayAdminLastName(String getGatewayAdminLastName) { - this.getGatewayAdminLastName = getGatewayAdminLastName; - } - - @Column(name = "GATEWAY_ADMIN_EMAIL") - public String getGatewayAdminEmail() { - return gatewayAdminEmail; - } - - public void setGatewayAdminEmail(String gatewayAdminEmail) { - this.gatewayAdminEmail = gatewayAdminEmail; - } - - @Column(name = "IDENTITY_SERVER_USERNAME") - public String getIdentityServerUserName() { - return identityServerUserName; - } - - public void setIdentityServerUserName(String identityServerUserName) { - this.identityServerUserName = identityServerUserName; - } - - @Column(name = "IDENTITY_SERVER_PASSWORD_TOKEN") - public String getIdentityServerPasswordToken() { - return identityServerPasswordToken; - } - - public void setIdentityServerPasswordToken(String identityServerPasswordToken) { - this.identityServerPasswordToken = identityServerPasswordToken; - } - - @Column(name = "REQUESTER_USERNAME") - public String getRequesterUsername() { - return requesterUsername; - } - - public void setRequesterUsername(String requesterUsername) { - this.requesterUsername = requesterUsername; - } - - @Column(name = "DECLINED_REASON") - public String getDeclinedReason() { - return declinedReason; - } - - public void setDeclinedReason(String declinedReason) { - this.declinedReason = declinedReason; - } - - @Column(name = "OAUTH_CLIENT_ID") - public String getOauthClientId() { - return oauthClientId; - } - - public void setOauthClientId(String oauthClientId) { - this.oauthClientId = oauthClientId; - } - - @Column(name = "REQUEST_CREATION_TIME") - public long getRequestCreationTime() { - return requestCreationTime; - } - - public void setRequestCreationTime(long requestCreationTime) { - this.requestCreationTime = requestCreationTime; - } - - @Column(name = "OAUTH_CLIENT_SECRET") - public String getGetOauthClientSecret() { - return getOauthClientSecret; - } - - public void setGetOauthClientSecret(String oauthClientSecret) { - this.getOauthClientSecret = oauthClientSecret; - } - - @PrePersist - void createdAt() { - this.requestCreationTime = new Date().getTime(); - } - - @Override - public String toString() { - return "Gateway{" + - "gatewayId='" + gatewayId + '\'' + - ", gatewayName='" + gatewayName + '\'' + - ", domain='" + domain + '\'' + - ", emailAddress='" + emailAddress + '\'' + - ", gatewayApprovalStatus='" + gatewayApprovalStatus + '\'' + - ", gatewayAcronym='" + gatewayAcronym + '\'' + - ", gatewayUrl='" + gatewayUrl + '\'' + - ", gatewayPublicAbstract='" + gatewayPublicAbstract + '\'' + - ", reviewProposalDescription='" + reviewProposalDescription + '\'' + - ", gatewayAdminFirstName='" + gatewayAdminFirstName + '\'' + - ", getGatewayAdminLastName='" + getGatewayAdminLastName + '\'' + - ", gatewayAdminEmail='" + gatewayAdminEmail + '\'' + - ", identityServerUserName='" + identityServerUserName + '\'' + - ", identityServerPasswordToken='" + identityServerPasswordToken + '\'' + - ", declinedReason='" + declinedReason + '\'' + - ", oauthClientId='" + oauthClientId + '\'' + - ", getOauthClientSecret='" + getOauthClientSecret + '\'' + - ", requestCreationTime=" + requestCreationTime + - ", requesterUsername='" + requesterUsername + '\'' + - '}'; - } -} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/airavata/blob/2eb3ee7c/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/GatewayEntity.java ---------------------------------------------------------------------- diff --git a/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/GatewayEntity.java b/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/GatewayEntity.java new file mode 100644 index 0000000..0a67383 --- /dev/null +++ b/airavata-services/profile-service/profile-service-commons/src/main/java/org/apache/airavata/service/profile/commons/tenant/entities/GatewayEntity.java @@ -0,0 +1,255 @@ +/* + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * +*/ +package org.apache.airavata.service.profile.commons.tenant.entities; + +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +import javax.persistence.*; +import java.sql.Timestamp; +import java.util.Date; + +@Entity +@Table(name = "GATEWAY") +public class Gateway { + private final static Logger logger = LoggerFactory.getLogger(Gateway.class); + private String gatewayId; + private String gatewayName; + private String domain; + private String emailAddress; + private String gatewayApprovalStatus; + private String gatewayAcronym; + private String gatewayUrl; + private String gatewayPublicAbstract; + private String reviewProposalDescription; + private String gatewayAdminFirstName; + private String getGatewayAdminLastName; + private String gatewayAdminEmail; + private String identityServerUserName; + private String identityServerPasswordToken; + private String declinedReason; + private String oauthClientId; + private String getOauthClientSecret; + private long requestCreationTime; + private String requesterUsername; + + @Id + @Column(name = "GATEWAY_ID") + public String getGatewayId() { + return gatewayId; + } + + public void setGatewayId(String gatewayId) { + this.gatewayId = gatewayId; + } + + @Column(name = "GATEWAY_NAME") + public String getGatewayName() { + return gatewayName; + } + + public void setGatewayName(String gatewayName) { + this.gatewayName = gatewayName; + } + + @Column(name = "GATEWAY_DOMAIN") + public String getDomain() { + return domain; + } + + public void setDomain(String domain) { + this.domain = domain; + } + + @Column(name = "EMAIL_ADDRESS") + public String getEmailAddress() { + return emailAddress; + } + + public void setEmailAddress(String emailAddress) { + this.emailAddress = emailAddress; + } + + @Column(name = "GATEWAY_APPROVAL_STATUS") + public String getGatewayApprovalStatus() { + return gatewayApprovalStatus; + } + + public void setGatewayApprovalStatus(String gatewayApprovalStatus) { + this.gatewayApprovalStatus = gatewayApprovalStatus; + } + + @Column(name = "GATEWAY_ACRONYM") + public String getGatewayAcronym() { + return gatewayAcronym; + } + + public void setGatewayAcronym(String gatewayAcronym) { + this.gatewayAcronym = gatewayAcronym; + } + + @Column(name = "GATEWAY_URL") + public String getGatewayUrl() { + return gatewayUrl; + } + + public void setGatewayUrl(String gatewayUrl) { + this.gatewayUrl = gatewayUrl; + } + + @Column(name = "GATEWAY_PUBLIC_ABSTRACT") + public String getGatewayPublicAbstract() { + return gatewayPublicAbstract; + } + + public void setGatewayPublicAbstract(String gatewayPublicAbstract) { + this.gatewayPublicAbstract = gatewayPublicAbstract; + } + + @Column(name = "GATEWAY_REVIEW_PROPOSAL_DESCRIPTION") + public String getReviewProposalDescription() { + return reviewProposalDescription; + } + + public void setReviewProposalDescription(String reviewProposalDescription) { + this.reviewProposalDescription = reviewProposalDescription; + } + + @Column(name = "GATEWAY_ADMIN_FIRST_NAME") + public String getGatewayAdminFirstName() { + return gatewayAdminFirstName; + } + + public void setGatewayAdminFirstName(String gatewayAdminFirstName) { + this.gatewayAdminFirstName = gatewayAdminFirstName; + } + + @Column(name = "GATEWAY_ADMIN_LAST_NAME") + public String getGetGatewayAdminLastName() { + return getGatewayAdminLastName; + } + + public void setGetGatewayAdminLastName(String getGatewayAdminLastName) { + this.getGatewayAdminLastName = getGatewayAdminLastName; + } + + @Column(name = "GATEWAY_ADMIN_EMAIL") + public String getGatewayAdminEmail() { + return gatewayAdminEmail; + } + + public void setGatewayAdminEmail(String gatewayAdminEmail) { + this.gatewayAdminEmail = gatewayAdminEmail; + } + + @Column(name = "IDENTITY_SERVER_USERNAME") + public String getIdentityServerUserName() { + return identityServerUserName; + } + + public void setIdentityServerUserName(String identityServerUserName) { + this.identityServerUserName = identityServerUserName; + } + + @Column(name = "IDENTITY_SERVER_PASSWORD_TOKEN") + public String getIdentityServerPasswordToken() { + return identityServerPasswordToken; + } + + public void setIdentityServerPasswordToken(String identityServerPasswordToken) { + this.identityServerPasswordToken = identityServerPasswordToken; + } + + @Column(name = "REQUESTER_USERNAME") + public String getRequesterUsername() { + return requesterUsername; + } + + public void setRequesterUsername(String requesterUsername) { + this.requesterUsername = requesterUsername; + } + + @Column(name = "DECLINED_REASON") + public String getDeclinedReason() { + return declinedReason; + } + + public void setDeclinedReason(String declinedReason) { + this.declinedReason = declinedReason; + } + + @Column(name = "OAUTH_CLIENT_ID") + public String getOauthClientId() { + return oauthClientId; + } + + public void setOauthClientId(String oauthClientId) { + this.oauthClientId = oauthClientId; + } + + @Column(name = "REQUEST_CREATION_TIME") + public long getRequestCreationTime() { + return requestCreationTime; + } + + public void setRequestCreationTime(long requestCreationTime) { + this.requestCreationTime = requestCreationTime; + } + + @Column(name = "OAUTH_CLIENT_SECRET") + public String getGetOauthClientSecret() { + return getOauthClientSecret; + } + + public void setGetOauthClientSecret(String oauthClientSecret) { + this.getOauthClientSecret = oauthClientSecret; + } + + @PrePersist + void createdAt() { + this.requestCreationTime = new Date().getTime(); + } + + @Override + public String toString() { + return "Gateway{" + + "gatewayId='" + gatewayId + '\'' + + ", gatewayName='" + gatewayName + '\'' + + ", domain='" + domain + '\'' + + ", emailAddress='" + emailAddress + '\'' + + ", gatewayApprovalStatus='" + gatewayApprovalStatus + '\'' + + ", gatewayAcronym='" + gatewayAcronym + '\'' + + ", gatewayUrl='" + gatewayUrl + '\'' + + ", gatewayPublicAbstract='" + gatewayPublicAbstract + '\'' + + ", reviewProposalDescription='" + reviewProposalDescription + '\'' + + ", gatewayAdminFirstName='" + gatewayAdminFirstName + '\'' + + ", getGatewayAdminLastName='" + getGatewayAdminLastName + '\'' + + ", gatewayAdminEmail='" + gatewayAdminEmail + '\'' + + ", identityServerUserName='" + identityServerUserName + '\'' + + ", identityServerPasswordToken='" + identityServerPasswordToken + '\'' + + ", declinedReason='" + declinedReason + '\'' + + ", oauthClientId='" + oauthClientId + '\'' + + ", getOauthClientSecret='" + getOauthClientSecret + '\'' + + ", requestCreationTime=" + requestCreationTime + + ", requesterUsername='" + requesterUsername + '\'' + + '}'; + } +} \ No newline at end of file
