Examples of SimpleScheduler


Examples of com.pugh.sockso.music.scheduling.SimpleScheduler

public class SimpleSchedulerTest extends SocksoTestCase {

    public void testShouldRunAt() throws Exception {
        final Properties p = new StringProperties();
        final Scheduler s = new SimpleScheduler( p );
        final DateFormat df = new SimpleDateFormat( "y-M-d H:m:s" );
        p.set( "scheduler.simple.interval", 10 );
        assertTrue( s.shouldRunAt(df.parse("2009-10-10 11:00:00")) );
        assertTrue( s.shouldRunAt(df.parse("2009-10-10 11:10:00")) );
        assertTrue( s.shouldRunAt(df.parse("2009-10-10 12:00:00")) );
        assertFalse( s.shouldRunAt(df.parse("2009-10-10 12:03:00")) );
        assertFalse( s.shouldRunAt(df.parse("2009-10-10 09:31:00")) );
    }
View Full Code Here

Examples of org.apache.commons.scxml.env.SimpleScheduler

                        + " can not be parsed!");
                System.exit(-1);
            }
            System.out.println(SCXMLSerializer.serialize(doc));
            SCXMLExecutor exec = new SCXMLExecutor(evaluator, null, trc);
            EventDispatcher ed = new SimpleScheduler(exec);
            exec.setEventdispatcher(ed);
            exec.setStateMachine(doc);
            exec.addListener(doc, trc);
            exec.registerInvokerClass("scxml", SimpleSCXMLInvoker.class);
            exec.setRootContext(rootCtx);
View Full Code Here

Examples of org.apache.commons.scxml.env.SimpleScheduler

    public void testEventdata04Sample() throws InterruptedException {
        SCXML scxml = SCXMLTestHelper.parse(eventdata04);
        Tracer trc = new Tracer();
        try {
            exec = new SCXMLExecutor(new JexlEvaluator(), null, trc);
            exec.setEventdispatcher(new SimpleScheduler(exec));
            exec.addListener(scxml, trc);
            exec.setStateMachine(scxml);
            exec.go();
        } catch (Exception e) {
            fail(e.getMessage());
View Full Code Here

Examples of org.apache.commons.scxml.env.SimpleScheduler

                        + " can not be parsed!");
                System.exit(-1);
            }
            System.out.println(SCXMLSerializer.serialize(doc));
            SCXMLExecutor exec = new SCXMLExecutor(evaluator, null, trc);
            EventDispatcher ed = new SimpleScheduler(exec);
            exec.setEventdispatcher(ed);
            exec.setStateMachine(doc);
            exec.addListener(doc, trc);
            exec.registerInvokerClass("scxml", SimpleSCXMLInvoker.class);
            exec.setRootContext(rootCtx);
View Full Code Here

Examples of org.apache.commons.scxml2.env.SimpleScheduler

                        + " can not be parsed!");
                System.exit(-1);
            }
            System.out.println(SCXMLWriter.write(doc));
            SCXMLExecutor exec = new SCXMLExecutor(evaluator, null, trc);
            EventDispatcher ed = new SimpleScheduler(exec);
            exec.setEventdispatcher(ed);
            exec.setStateMachine(doc);
            exec.addListener(doc, trc);
            exec.registerInvokerClass("scxml", SimpleSCXMLInvoker.class);
            exec.setRootContext(rootCtx);
View Full Code Here

Examples of org.apache.ode.scheduler.simple.SimpleScheduler

   
    String clusterNodeName=JBossDSPFactory.getServerConfig().getClusterNodeName();
   
    __log.info("Scheduler node name: "+clusterNodeName);
   
  SimpleScheduler scheduler = new SimpleScheduler(clusterNodeName,
              _schedulerDaoCF, _txMgr, _odeConfig.getProperties());
    scheduler.setExecutorService(_executorService);
    scheduler.setTransactionManager(_txMgr);

    return scheduler;
  }
View Full Code Here

Examples of org.apache.ode.scheduler.simple.SimpleScheduler

       
        _db.shutdown();
    }

    protected Scheduler createScheduler() {
        SimpleScheduler scheduler = new SimpleScheduler(new GUID().toString(),new JdbcDelegate(_db.getDataSource()));
        scheduler.setTransactionManager(_txMgr);

        return scheduler;
    }
View Full Code Here

Examples of org.apache.ode.scheduler.simple.SimpleScheduler

            }
        }
    }

    protected Scheduler createScheduler() {
        SimpleScheduler scheduler = new SimpleScheduler(new GUID().toString(),new JdbcDelegate(_db.getDataSource()));
        scheduler.setTransactionManager(_txMgr);

        return scheduler;
    }
View Full Code Here

Examples of org.apache.ode.scheduler.simple.SimpleScheduler

            }
        }
    }

    protected Scheduler createScheduler() {
        SimpleScheduler scheduler = new SimpleScheduler(new GUID().toString(),new JdbcDelegate(_db.getDataSource()));
        scheduler.setTransactionManager(_txMgr);

        return scheduler;
    }
View Full Code Here

Examples of org.apache.ode.scheduler.simple.SimpleScheduler

    protected ProcessStoreImpl createProcessStore(DataSource ds) {
        return new ProcessStoreImpl(ds, _odeConfig.getDAOConnectionFactory(),false);
    }

    protected Scheduler createScheduler() {
        SimpleScheduler scheduler = new SimpleScheduler(new GUID().toString(), new JdbcDelegate(_db.getDataSource()));
        scheduler.setExecutorService(_executorService);
        scheduler.setTransactionManager(_txMgr);
        return scheduler;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.