Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members

LMConfiguration.h

Go to the documentation of this file.
00001 
00010 #ifndef EDG_WORKLOAD_COMMON_CONFIGURATION_LMCONFIGURATION_H
00011 #define EDG_WORKLOAD_COMMON_CONFIGURATION_LMCONFIGURATION_H
00012 
00013 #include "confbase.h"
00014 
00015 COMMON_NAMESPACE_BEGIN {
00016 
00017 namespace configuration {
00018 
00019 class LMConfiguration : public confbase_c {
00020 public:
00021   LMConfiguration( const classad::ClassAd *ad );
00022 
00023   ~LMConfiguration( void );
00024 
00025 
00026   inline bool remove_job_files( bool def = true ) const
00027   {
00028     return this->getBool( "RemoveJobFiles", def );
00029   }
00030 
00031   inline bool use_maradona_file( bool def = true ) const
00032   {
00033     return this->getBool( "UseMaradonaFile", def );
00034   }
00035 
00036   inline int jobs_per_condor_log( int def = 1000 ) const
00037   {
00038     return this->getInt( "JobsPerCondorLog", def );
00039   }
00040 
00041   inline int main_loop_duration( int def = 3 ) const
00042   {
00043     return this->getInt( "MainLoopDuration", def );
00044   }
00045 
00046   inline int aborted_jobs_timeout( int def = 600 ) const
00047   {
00048     return this->getInt( "AbortedJobsTimeout", def );
00049   }
00050 
00051   inline int force_cancellation_retries( int def = 10 ) const
00052   {
00053     return this->getInt( "ForceCancellationRetries", def );
00054   }
00055 
00056   inline size_t containers_compact_threshold( size_t def = 1000 ) const
00057   {
00058     return static_cast<size_t>( this->getInt( "ContainersCompactThreshold", def ) );
00059   }
00060 
00061   inline std::string condor_log_dir( const std::string &def = "" ) const
00062   {
00063     return this->getAndParseFileName( "CondorLogDir", def );
00064   }
00065 
00066   inline std::string condor_log_recycle_dir( const std::string &def = "" ) const
00067   {
00068     return this->getAndParseFileName( "CondorLogRecycleDir", def );
00069   }
00070 
00071   inline std::string external_log_file( const std::string &def = "" ) const
00072   {
00073     return this->getAndParseFileName( "ExternalLogFile", def );
00074   }
00075 
00076   inline std::string monitor_internal_dir( const std::string &def = "" ) const
00077   {
00078     return this->getAndParseFileName( "MonitorInternalDir", def );
00079   }
00080 
00081   inline std::string id_repository_name( const std::string &def = "" ) const
00082   {
00083     return this->getAndParseFileName( "IdRepositoryName", def );
00084   }
00085 
00086   inline std::string maradona_transport_protocol( const std::string &def = "gsiftp://${HOSTNAME}" ) const
00087   {
00088     return this->getAndParseString( "MaradonaTransportProtocol", def );
00089   }
00090 
00091   inline int log_level( int def = 0 ) const
00092   {
00093     return this->getInt( "LogLevel", def );
00094   }
00095 
00096   inline unsigned int log_rotation_max_file_number( unsigned int def = 5 ) const
00097   {
00098     return static_cast<unsigned int>( this->getInt( "LogRotationMaxFileNumber", def ) );
00099   }
00100 
00101   inline std::streamsize log_file_max_size( std::streamsize def = 100000000 ) const
00102   {
00103     return static_cast<std::streamsize>( this->getInt( "LogFileMaxSize", def ) );
00104   }
00105 
00106   inline std::string log_file( const std::string &def = "" ) const
00107   {
00108     return this->getAndParseFileName( "LogFile", def );
00109   }
00110 
00111   inline std::string log_rotation_base_file( const std::string &def = "[[LogFile]]" ) const
00112   {
00113     return this->getAndParseFileName( "LogRotationBaseFile", def );
00114   }
00115 
00116   inline std::string lock_file( const std::string &def = "" ) const
00117   {
00118     return this->getAndParseFileName( "LockFile", def );
00119   }
00120 
00121 };
00122 
00123 }; // configuration namespace closure
00124 
00125 } COMMON_NAMESPACE_END;
00126 
00127 #endif /* EDG_WORKLOAD_COMMON_CONFIGURATION_LMCONFIGURATION_H */
00128 
00129 // Local Variables:
00130 // mode: c++
00131 // End:

Generated on Wed Mar 1 00:37:55 2006 for COMMON API - configuration, jobid, ldif2classadi, logger, process, requestad, socket++i, task, utilities by doxygen 1.3.5