[ 
https://issues.apache.org/jira/browse/AIRAVATA-2712?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16412085#comment-16412085
 ] 

ASF GitHub Bot commented on AIRAVATA-2712:
------------------------------------------

machristie commented on a change in pull request #185: [AIRAVATA-2712] 
Refactoring App Catalog Implementation - UserResourceProfile
URL: https://github.com/apache/airavata/pull/185#discussion_r176859591
 
 

 ##########
 File path: 
modules/registry-refactoring/src/main/java/org/apache/airavata/registry/core/entities/appcatalog/UserComputeResourcePreferenceEntity.java
 ##########
 @@ -0,0 +1,195 @@
+/*
+ *
+ * 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.registry.core.entities.appcatalog;
+
+import javax.persistence.*;
+import java.sql.Timestamp;
+
+/**
+ * The persistent class for the user_compute_resource_preference database 
table.
+ */
+@Entity
+@Table(name = "USER_COMPUTE_RESOURCE_PREFERENCE")
+@IdClass(UserComputeResourcePreferencePK.class)
+public class UserComputeResourcePreferenceEntity {
+    private static final long serialVersionUID = 1L;
+
+    @Id
+    @Column(name = "RESOURCE_ID")
+    private String computeResourceId;
+
+    @Id
+    @Column(name = "USER_ID")
+    private String userId;
+
+    @Id
+    @Column(name = "GATEWAY_ID")
+    private String gatewayId;
+
+    @Column(name = "PREFERED_BATCH_QUEUE")
+    private String preferredBatchQueue;
+
+    @Column(name = "RESOURCE_CS_TOKEN")
+    private String resourceSpecificCredentialStoreToken;
+
+    @Column(name = "LOGIN_USERNAME")
+    private String loginUserName;
+
+    @Column(name = "ALLOCATION_PROJECT_NUMBER")
+    private String allocationProjectNumber;
+
+    @Column(name = "QUALITY_OF_SERVICE")
+    private String qualityOfService;
+
+    @Column(name = "RESERVATION")
+    private String reservation;
+
+    @Column(name = "RESERVATION_START_TIME")
+    private Timestamp reservationStartTime;
+
+    @Column(name = "RESERVATION_END_TIME")
+    private Timestamp reservationEndTime;
+
+    @Column(name = "SCRATCH_LOCATION")
+    private String scratchLocation;
+
+    @Column(name = "VALIDATED")
+    private boolean validated;
+
+    @ManyToOne(targetEntity = UserResourceProfileEntity.class, cascade = 
CascadeType.MERGE)
+    @JoinColumn(name = "USER_ID")
 
 Review comment:
   This should join on USER_ID and GATEWAY_ID

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Refactoring App Catalog Implementation - User Resource Profile
> --------------------------------------------------------------
>
>                 Key: AIRAVATA-2712
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-2712
>             Project: Airavata
>          Issue Type: Improvement
>          Components: Registry API
>            Reporter: Sneha Tilak
>            Assignee: Sneha Tilak
>            Priority: Major
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to