Commit 97026249 authored by Cedric CAFFY's avatar Cedric CAFFY
Browse files

Removed DISK_FILE_PATH from the ARCHIVE_FILE table

Adapted the unit tests + the database-dependencies on this removed column
parent 89e0f4f0
......@@ -233,7 +233,6 @@ CREATE TABLE ARCHIVE_FILE(
ARCHIVE_FILE_ID BIGINT UNSIGNED CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,
DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,
DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,
DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,
DISK_FILE_UID INT UNSIGNED CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,
DISK_FILE_GID INT UNSIGNED CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,
SIZE_IN_BYTES BIGINT UNSIGNED CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,
......@@ -249,7 +248,7 @@ CREATE TABLE ARCHIVE_FILE(
CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),
CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))
);
CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);
CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);
CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);
CREATE TABLE TAPE_FILE(
VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,
......
......@@ -259,7 +259,6 @@ CREATE TABLE ARCHIVE_FILE(
ARCHIVE_FILE_ID NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,
DISK_INSTANCE_NAME VARCHAR2(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,
DISK_FILE_ID VARCHAR2(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,
DISK_FILE_PATH VARCHAR2(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,
DISK_FILE_UID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,
DISK_FILE_GID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,
SIZE_IN_BYTES NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,
......@@ -275,7 +274,7 @@ CREATE TABLE ARCHIVE_FILE(
CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),
CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))
);
CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);
CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);
CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);
CREATE TABLE TAPE_FILE(
VID VARCHAR2(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,
......
......@@ -243,7 +243,6 @@ CREATE TABLE ARCHIVE_FILE(
ARCHIVE_FILE_ID NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,
DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,
DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,
DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,
DISK_FILE_UID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,
DISK_FILE_GID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,
SIZE_IN_BYTES NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,
......@@ -259,7 +258,7 @@ CREATE TABLE ARCHIVE_FILE(
CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),
CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))
);
CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);
CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);
CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);
CREATE TABLE TAPE_FILE(
VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,
......
......@@ -223,7 +223,6 @@ CREATE TABLE ARCHIVE_FILE(
ARCHIVE_FILE_ID INTEGER CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,
DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,
DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,
DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,
DISK_FILE_UID INTEGER CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,
DISK_FILE_GID INTEGER CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,
SIZE_IN_BYTES INTEGER CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,
......@@ -239,7 +238,7 @@ CREATE TABLE ARCHIVE_FILE(
CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),
CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))
);
CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);
CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);
CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);
CREATE TABLE TAPE_FILE(
VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,
......
......@@ -2727,7 +2727,6 @@ namespace catalogue{
" ARCHIVE_FILE_ID NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,"
" DISK_INSTANCE_NAME VARCHAR2(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,"
" DISK_FILE_ID VARCHAR2(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,"
" DISK_FILE_PATH VARCHAR2(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,"
" DISK_FILE_UID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,"
" DISK_FILE_GID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,"
" SIZE_IN_BYTES NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,"
......@@ -2743,7 +2742,7 @@ namespace catalogue{
" CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),"
" CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))"
");"
"CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);"
"CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);"
"CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);"
"CREATE TABLE TAPE_FILE("
" VID VARCHAR2(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,"
......@@ -3051,7 +3050,6 @@ namespace catalogue{
" ARCHIVE_FILE_ID BIGINT UNSIGNED CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,"
" DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,"
" DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,"
" DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,"
" DISK_FILE_UID INT UNSIGNED CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,"
" DISK_FILE_GID INT UNSIGNED CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,"
" SIZE_IN_BYTES BIGINT UNSIGNED CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,"
......@@ -3067,7 +3065,7 @@ namespace catalogue{
" CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),"
" CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))"
");"
"CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);"
"CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);"
"CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);"
"CREATE TABLE TAPE_FILE("
" VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,"
......@@ -3364,7 +3362,6 @@ namespace catalogue{
" ARCHIVE_FILE_ID INTEGER CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,"
" DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,"
" DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,"
" DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,"
" DISK_FILE_UID INTEGER CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,"
" DISK_FILE_GID INTEGER CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,"
" SIZE_IN_BYTES INTEGER CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,"
......@@ -3380,7 +3377,7 @@ namespace catalogue{
" CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),"
" CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))"
");"
"CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);"
"CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);"
"CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);"
"CREATE TABLE TAPE_FILE("
" VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,"
......@@ -3695,7 +3692,6 @@ namespace catalogue{
" ARCHIVE_FILE_ID NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_AFI_NN NOT NULL,"
" DISK_INSTANCE_NAME VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DIN_NN NOT NULL,"
" DISK_FILE_ID VARCHAR(100) CONSTRAINT ARCHIVE_FILE_DFI_NN NOT NULL,"
" DISK_FILE_PATH VARCHAR(2000) CONSTRAINT ARCHIVE_FILE_DFP_NN NOT NULL,"
" DISK_FILE_UID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFUID_NN NOT NULL,"
" DISK_FILE_GID NUMERIC(10, 0) CONSTRAINT ARCHIVE_FILE_DFGID_NN NOT NULL,"
" SIZE_IN_BYTES NUMERIC(20, 0) CONSTRAINT ARCHIVE_FILE_SIB_NN NOT NULL,"
......@@ -3711,7 +3707,7 @@ namespace catalogue{
" CONSTRAINT ARCHIVE_FILE_DIN_DFI_UN UNIQUE(DISK_INSTANCE_NAME, DISK_FILE_ID),"
" CONSTRAINT ARCHIVE_FILE_ID_BOOL_CK CHECK(IS_DELETED IN ('0', '1'))"
");"
"CREATE INDEX ARCHIVE_FILE_DIN_DFP_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME, DISK_FILE_PATH);"
"CREATE INDEX ARCHIVE_FILE_DIN_IDX ON ARCHIVE_FILE(DISK_INSTANCE_NAME);"
"CREATE INDEX ARCHIVE_FILE_DFI_IDX ON ARCHIVE_FILE(DISK_FILE_ID);"
"CREATE TABLE TAPE_FILE("
" VID VARCHAR(100) CONSTRAINT TAPE_FILE_V_NN NOT NULL,"
......
This diff is collapsed.
......@@ -374,7 +374,6 @@ void MysqlCatalogue::fileWrittenToTape(rdbms::Conn &conn, const TapeFileWritten
row.size = event.size;
row.checksumBlob = event.checksumBlob;
row.storageClassName = event.storageClassName;
row.diskFilePath = event.diskFilePath;
row.diskFileOwnerUid = event.diskFileOwnerUid;
row.diskFileGid = event.diskFileGid;
insertArchiveFile(conn, row);
......@@ -394,7 +393,7 @@ void MysqlCatalogue::fileWrittenToTape(rdbms::Conn &conn, const TapeFileWritten
std::ostringstream fileContext;
fileContext << "archiveFileId=" << event.archiveFileId << ", diskInstanceName=" << event.diskInstance <<
", diskFileId=" << event.diskFileId << ", diskFilePath=" << event.diskFilePath;
", diskFileId=" << event.diskFileId;
if(archiveFile->fileSize != event.size) {
catalogue::FileSizeMismatch ex;
......@@ -433,7 +432,6 @@ void MysqlCatalogue::deleteArchiveFile(const std::string &diskInstanceName, cons
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -478,7 +476,6 @@ void MysqlCatalogue::deleteArchiveFile(const std::string &diskInstanceName, cons
archiveFile->archiveFileID = selectRset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = selectRset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = selectRset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = selectRset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = selectRset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = selectRset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = selectRset.columnUint64("SIZE_IN_BYTES");
......@@ -522,7 +519,6 @@ void MysqlCatalogue::deleteArchiveFile(const std::string &diskInstanceName, cons
.add("diskInstance", archiveFile->diskInstance)
.add("requestDiskInstance", diskInstanceName)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......@@ -552,9 +548,7 @@ void MysqlCatalogue::deleteArchiveFile(const std::string &diskInstanceName, cons
exception::UserError ue;
ue.getMessage() << "Failed to delete archive file with ID " << archiveFileId << " because the disk instance of "
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " path=" <<
archiveFile->diskFileInfo.path << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" <<
archiveFile->diskInstance;
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" << archiveFile->diskInstance;
throw ue;
}
......@@ -590,7 +584,6 @@ void MysqlCatalogue::deleteArchiveFile(const std::string &diskInstanceName, cons
spc.add("fileId", std::to_string(archiveFile->archiveFileID))
.add("diskInstance", archiveFile->diskInstance)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......
......@@ -77,7 +77,6 @@ namespace {
rdbms::wrapper::OcciColumn archiveFileId;
rdbms::wrapper::OcciColumn diskInstance;
rdbms::wrapper::OcciColumn diskFileId;
rdbms::wrapper::OcciColumn diskFilePath;
rdbms::wrapper::OcciColumn diskFileUser;
rdbms::wrapper::OcciColumn diskFileGroup;
rdbms::wrapper::OcciColumn size;
......@@ -97,7 +96,6 @@ namespace {
archiveFileId("ARCHIVE_FILE_ID", nbRows),
diskInstance("DISK_INSTANCE_NAME", nbRows),
diskFileId("DISK_FILE_ID", nbRows),
diskFilePath("DISK_FILE_PATH", nbRows),
diskFileUser("DISK_FILE_UID", nbRows),
diskFileGroup("DISK_FILE_GID", nbRows),
size("SIZE_IN_BYTES", nbRows),
......@@ -473,7 +471,7 @@ void OracleCatalogue::filesWrittenToTape(const std::set<TapeItemWrittenPointer>
std::ostringstream fileContext;
fileContext << "archiveFileId=" << event.archiveFileId << ", diskInstanceName=" << event.diskInstance <<
", diskFileId=" << event.diskFileId << ", diskFilePath=" << event.diskFilePath;
", diskFileId=" << event.diskFileId;
// This should never happen
if(fileSizesAndChecksums.end() == fileSizeAndChecksumItor) {
......@@ -566,7 +564,6 @@ void OracleCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn, const
archiveFileBatch.archiveFileId.setFieldLenToValueLen(i, event.archiveFileId);
archiveFileBatch.diskInstance.setFieldLenToValueLen(i, event.diskInstance);
archiveFileBatch.diskFileId.setFieldLenToValueLen(i, event.diskFileId);
archiveFileBatch.diskFilePath.setFieldLenToValueLen(i, event.diskFilePath);
archiveFileBatch.diskFileUser.setFieldLenToValueLen(i, event.diskFileOwnerUid);
archiveFileBatch.diskFileGroup.setFieldLenToValueLen(i, event.diskFileGid);
archiveFileBatch.size.setFieldLenToValueLen(i, event.size);
......@@ -584,7 +581,6 @@ void OracleCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn, const
archiveFileBatch.archiveFileId.setFieldValue(i, event.archiveFileId);
archiveFileBatch.diskInstance.setFieldValue(i, event.diskInstance);
archiveFileBatch.diskFileId.setFieldValue(i, event.diskFileId);
archiveFileBatch.diskFilePath.setFieldValue(i, event.diskFilePath);
archiveFileBatch.diskFileUser.setFieldValue(i, event.diskFileOwnerUid);
archiveFileBatch.diskFileGroup.setFieldValue(i, event.diskFileGid);
archiveFileBatch.size.setFieldValue(i, event.size);
......@@ -601,7 +597,6 @@ void OracleCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn, const
"ARCHIVE_FILE_ID,"
"DISK_INSTANCE_NAME,"
"DISK_FILE_ID,"
"DISK_FILE_PATH,"
"DISK_FILE_UID,"
"DISK_FILE_GID,"
"SIZE_IN_BYTES,"
......@@ -614,7 +609,6 @@ void OracleCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn, const
":ARCHIVE_FILE_ID,"
":DISK_INSTANCE_NAME,"
":DISK_FILE_ID,"
":DISK_FILE_PATH,"
":DISK_FILE_UID,"
":DISK_FILE_GID,"
":SIZE_IN_BYTES,"
......@@ -634,7 +628,6 @@ void OracleCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn, const
occiStmt.setColumn(archiveFileBatch.archiveFileId);
occiStmt.setColumn(archiveFileBatch.diskInstance);
occiStmt.setColumn(archiveFileBatch.diskFileId);
occiStmt.setColumn(archiveFileBatch.diskFilePath);
occiStmt.setColumn(archiveFileBatch.diskFileUser);
occiStmt.setColumn(archiveFileBatch.diskFileGroup);
occiStmt.setColumn(archiveFileBatch.size);
......@@ -759,7 +752,6 @@ void OracleCatalogue::deleteArchiveFile(const std::string &diskInstanceName, con
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -808,7 +800,6 @@ void OracleCatalogue::deleteArchiveFile(const std::string &diskInstanceName, con
archiveFile->archiveFileID = selectRset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = selectRset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = selectRset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = selectRset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = selectRset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = selectRset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = selectRset.columnUint64("SIZE_IN_BYTES");
......@@ -852,7 +843,6 @@ void OracleCatalogue::deleteArchiveFile(const std::string &diskInstanceName, con
.add("diskInstance", archiveFile->diskInstance)
.add("requestDiskInstance", diskInstanceName)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......@@ -882,8 +872,7 @@ void OracleCatalogue::deleteArchiveFile(const std::string &diskInstanceName, con
exception::UserError ue;
ue.getMessage() << "Failed to delete archive file with ID " << archiveFileId << " because the disk instance of "
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " path=" <<
archiveFile->diskFileInfo.path << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" <<
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" <<
archiveFile->diskInstance;
throw ue;
}
......@@ -918,7 +907,6 @@ void OracleCatalogue::deleteArchiveFile(const std::string &diskInstanceName, con
spc.add("fileId", std::to_string(archiveFile->archiveFileID))
.add("diskInstance", archiveFile->diskInstance)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......
......@@ -75,7 +75,6 @@ namespace {
rdbms::wrapper::PostgresColumn archiveFileId;
rdbms::wrapper::PostgresColumn diskInstance;
rdbms::wrapper::PostgresColumn diskFileId;
rdbms::wrapper::PostgresColumn diskFilePath;
rdbms::wrapper::PostgresColumn diskFileUser;
rdbms::wrapper::PostgresColumn diskFileGroup;
rdbms::wrapper::PostgresColumn size;
......@@ -95,7 +94,6 @@ namespace {
archiveFileId("ARCHIVE_FILE_ID", nbRows),
diskInstance("DISK_INSTANCE_NAME", nbRows),
diskFileId("DISK_FILE_ID", nbRows),
diskFilePath("DISK_FILE_PATH", nbRows),
diskFileUser("DISK_FILE_UID", nbRows),
diskFileGroup("DISK_FILE_GID", nbRows),
size("SIZE_IN_BYTES", nbRows),
......@@ -375,7 +373,7 @@ void PostgresCatalogue::filesWrittenToTape(const std::set<TapeItemWrittenPointer
std::ostringstream fileContext;
fileContext << "archiveFileId=" << event.archiveFileId << ", diskInstanceName=" << event.diskInstance <<
", diskFileId=" << event.diskFileId << ", diskFilePath=" << event.diskFilePath;
", diskFileId=" << event.diskFileId;
// This should never happen
if(fileSizesAndChecksums.end() == fileSizeAndChecksumItor) {
......@@ -484,7 +482,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
archiveFileBatch.archiveFileId.setFieldValue(i, event.archiveFileId);
archiveFileBatch.diskInstance.setFieldValue(i, event.diskInstance);
archiveFileBatch.diskFileId.setFieldValue(i, event.diskFileId);
archiveFileBatch.diskFilePath.setFieldValue(i, event.diskFilePath);
archiveFileBatch.diskFileUser.setFieldValue(i, event.diskFileOwnerUid);
archiveFileBatch.diskFileGroup.setFieldValue(i, event.diskFileGid);
archiveFileBatch.size.setFieldValue(i, event.size);
......@@ -510,7 +507,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
"ARCHIVE_FILE_ID,"
"DISK_INSTANCE_NAME,"
"DISK_FILE_ID,"
"DISK_FILE_PATH,"
"DISK_FILE_UID,"
"DISK_FILE_GID,"
"SIZE_IN_BYTES,"
......@@ -523,7 +519,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
":ARCHIVE_FILE_ID,"
":DISK_INSTANCE_NAME,"
":DISK_FILE_ID,"
":DISK_FILE_PATH,"
":DISK_FILE_UID,"
":DISK_FILE_GID,"
":SIZE_IN_BYTES,"
......@@ -539,7 +534,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
postgresStmt.setColumn(archiveFileBatch.archiveFileId);
postgresStmt.setColumn(archiveFileBatch.diskInstance);
postgresStmt.setColumn(archiveFileBatch.diskFileId);
postgresStmt.setColumn(archiveFileBatch.diskFilePath);
postgresStmt.setColumn(archiveFileBatch.diskFileUser);
postgresStmt.setColumn(archiveFileBatch.diskFileGroup);
postgresStmt.setColumn(archiveFileBatch.size);
......@@ -556,7 +550,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
"ARCHIVE_FILE_ID,"
"DISK_INSTANCE_NAME,"
"DISK_FILE_ID,"
"DISK_FILE_PATH,"
"DISK_FILE_UID,"
"DISK_FILE_GID,"
"SIZE_IN_BYTES,"
......@@ -569,7 +562,6 @@ void PostgresCatalogue::idempotentBatchInsertArchiveFiles(rdbms::Conn &conn,
"A.ARCHIVE_FILE_ID,"
"A.DISK_INSTANCE_NAME,"
"A.DISK_FILE_ID,"
"A.DISK_FILE_PATH,"
"A.DISK_FILE_UID,"
"A.DISK_FILE_GID,"
"A.SIZE_IN_BYTES,"
......@@ -694,7 +686,6 @@ void PostgresCatalogue::deleteArchiveFile(const std::string &diskInstanceName, c
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -741,7 +732,6 @@ void PostgresCatalogue::deleteArchiveFile(const std::string &diskInstanceName, c
archiveFile->archiveFileID = selectRset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = selectRset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = selectRset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = selectRset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = selectRset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = selectRset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = selectRset.columnUint64("SIZE_IN_BYTES");
......@@ -785,7 +775,6 @@ void PostgresCatalogue::deleteArchiveFile(const std::string &diskInstanceName, c
.add("diskInstance", archiveFile->diskInstance)
.add("requestDiskInstance", diskInstanceName)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......@@ -816,8 +805,7 @@ void PostgresCatalogue::deleteArchiveFile(const std::string &diskInstanceName, c
exception::UserError ue;
ue.getMessage() << "Failed to delete archive file with ID " << archiveFileId << " because the disk instance of "
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " path=" <<
archiveFile->diskFileInfo.path << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" <<
"the request does not match that of the archived file: archiveFileId=" << archiveFileId << " requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" <<
archiveFile->diskInstance;
throw ue;
}
......@@ -853,7 +841,6 @@ void PostgresCatalogue::deleteArchiveFile(const std::string &diskInstanceName, c
spc.add("fileId", std::to_string(archiveFile->archiveFileID))
.add("diskInstance", archiveFile->diskInstance)
.add("diskFileId", archiveFile->diskFileId)
.add("diskFileInfo.path", archiveFile->diskFileInfo.path)
.add("diskFileInfo.owner_uid", archiveFile->diskFileInfo.owner_uid)
.add("diskFileInfo.gid", archiveFile->diskFileInfo.gid)
.add("fileSize", std::to_string(archiveFile->fileSize))
......
......@@ -1228,34 +1228,6 @@ bool RdbmsCatalogue::diskFileIdExists(rdbms::Conn &conn, const std::string &disk
}
}
//------------------------------------------------------------------------------
// diskFilePathExists
//------------------------------------------------------------------------------
bool RdbmsCatalogue::diskFilePathExists(rdbms::Conn &conn, const std::string &diskInstanceName,
const std::string &diskFilePath) const {
try {
const char *const sql =
"SELECT "
"DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME, "
"DISK_FILE_PATH AS DISK_FILE_PATH "
"FROM "
"ARCHIVE_FILE "
"WHERE "
"DISK_INSTANCE_NAME = :DISK_INSTANCE_NAME AND "
"DISK_FILE_PATH = :DISK_FILE_PATH";
auto stmt = conn.createStmt(sql);
stmt.bindString(":DISK_INSTANCE_NAME", diskInstanceName);
stmt.bindString(":DISK_FILE_PATH", diskFilePath);
auto rset = stmt.executeQuery();
return rset.next();
} catch(exception::UserError &) {
throw;
} catch(exception::Exception &ex) {
ex.getMessage().str(std::string(__FUNCTION__) + ": " + ex.getMessage().str());
throw;
}
}
//------------------------------------------------------------------------------
// diskFileUserExists
//------------------------------------------------------------------------------
......@@ -5811,7 +5783,6 @@ void RdbmsCatalogue::insertArchiveFile(rdbms::Conn &conn, const ArchiveFileRow &
"ARCHIVE_FILE_ID,"
"DISK_INSTANCE_NAME,"
"DISK_FILE_ID,"
"DISK_FILE_PATH,"
"DISK_FILE_UID,"
"DISK_FILE_GID,"
"SIZE_IN_BYTES,"
......@@ -5824,7 +5795,6 @@ void RdbmsCatalogue::insertArchiveFile(rdbms::Conn &conn, const ArchiveFileRow &
":ARCHIVE_FILE_ID,"
":DISK_INSTANCE_NAME,"
":DISK_FILE_ID,"
":DISK_FILE_PATH,"
":DISK_FILE_UID,"
":DISK_FILE_GID,"
":SIZE_IN_BYTES,"
......@@ -5842,7 +5812,6 @@ void RdbmsCatalogue::insertArchiveFile(rdbms::Conn &conn, const ArchiveFileRow &
stmt.bindUint64(":ARCHIVE_FILE_ID", row.archiveFileId);
stmt.bindString(":DISK_INSTANCE_NAME", row.diskInstance);
stmt.bindString(":DISK_FILE_ID", row.diskFileId);
stmt.bindString(":DISK_FILE_PATH", row.diskFilePath);
stmt.bindUint64(":DISK_FILE_UID", row.diskFileOwnerUid);
stmt.bindUint64(":DISK_FILE_GID", row.diskFileGid);
stmt.bindUint64(":SIZE_IN_BYTES", row.size);
......@@ -5907,18 +5876,6 @@ void RdbmsCatalogue::checkTapeFileSearchCriteria(const TapeFileSearchCriteria &s
}
}
if(searchCriteria.diskFilePath && !searchCriteria.diskInstance) {
throw exception::UserError(std::string("Disk file path ") + searchCriteria.diskFilePath.value() + " is ambiguous "
"without disk instance name");
}
if(searchCriteria.diskInstance && searchCriteria.diskFilePath) {
if(!diskFilePathExists(conn, searchCriteria.diskInstance.value(), searchCriteria.diskFilePath.value())) {
throw exception::UserError(std::string("Disk file path ") + searchCriteria.diskInstance.value() + "::" +
searchCriteria.diskFilePath.value() + " does not exist");
}
}
if(searchCriteria.diskFileOwnerUid && !searchCriteria.diskInstance) {
throw exception::UserError(std::string("Disk file user ") + std::to_string(searchCriteria.diskFileOwnerUid.value()) +
" is ambiguous without disk instance name");
......@@ -5987,7 +5944,6 @@ std::list<common::dataStructures::ArchiveFile> RdbmsCatalogue::getFilesForRepack
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -6034,7 +5990,6 @@ std::list<common::dataStructures::ArchiveFile> RdbmsCatalogue::getFilesForRepack
archiveFile.archiveFileID = rset.columnUint64("ARCHIVE_FILE_ID");
archiveFile.diskInstance = rset.columnString("DISK_INSTANCE_NAME");
archiveFile.diskFileId = rset.columnString("DISK_FILE_ID");
archiveFile.diskFileInfo.path = rset.columnString("DISK_FILE_PATH");
archiveFile.diskFileInfo.owner_uid = rset.columnUint64("DISK_FILE_UID");
archiveFile.diskFileInfo.gid = rset.columnUint64("DISK_FILE_GID");
archiveFile.fileSize = rset.columnUint64("SIZE_IN_BYTES");
......@@ -6111,7 +6066,6 @@ common::dataStructures::ArchiveFileSummary RdbmsCatalogue::getTapeFileSummary(
searchCriteria.archiveFileId ||
searchCriteria.diskInstance ||
searchCriteria.diskFileId ||
searchCriteria.diskFilePath ||
searchCriteria.diskFileOwnerUid ||
searchCriteria.diskFileGid ||
searchCriteria.storageClass ||
......@@ -6137,11 +6091,6 @@ common::dataStructures::ArchiveFileSummary RdbmsCatalogue::getTapeFileSummary(
sql += "ARCHIVE_FILE.DISK_FILE_ID = :DISK_FILE_ID";
addedAWhereConstraint = true;
}
if(searchCriteria.diskFilePath) {
if(addedAWhereConstraint) sql += " AND ";
sql += "ARCHIVE_FILE.DISK_FILE_PATH = :DISK_FILE_PATH";
addedAWhereConstraint = true;
}
if(searchCriteria.diskFileOwnerUid) {
if(addedAWhereConstraint) sql += " AND ";
sql += "ARCHIVE_FILE.DISK_FILE_UID = :DISK_FILE_UID";
......@@ -6183,9 +6132,6 @@ common::dataStructures::ArchiveFileSummary RdbmsCatalogue::getTapeFileSummary(
if(searchCriteria.diskFileId) {
stmt.bindString(":DISK_FILE_ID", searchCriteria.diskFileId.value());
}
if(searchCriteria.diskFilePath) {
stmt.bindString(":DISK_FILE_PATH", searchCriteria.diskFilePath.value());
}
if(searchCriteria.diskFileOwnerUid) {
stmt.bindUint64(":DISK_FILE_UID", searchCriteria.diskFileOwnerUid.value());
}
......@@ -6540,7 +6486,7 @@ common::dataStructures::RetrieveFileQueueCriteria RdbmsCatalogue::prepareToRetri
if(diskInstanceName != archiveFile->diskInstance) {
exception::UserError ue;
ue.getMessage() << "Cannot retrieve file because the disk instance of the request does not match that of the"
" archived file: archiveFileId=" << archiveFileId << " path=" << archiveFile->diskFileInfo.path <<
" archived file: archiveFileId=" << archiveFileId <<
" requestDiskInstance=" << diskInstanceName << " archiveFileDiskInstance=" << archiveFile->diskInstance;
throw ue;
}
......@@ -6565,7 +6511,7 @@ common::dataStructures::RetrieveFileQueueCriteria RdbmsCatalogue::prepareToRetri
} else {
exception::UserError ue;
ue.getMessage() << "Cannot retrieve file because there are no mount rules for the requester or their group:" <<
" archiveFileId=" << archiveFileId << " path=" << archiveFile->diskFileInfo.path << " requester=" <<
" archiveFileId=" << archiveFileId << " requester=" <<
diskInstanceName << ":" << user.name << ":" << user.group;
throw ue;
}
......@@ -6944,7 +6890,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -6982,7 +6927,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
archiveFile->archiveFileID = rset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = rset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = rset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = rset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = rset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = rset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = rset.columnUint64("SIZE_IN_BYTES");
......@@ -7032,7 +6976,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -7073,7 +7016,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
archiveFile->archiveFileID = rset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = rset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = rset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = rset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = rset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = rset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = rset.columnUint64("SIZE_IN_BYTES");
......@@ -7177,7 +7119,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -7217,7 +7158,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
archiveFile->archiveFileID = rset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = rset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = rset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = rset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = rset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = rset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = rset.columnUint64("SIZE_IN_BYTES");
......@@ -7269,7 +7209,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
"ARCHIVE_FILE.ARCHIVE_FILE_ID AS ARCHIVE_FILE_ID,"
"ARCHIVE_FILE.DISK_INSTANCE_NAME AS DISK_INSTANCE_NAME,"
"ARCHIVE_FILE.DISK_FILE_ID AS DISK_FILE_ID,"
"ARCHIVE_FILE.DISK_FILE_PATH AS DISK_FILE_PATH,"
"ARCHIVE_FILE.DISK_FILE_UID AS DISK_FILE_UID,"
"ARCHIVE_FILE.DISK_FILE_GID AS DISK_FILE_GID,"
"ARCHIVE_FILE.SIZE_IN_BYTES AS SIZE_IN_BYTES,"
......@@ -7312,7 +7251,6 @@ std::unique_ptr<common::dataStructures::ArchiveFile> RdbmsCatalogue::getArchiveF
archiveFile->archiveFileID = rset.columnUint64("ARCHIVE_FILE_ID");
archiveFile->diskInstance = rset.columnString("DISK_INSTANCE_NAME");
archiveFile->diskFileId = rset.columnString("DISK_FILE_ID");
archiveFile->diskFileInfo.path = rset.columnString("DISK_FILE_PATH");
archiveFile->diskFileInfo.owner_uid = rset.columnUint64("DISK_FILE_UID");
archiveFile->diskFileInfo.gid = rset.columnUint64("DISK_FILE_GID");
archiveFile->fileSize = rset.columnUint64("SIZE_IN_BYTES");
......@@ -7450,7 +7388,6 @@ void RdbmsCatalogue::checkTapeFileWrittenFieldsAreSet(const std::string &calling
try {
if(event.diskInstance.empty()) throw exception::Exception("diskInstance is an empty string");
if(event.diskFileId.empty()) throw exception::Exception("diskFileId is an empty string");
if(event.diskFilePath.empty()) throw exception::Exception("diskFilePath is an empty string");
if(0 == event.diskFileOwnerUid) throw exception::Exception("diskFileOwnerUid is 0");
if(0 == event.diskFileGid) throw exception::Exception("diskFileGid is 0");
if(0 == event.size) throw exception::Exception("size is 0");
......
......@@ -891,18 +891,6 @@ protected:
*/
bool diskFileIdExists(rdbms::Conn &conn, const std::string &diskInstanceName, const std::string &diskFileId) const;
/**
* Returns true if the specified disk file path exists.
*
* @param conn The database connection.
* @param diskInstanceName The name of the disk instance to which the disk