Commit 7a43dc08 authored by Steven Murray's avatar Steven Murray
Browse files

Removed unused maxTriesToConnect parameter from the constructor of RdbmsCatalogue

parent d148a35a
......@@ -47,19 +47,17 @@ std::unique_ptr<Catalogue> CatalogueFactory::create(
case rdbms::Login::DBTYPE_ORACLE:
{
auto c = cta::make_unique<OracleCatalogue>(log, login.username, login.password, login.database, nbConns,
nbArchiveFileListingConns, maxTriesToConnect);
nbArchiveFileListingConns);
return cta::make_unique<CatalogueRetryWrapper>(log, std::move(c), maxTriesToConnect);
}
case rdbms::Login::DBTYPE_SQLITE:
{
auto c = cta::make_unique<SqliteCatalogue>(log, login.database, nbConns, nbArchiveFileListingConns,
maxTriesToConnect);
auto c = cta::make_unique<SqliteCatalogue>(log, login.database, nbConns, nbArchiveFileListingConns);
return cta::make_unique<CatalogueRetryWrapper>(log, std::move(c), maxTriesToConnect);
}
case rdbms::Login::DBTYPE_MYSQL:
{
auto c = cta::make_unique<MysqlCatalogue>(log, login, nbConns, nbArchiveFileListingConns,
maxTriesToConnect);
auto c = cta::make_unique<MysqlCatalogue>(log, login, nbConns, nbArchiveFileListingConns);
return cta::make_unique<CatalogueRetryWrapper>(log, std::move(c), maxTriesToConnect);
}
case rdbms::Login::DBTYPE_NONE:
......
......@@ -42,16 +42,14 @@ MysqlCatalogue::MysqlCatalogue(
log::Logger &log,
const rdbms::Login &login,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect):
const uint64_t nbArchiveFileListingConns):
RdbmsCatalogue(
log,
rdbms::Login(rdbms::Login::DBTYPE_MYSQL,
login.username, login.password, login.database,
login.hostname, login.port),
nbConns,
nbArchiveFileListingConns,
maxTriesToConnect) {
nbArchiveFileListingConns) {
}
//------------------------------------------------------------------------------
......
......@@ -43,16 +43,12 @@ public:
* @param nbArchiveFileListingConns The maximum number of concurrent
* connections to the underlying relational database for the sole purpose of
* listing archive files.
* @param maxTriesToConnext The maximum number of times a single method should
* try to connect to the database in the event of LostDatabaseConnection
* exceptions being thrown.
*/
MysqlCatalogue(
log::Logger &log,
const rdbms::Login &login,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect);
const uint64_t nbArchiveFileListingConns);
/**
* Destructor.
......
......@@ -142,14 +142,12 @@ OracleCatalogue::OracleCatalogue(
const std::string &password,
const std::string &database,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect):
const uint64_t nbArchiveFileListingConns):
RdbmsCatalogue(
log,
rdbms::Login(rdbms::Login::DBTYPE_ORACLE, username, password, database, "", 0),
nbConns,
nbArchiveFileListingConns,
maxTriesToConnect) {
nbArchiveFileListingConns) {
}
//------------------------------------------------------------------------------
......
......@@ -43,9 +43,6 @@ public:
* @param nbArchiveFileListingConns The maximum number of concurrent
* connections to the underlying relational database for the sole purpose of
* listing archive files.
* @param maxTriesToConnext The maximum number of times a single method should
* try to connect to the database in the event of LostDatabaseConnection
* exceptions being thrown.
*/
OracleCatalogue(
log::Logger &log,
......@@ -53,8 +50,7 @@ public:
const std::string &password,
const std::string &database,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect = 3);
const uint64_t nbArchiveFileListingConns);
/**
* Destructor.
......
......@@ -59,12 +59,10 @@ RdbmsCatalogue::RdbmsCatalogue(
log::Logger &log,
const rdbms::Login &login,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect):
const uint64_t nbArchiveFileListingConns):
m_log(log),
m_connPool(login, nbConns),
m_archiveFileListingConnPool(login, nbArchiveFileListingConns),
m_maxTriesToConnect(maxTriesToConnect),
m_tapeCopyToPoolCache(10),
m_groupMountPolicyCache(10),
m_userMountPolicyCache(10),
......
......@@ -71,16 +71,12 @@ protected:
* @param nbArchiveFileListingConns The maximum number of concurrent
* connections to the underlying relational database for the sole purpose of
* listing archive files.
* @param maxTriesToConnext The maximum number of times a single method should
* try to connect to the database in the event of LostDatabaseConnection
* exceptions being thrown.
*/
RdbmsCatalogue(
log::Logger &log,
const rdbms::Login &login,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect);
const uint64_t nbArchiveFileListingConns);
public:
......@@ -592,12 +588,6 @@ protected:
*/
mutable rdbms::ConnPool m_archiveFileListingConnPool;
/**
* The maximum number of times a single method should try to connect to the
* database in the event of LostDatabaseConnection exceptions being thrown.
*/
uint32_t m_maxTriesToConnect;
/**
* Returns true if the specified admin user exists.
*
......
......@@ -31,7 +31,7 @@ SchemaCreatingSqliteCatalogue::SchemaCreatingSqliteCatalogue(
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect):
SqliteCatalogue(log, filename, nbConns, nbArchiveFileListingConns, maxTriesToConnect) {
SqliteCatalogue(log, filename, nbConns, nbArchiveFileListingConns) {
try {
createCatalogueSchema();
} catch(exception::Exception &ex) {
......
......@@ -42,14 +42,12 @@ SqliteCatalogue::SqliteCatalogue(
log::Logger &log,
const std::string &filename,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect):
const uint64_t nbArchiveFileListingConns):
RdbmsCatalogue(
log,
rdbms::Login(rdbms::Login::DBTYPE_SQLITE, "", "", filename, "", 0),
nbConns,
nbArchiveFileListingConns,
maxTriesToConnect) {
nbArchiveFileListingConns) {
}
//------------------------------------------------------------------------------
......
......@@ -42,16 +42,12 @@ public:
* @param nbArchiveFileListingConns The maximum number of concurrent
* connections to the underlying relational database for the sole purpose of
* listing archive files.
* @param maxTriesToConnext The maximum number of times a single method should
* try to connect to the database in the event of LostDatabaseConnection
* exceptions being thrown.
*/
SqliteCatalogue(
log::Logger &log,
const std::string &filename,
const uint64_t nbConns,
const uint64_t nbArchiveFileListingConns,
const uint32_t maxTriesToConnect);
const uint64_t nbArchiveFileListingConns);
public:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment