Examples of SchedulerService


Examples of org.cishell.app.service.scheduler.SchedulerService

        this.conversionRegistration = bundleContext.registerService(
          DataConversionService.class.getName(),
          conversionService,
          new Hashtable<String, Object>());
       
        SchedulerService scheduler = new SchedulerServiceImpl();
        this.schedulerRegistration = bundleContext.registerService(
          SchedulerService.class.getName(), scheduler, new Hashtable<String, Object>());

        DataManagerService dataManager = new DataManagerServiceImpl();
        this.dataManagerRegistration = bundleContext.registerService(
View Full Code Here

Examples of org.cishell.app.service.scheduler.SchedulerService

       
        dmReg.open();
        eventReg.open();
        schedulerReg.open();
       
        SchedulerService scheduler = (SchedulerService) schedulerReg.getService();
        scheduler.addSchedulerListener(this);
    }
View Full Code Here

Examples of org.cishell.app.service.scheduler.SchedulerService

    /**
     * @see org.cishell.remoting.service.framework.AlgorithmRegistry#execute(String, String)
     */
    public void execute(String sessionID, String algorithmID) {
        SchedulerService scheduler = (SchedulerService) schedulerReg.getService();
       
        WrapperAlgorithm alg = new WrapperAlgorithm(getAlgorithm(algorithmID),
                sessionID, algorithmID);
       
        scheduler.runNow(alg, null);
    }
View Full Code Here

Examples of org.cishell.app.service.scheduler.SchedulerService

    return context;
  }
 
  protected static SchedulerService getSchedulerService() {
    ServiceReference serviceReference = context.getServiceReference(SchedulerService.class.getName());
    SchedulerService manager = null;
   
    if (serviceReference != null) {
      manager = (SchedulerService) context.getService(serviceReference);
    }
   
View Full Code Here

Examples of org.cishell.app.service.scheduler.SchedulerService

              this.bundleContext,
              this.ciShellContext,
              this.originalData,
              this.data,
              this.converters);
            SchedulerService scheduler = (SchedulerService) getService(SchedulerService.class);
           
            scheduler.schedule(algorithm, uniqueServiceReference);
        } catch (Throwable exception) {
          // Just in case an uncaught exception occurs. Eclipse will swallow errors thrown here.
            exception.printStackTrace();
        }
    }
View Full Code Here

Examples of org.drools.time.SchedulerService

        UuidJobHandle jobhandle = new UuidJobHandle();
        // Get the Service Configuration from the Data field
        SchedulerServiceConfiguration conf = (SchedulerServiceConfiguration) schedulerGsd.getData();
        // If the GSD doesn't have conf and it doesn't have addresses, we can use the local SchedulerService
        if ( conf == null && schedulerGsd.getAddresses().get( "socket" ) == null ) {
            SchedulerService sched = null;
            try {
                // We use the ID that contains the type of the service that we are using -> refactor this and include serviceType in GSD
                sched = grid.get( (Class<SchedulerService>) Class.forName( schedulerGsd.getServiceInterface().getCanonicalName() ) );
            } catch ( ClassNotFoundException ex ) {
                Logger.getLogger( SchedulerClient.class.getName() ).log( Level.SEVERE,
                                                                         null,
                                                                         ex );
            }
            return sched.scheduleJob( job,
                                      ctx,
                                      trigger );
        }
        // If we have a service configuration
        int redundancy = 1;
View Full Code Here

Examples of org.drools.time.SchedulerService

    public int getPort() {
        return port;
    }

    public void configureService(Grid grid) {
        SchedulerService sched = grid.get( SchedulerService.class );

        if ( port != -1 ) {
            CoreServicesLookupImpl coreServicesWP = (CoreServicesLookupImpl) grid.get( CoreServicesLookup.class );

            GridServiceDescriptionImpl gsd = (GridServiceDescriptionImpl) coreServicesWP.lookup( SchedulerService.class );
View Full Code Here

Examples of org.drools.time.SchedulerService

        UuidJobHandle jobhandle = new UuidJobHandle();
        // Get the Service Configuration from the Data field
        SchedulerServiceConfiguration conf = (SchedulerServiceConfiguration) schedulerGsd.getData();
        // If the GSD doesn't have conf and it doesn't have addresses, we can use the local SchedulerService
        if ( conf == null && schedulerGsd.getAddresses().get( "socket" ) == null ) {
            SchedulerService sched = null;
            try {
                // We use the ID that contains the type of the service that we are using -> refactor this and include serviceType in GSD
                sched = grid.get( (Class<SchedulerService>) Class.forName( schedulerGsd.getServiceInterface().getCanonicalName() ) );
            } catch ( ClassNotFoundException ex ) {
                Logger.getLogger( SchedulerClient.class.getName() ).log( Level.SEVERE,
                                                                         null,
                                                                         ex );
            }
            return sched.scheduleJob( job,
                                      ctx,
                                      trigger );
        }
        // If we have a service configuration
        int redundancy = 1;
View Full Code Here

Examples of org.drools.time.SchedulerService

        UuidJobHandle jobhandle = new UuidJobHandle();
        // Get the Service Configuration from the Data field
        SchedulerServiceConfiguration conf = (SchedulerServiceConfiguration) schedulerGsd.getData();
        // If the GSD doesn't have conf and it doesn't have addresses, we can use the local SchedulerService
        if ( conf == null && schedulerGsd.getAddresses().get( "socket" ) == null ) {
            SchedulerService sched = null;
            try {
                // We use the ID that contains the type of the service that we are using -> refactor this and include serviceType in GSD
                sched = grid.get( (Class<SchedulerService>) Class.forName( schedulerGsd.getServiceInterface().getCanonicalName() ) );
            } catch ( ClassNotFoundException ex ) {
                Logger.getLogger( SchedulerClient.class.getName() ).log( Level.SEVERE,
                                                                         null,
                                                                         ex );
            }
            return sched.scheduleJob( job,
                                      ctx,
                                      trigger );
        }
        // If we have a service configuration
        int redundancy = 1;
View Full Code Here

Examples of org.drools.time.SchedulerService

    public int getPort() {
        return port;
    }

    public void configureService(Grid grid) {
        SchedulerService sched = grid.get( SchedulerService.class );

        if ( port != -1 ) {
            CoreServicesLookupImpl coreServicesWP = (CoreServicesLookupImpl) grid.get( CoreServicesLookup.class );

            GridServiceDescriptionImpl gsd = (GridServiceDescriptionImpl) coreServicesWP.lookup( SchedulerService.class );
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.