Package org.rhq.core.domain.operation

Examples of org.rhq.core.domain.operation.ResourceOperationScheduleEntity


        trigger.setGroup(jobDetail.getGroup());
        trigger.setJobName(jobDetail.getName());
        trigger.setJobGroup(jobDetail.getGroup());

        // We need to create our own schedule tracking entity.
        ResourceOperationScheduleEntity schedule;
        schedule = new ResourceOperationScheduleEntity(jobDetail.getName(), jobDetail.getGroup(),
            trigger.getStartTime(), resource);
        entityManager.persist(schedule);

        // Add the id of the entity bean, so we can easily map the Quartz job to the associated entity bean.
        jobDataMap.put(OperationJob.DATAMAP_INT_ENTITY_ID, String.valueOf(schedule.getId()));

        // Create an IN_PROGRESS item
        // - we need a copy of parameters to avoid constraint violations upon delete
        ResourceOperationHistory history;
        history = new ResourceOperationHistory(uniqueJobId, jobGroupName, subject.getName(), opDef,
            (parameters == null ? null : parameters.deepCopy(false)), schedule.getResource(), null);

        updateOperationHistory(subject, history);

        // Now actually schedule it.
        Date next = scheduler.scheduleJob(jobDetail, trigger);
View Full Code Here

TOP

Related Classes of org.rhq.core.domain.operation.ResourceOperationScheduleEntity

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.