Skip to content
Snippets Groups Projects
Commit 2c76b442 authored by Steven Murray's avatar Steven Murray
Browse files

Added skeleton implementations of the MiddleTierUser method signatures to MockSchedulerDatabase

parent 9cdaf1da
No related branches found
No related tags found
No related merge requests found
......@@ -25,6 +25,7 @@
#include "scheduler/DirIterator.hpp"
#include "scheduler/LogicalLibrary.hpp"
#include "scheduler/MockSchedulerDatabase.hpp"
#include "scheduler/RetrievalJob.hpp"
#include "scheduler/SecurityIdentity.hpp"
#include "scheduler/SqliteColumnNameToIndex.hpp"
#include "scheduler/StorageClass.hpp"
......@@ -173,6 +174,81 @@ cta::MockSchedulerDatabase::~MockSchedulerDatabase() throw() {
sqlite3_close(m_dbHandle);
}
//------------------------------------------------------------------------------
// queue
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::queue(const ArchiveToDirRequest &rqst) {
}
//------------------------------------------------------------------------------
// queue
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::queue(const ArchiveToFileRequest &rqst) {
}
//------------------------------------------------------------------------------
// getArchivalJobs
//------------------------------------------------------------------------------
std::map<cta::TapePool, std::list<cta::ArchivalJob> >
cta::MockSchedulerDatabase::getArchivalJobs(const SecurityIdentity &requester)
const {
return std::map<TapePool, std::list<ArchivalJob> >();
}
//------------------------------------------------------------------------------
// getArchivalJobs
//------------------------------------------------------------------------------
std::list<cta::ArchivalJob> cta::MockSchedulerDatabase::getArchivalJobs(
const SecurityIdentity &requester,
const std::string &tapePoolName) const {
return std::list<ArchivalJob>();
}
//------------------------------------------------------------------------------
// deleteArchivalJob
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::deleteArchivalJob(
const SecurityIdentity &requester,
const std::string &dstPath) {
}
//------------------------------------------------------------------------------
// queue
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::queue(RetrieveToDirRequest &rqst) {
}
//------------------------------------------------------------------------------
// queue
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::queue(RetrieveToFileRequest &rqst) {
}
//------------------------------------------------------------------------------
// getRetrievalJobs
//------------------------------------------------------------------------------
std::map<cta::Tape, std::list<cta::RetrievalJob> > cta::MockSchedulerDatabase::
getRetrievalJobs(const SecurityIdentity &requester) const {
return std::map<Tape, std::list<RetrievalJob> >();
}
//------------------------------------------------------------------------------
// getRetrievalJobs
//------------------------------------------------------------------------------
std::list<cta::RetrievalJob> cta::MockSchedulerDatabase::getRetrievalJobs(
const SecurityIdentity &requester,
const std::string &vid) const {
return std::list<RetrievalJob>();
}
//------------------------------------------------------------------------------
// deleteRetrievalJob
//------------------------------------------------------------------------------
void cta::MockSchedulerDatabase::deleteRetrievalJob(
const SecurityIdentity &requester,
const std::string &dstUrl) {
}
//------------------------------------------------------------------------------
// createAdminUser
//------------------------------------------------------------------------------
......
......@@ -40,6 +40,105 @@ public:
*/
~MockSchedulerDatabase() throw();
/**
* Queues the specified request.
*
* @param rqst The request to be queued.
*/
void queue(const ArchiveToDirRequest &rqst);
/**
* Queues the specified request.
*
* @param rqst The request to be queued.
*/
void queue(const ArchiveToFileRequest &rqst);
/**
* Returns all of the existing archival jobs grouped by tape pool and then
* sorted by creation time in ascending order (oldest first).
*
* @param requester The identity of the user requesting the list.
* @return All of the existing archival jobs grouped by tape pool and then
* sorted by creation time in ascending order (oldest first).
*/
std::map<TapePool, std::list<ArchivalJob> > getArchivalJobs(
const SecurityIdentity &requester) const;
/**
* Returns the list of archival jobs associated with the specified tape pool
* sorted by creation time in ascending order (oldest first).
*
* @param requester The identity of the user requesting the list.
* @param tapePoolName The name of the tape pool.
* @return The list of archival jobs associated with the specified tape pool
* sorted by creation time in ascending order (oldest first).
*/
std::list<ArchivalJob> getArchivalJobs(
const SecurityIdentity &requester,
const std::string &tapePoolName) const;
/**
* Deletes the specified archival job.
*
* @param requester The identity of the user requesting the deletion of the
* tape.
* @param dstPath The absolute path of the destination file within the
* archive namespace.
*/
void deleteArchivalJob(
const SecurityIdentity &requester,
const std::string &dstPath);
/**
* Queues the specified request.
*
* @param rqst The request to be queued.
*/
void queue(RetrieveToDirRequest &rqst);
/**
* Queues the specified request.
*
* @param rqst The request to be queued.
*/
void queue(RetrieveToFileRequest &rqst);
/**
* Returns all of the existing retrieval jobs grouped by tape and then
* sorted by creation time in ascending order (oldest first).
*
* @param requester The identity of the user requesting the list.
* @return All of the existing retrieval jobs grouped by tape and then
* sorted by creation time in ascending order (oldest first).
*/
std::map<Tape, std::list<RetrievalJob> > getRetrievalJobs(
const SecurityIdentity &requester) const;
/**
* Returns the list of retrieval jobs associated with the specified tape
* sorted by creation time in ascending order (oldest first).
*
* @param requester The identity of the user requesting the list.
* @param vid The volume identifier of the tape.
* @return The list of retrieval jobs associated with the specified tape
* sorted by creation time in ascending order (oldest first).
*/
std::list<RetrievalJob> getRetrievalJobs(
const SecurityIdentity &requester,
const std::string &vid) const;
/**
* Deletes the specified retrieval job.
*
* @param requester The identity of the user requesting the deletion of the
* tape.
* @param dstUrl The URL of the destination file or directory.
*/
void deleteRetrievalJob(
const SecurityIdentity &requester,
const std::string &dstUrl);
/**
* Creates the specified administrator.
*
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment