remove svn keywords one last time and for good (hopefully)
[sfa.git] / sfa / util / config.py
index a3fe098..cf2cca9 100644 (file)
@@ -14,9 +14,6 @@
 # Note that SFA does not access any of the PLC databases directly via
 # a mysql connection; All PLC databases are accessed via PLCAPI.
 
-### $Id$
-### $URL$
-
 import os.path
 import traceback
 
@@ -69,6 +66,9 @@ class Config:
             if not hasattr(self, 'SFA_CM_TYPE'):
                 self.SFA_COMPONENT_TYPE='pl'
 
+            if not hasattr(self, 'SFA_MAX_SLICE_RENEW'):
+                self.SFA_MAX_SLICE_RENEW=60
+
             # create the data directory if it doesnt exist
             if not os.path.isdir(self.SFA_DATA_DIR):
                 try:
@@ -98,6 +98,12 @@ class Config:
         else:
             return "pl"
 
+    def get_interface_hrn(self):
+        if (hasattr(self,'SFA_INTERFACE_HRN')):
+            return self.SFA_INTERFACE_HRN
+        else:
+            return "plc"
+
     def get_plc_dbinfo(self):
         return {
             'dbname' : self.SFA_PLC_DB_NAME,
@@ -107,6 +113,18 @@ class Config:
             'password' : self.SFA_PLC_DB_PASSWORD
             }
 
+    # TODO: find a better place to put this method
+    def get_max_aggrMgr_info(self):
+        am_apiclient_path = '/usr/local/MAXGENI_AM_APIClient'
+        if (hasattr(self,'MAXGENI_AM_APICLIENT_PATH')):
+            am_client_path = self.MAXGENI_AM_APICLIENT_PATH
+
+        am_url = 'https://geni.dragon.maxgigapop.net:8443/axis2/services/AggregateGENI'
+        if (hasattr(self,'MAXGENI_AM_URL')):
+            am_url = self.MAXGENI_AM_URL
+
+        return (am_apiclient_path,am_url)
+
     ##
     # SFA uses a PLCAPI connection to perform operations on the registry,
     # such as creating and deleting slices. This connection requires an account