Skip to content
Snippets Groups Projects
Commit 96035d56 authored by Jan David Mol's avatar Jan David Mol
Browse files

L2SS-555: Merge common initialisation code and add required properties to...

L2SS-555: Merge common initialisation code and add required properties to abstract base class already.
parent a05c16bc
No related branches found
No related tags found
1 merge request!213L2SS-555: Touch up archiver retriever
......@@ -15,6 +15,10 @@ class Retriever(ABC):
"""
The Retriever abstract class implements retrieve operations on a given DBMS
"""
def __init__(self):
self.session = self.connect_to_archiving_db()
self.ab = self.set_archiver_base()
def create_session(self, creds):
"""
......@@ -120,8 +124,8 @@ class RetrieverMySQL(Retriever):
def __init__(self, cm_name: str = 'archiving/hdbpp/confmanager01'):
self.cm_name = cm_name
self.session = self.connect_to_archiving_db()
self.ab = self.set_archiver_base()
super().__init__()
def connect_to_archiving_db(self):
"""
......@@ -216,8 +220,8 @@ class RetrieverTimescale(Retriever):
def __init__(self, cm_name: str = 'archiving/hdbppts/confmanager01'):
self.cm_name = cm_name
self.session = self.connect_to_archiving_db()
self.ab = self.set_archiver_base()
super().__init__()
def connect_to_archiving_db(self):
"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment