Package sos.util

Examples of sos.util.SOSSchedulerLogger


  private Iterator liveDirCrontabsIterator = null;

  public boolean spooler_init() throws Exception {
    File liveFolder = new File(spooler.configuration_directory());
    schedulerCronConfigurationDir = new File(liveFolder,"cron");
    logger = new SOSSchedulerLogger(spooler_log);
    monitoredLiveDir = spooler.variables().value("cron_adapter_dynamic_configuration_dir");
    if (monitoredLiveDir!=null && monitoredLiveDir.length()>0){
      spooler_log.info("parameter cron_adapter_dynamic_configuration_dir: "+monitoredLiveDir);
      monitoredLiveDirs = monitoredLiveDir.split(";");
    } else monitoredLiveDir=null;
View Full Code Here


    String database="";
    String[] operations=null;
    String[] tables=null;
    String[] attributes=null;
   
    this.setLogger(new SOSSchedulerLogger(spooler_log));
    try{
      if (getJobProperties().getProperty("config") != null) {
            connection = sos.connection.SOSConnection.createInstance(getJobProperties().getProperty("config"));
              connection.connect();
            new_connection = true;
View Full Code Here

                this.masterConnection = new SOSMySQLConnection( this.masterProperties.getProperty("driver"),
                                                                this.masterProperties.getProperty("url"),
                                                                this.masterProperties.getProperty("user"),
                                                                this.masterProperties.getProperty("password") );
            } else {
                this.masterConnection = SOSConnection.createInstance(connectionSettingsFilename, (SOSLogger) new SOSSchedulerLogger(spooler_log));
                masterProperties.setProperty("url", this.masterConnection.getUrl());
            }
            this.masterConnection.connect();
        }
        catch (Exception e) {
View Full Code Here

                slaveConnection = new SOSMySQLConnection( masterProperties.getProperty("driver"),
                                                      slaveProperties.getProperty("url"),
                                                      slaveProperties.getProperty("user"),
                                                      slaveProperties.getProperty("password") );
            } else {
                slaveConnection = SOSConnection.createInstance(connectionSettingsFilename, (SOSLogger) new SOSSchedulerLogger(spooler_log));
                slaveProperties.setProperty("url", slaveConnection.getUrl());
            }
            slaveConnection.connect();
        }
        catch (Exception e) {
View Full Code Here

  public void addObject(Object object, String name) {
    if (object instanceof Log) {
      Log log = (Log) object;    // log object of the scheduler-task
      if (jsAppender != null) {
        try {
          SOSSchedulerLogger l = new SOSSchedulerLogger(log);
          jsAppender.setSchedulerLogger( l );
        } catch (Exception e) {
          logger.error("LOG-E-0120: job scheduler log object could not set in log4j properties");
          e.printStackTrace();
        }
View Full Code Here

  public boolean spooler_process_after(boolean arg0) throws Exception {
   
    if (!arg0) return arg0;
   
    SOSConnection       conn        = null;
    SOSSchedulerLogger  log         = null;
    Variable_set        parameters  = null;
    String              host        = null;
    String              remoteDir   = null;
   
    try{
      parameters = spooler.create_variable_set();
      if(spooler_task.params() != null) parameters.merge(spooler_task.params());
      if (spooler_job.order_queue() != null)parameters.merge(spooler_task.order().params());
           
      SOSFTPHistory.debugParams(parameters, spooler_log);
           
      if(parameters != null && parameters.count() > 0){
        if (parameters.value("ftp_result_files") == "0"){
          spooler_log.debug9("no files were received");    
        }
        else{
          host      = parameters.value("ftp_host");
          remoteDir = parameters.value("ftp_remote_dir");
           
          if(host != null && host.length() > 0 && remoteDir != null && remoteDir.length() > 0){
            try{
              String[] files  = parameters.value("ftp_result_filepaths").split( ";" );
       
              log             = new SOSSchedulerLogger(spooler_log);
              conn            = SOSFTPHistory.getConnection(spooler, conn, parameters, log);
             
              for (int i=0; i<files.length; i++){
                fillPosition(conn,host,remoteDir,files[i]);
              }
View Full Code Here


   
    
     try {
     sosLogger = new SOSSchedulerLogger(spooler_log);

       this.setJobSettings(new SOSProfileSettings(spooler.ini_path()));
        this.setJobProperties(this.getJobSettings().getSection("spooler"));
        if (this.getJobProperties().isEmpty())
            throw new Exception("no settings found in section [spooler] of configuration file: " + spooler.ini_path());
View Full Code Here

     public boolean spooler_init() {
         
          try {
                sosString = new SOSString();             
              //this.getParameters();
              sosLogger = new SOSSchedulerLogger(spooler_log);                          
              return true;
             
          } catch (Exception e) {
              spooler_log.error("error occurred initializing job: " + e.getMessage());
              return false;
View Full Code Here

               
          Variable_set parameters = null;
          HashMap allParams       = null;
          JobSchedulerLoadTestLauncher launcher = null;
          try {
            sosLogger = new SOSSchedulerLogger(spooler_log);
            sosLogger.debug3(".. calling " + SOSClassUtil.getMethodName());
              parameters = spooler_task.params();
             
              if (spooler_job.order_queue() != null) {
                  parameters.merge(spooler_task.order().params());                          
View Full Code Here

     * @see sos.spooler.Monitor_impl#spooler_task_before()
     */
    public boolean spooler_task_before() {
       
        try { // to map order configuration to this job
            this.setLogger(new SOSSchedulerLogger(spooler_log));           
           
            if (spooler_task.params().value("configuration_path") != null && spooler_task.params().value("configuration_path").length() > 0)
                this.setConfigurationPath(spooler_task.params().value("configuration_path"));

            if (spooler_task.params().value("configuration_file") != null && spooler_task.params().value("configuration_file").length() > 0)
View Full Code Here

TOP

Related Classes of sos.util.SOSSchedulerLogger

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.