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

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

machristie commented on a change in pull request #169: [AIRAVATA-2659] 
GroupResourceProfile for modeling resource sharing with specific groups of users
URL: https://github.com/apache/airavata/pull/169#discussion_r168321543
 
 

 ##########
 File path: modules/registry-refactoring/src/main/resources/appcatalog-mysql.sql
 ##########
 @@ -568,6 +568,85 @@ CREATE TABLE USER_COMPUTE_RESOURCE_PREFERENCE (
   PRIMARY KEY (RESOURCE_ID,USER_ID,GATEWAY_ID)
 ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
 
+CREATE TABLE GROUP_RESOURCE_PROFILE (
+  GATEWAY_ID varchar(255) NOT NULL,
+  GROUP_RESOURCE_PROFILE_ID varchar(255) NOT NULL,
+  GROUP_RESOURCE_PROFILE_NAME varchar(255) DEFAULT NULL,
+  CREATION_TIME BIGINT NOT NULL,
+  UPDATE_TIME BIGINT NOT NULL,
+  PRIMARY KEY (GATEWAY_ID,GROUP_RESOURCE_PROFILE_ID)
+)ENGINE=InnoDB DEFAULT CHARSET=latin1;
+
+CREATE TABLE BATCH_QUEUE_RESOURCE_POLICY (
+  RESOURCE_POLICY_ID varchar(255) NOT NULL,
+  COMPUTE_RESOURCE_ID varchar(255) NOT NULL,
+  GROUP_RESOURCE_PROFILE_ID varchar(255) NOT NULL,
+  GATEWAY_ID varchar(255) NOT NULL,
+  QUEUE_NAME varchar(255) NOT NULL,
+  MAX_ALLOWED_NODES INTEGER,
+  MAX_ALLOWED_CORES INTEGER,
+  MAX_ALLOWED_WALLTIME INTEGER,
+  PRIMARY KEY 
(RESOURCE_POLICY_ID,COMPUTE_RESOURCE_ID,GROUP_RESOURCE_PROFILE_ID,GATEWAY_ID,QUEUE_NAME),
+  FOREIGN KEY (COMPUTE_RESOURCE_ID,QUEUE_NAME) REFERENCES 
BATCH_QUEUE(COMPUTE_RESOURCE_ID,QUEUE_NAME) ON DELETE CASCADE,
+  FOREIGN KEY (GATEWAY_ID,GROUP_RESOURCE_PROFILE_ID) REFERENCES 
GROUP_RESOURCE_PROFILE(GATEWAY_ID,GROUP_RESOURCE_PROFILE_ID) ON DELETE CASCADE
+)ENGINE=InnoDB DEFAULT CHARSET=latin1;
+
+CREATE TABLE COMPUTE_RESOURCE_POLICY (
+    RESOURCE_POLICY_ID varchar(255) NOT NULL,
 
 Review comment:
   Can you make the PK just the RESOURCE_POLICY_ID column?

----------------------------------------------------------------
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


> GroupResourceProfile for modeling resource sharing with specific groups of 
> users
> --------------------------------------------------------------------------------
>
>                 Key: AIRAVATA-2659
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-2659
>             Project: Airavata
>          Issue Type: Improvement
>            Reporter: Sachin Kariyattin
>            Assignee: Sachin Kariyattin
>            Priority: Major
>
> The first step in implementing the Group Resource Profile backend is to 
> create the required models and add methods to store the details in the 
> registry. The GroupResourceProfile implementation will be added to the 
> app_catalog and the following changes have been made as part of it.
>  * Created the following thrift models for the GroupResourceProfile
> {{       struct GroupResourceProfile}}
>  {{       struct GroupComputeResourcePreference}}
>  {{       struct ComputeResourcePolicy}}
>  {{       struct BatchQueueResourcePolicy}}
>  * Created new tables in the app_catalog schema.
>  * Implemented GroupResourceProfileRepository.
>  * Added GroupResourceProfileRepositoryTest.
>  
>  



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

Reply via email to