yasithdev commented on code in PR #748:
URL: https://github.com/apache/airavata-custos/pull/748#discussion_r4604739982


##########
internal/db/migrations/000010_storages.up.sql:
##########
@@ -0,0 +1,53 @@
+-- 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.
+
+CREATE TABLE IF NOT EXISTS storages
+(
+    id                 VARCHAR(255)   NOT NULL,
+    compute_cluster_id VARCHAR(255)   NOT NULL,
+    type               VARCHAR(32)    NOT NULL DEFAULT '',
+    path               TEXT           NOT NULL,
+    username           VARCHAR(255)   NOT NULL DEFAULT '',
+    allocation_id      VARCHAR(255),
+    allocation_name    VARCHAR(255),
+    start_time         TIMESTAMPTZ(6),
+    end_time           TIMESTAMPTZ(6),
+    owner              VARCHAR(255)   NOT NULL,
+    "group"            VARCHAR(255)   NOT NULL,
+    mode               TEXT           NOT NULL,
+    quota_bytes        BIGINT         NOT NULL DEFAULT 0,
+    quota_inodes       BIGINT         NOT NULL DEFAULT 0,
+    quota_until        TIMESTAMPTZ(6),
+    status             VARCHAR(16)    NOT NULL DEFAULT 'active',
+    PRIMARY KEY (id),
+    CONSTRAINT chk_storages_status CHECK (status IN ('active', 
'pending_deletion')),
+    CONSTRAINT uq_storages_path UNIQUE (compute_cluster_id, path)
+);
+
+-- Moves the folders the VAST connector tracked before storages moved to core.
+DO $$ BEGIN
+IF to_regclass('vast_folders') IS NOT NULL THEN

Review Comment:
   I removed this and moved the migration to upgrade notes in a new 
CHANGELOG.md file



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to