<commit_before>package istic.gla.groupb.nivimoju.init;

import istic.gla.goupb.nivimoju.drone.engine.DronePositionRefresherJob;
import org.apache.log4j.Logger;
import org.quartz.*;
import org.quartz.impl.StdSchedulerFactory;

import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;

/**
 * Created by sacapuces on 15/04/15.
 */
public class JobInit implements ServletContextListener {
    Logger logger = Logger.getLogger(JobInit.class);

    @Override
    public void contextInitialized(ServletContextEvent servletContextEvent) {
        logger.info("initializing context");
        //JobDetail job = new JobDetail();
        //job.setName("dummyJobName");
        //job.setJobClass(HelloJob.class);
        JobDetail job = JobBuilder.newJob(DronePositionRefresherJob.class)
                .withIdentity("dummyJobName", "group1").build();

        //CronTrigger trigger = new CronTrigger();
        //trigger.setName("dummyTriggerName");
        //trigger.setCronExpression("0/5 * * * * ?");

        Trigger trigger = TriggerBuilder
                .newTrigger()
                .withIdentity("dummyTriggerName", "group1")
                .withSchedule(
                        CronScheduleBuilder.cronSchedule("0/2 * * * * ?"))
                .build();

        //schedule it
        try{
            Scheduler scheduler = new StdSchedulerFactory().getScheduler();<commit_msg>passage du job de récupération des position de drones à 200ms<commit_after>package istic.gla.groupb.nivimoju.init;

import istic.gla.goupb.nivimoju.drone.engine.DronePositionRefresherJob;
import org.apache.log4j.Logger;
import org.quartz.*;
import org.quartz.impl.StdSchedulerFactory;

import javax.servlet.ServletContextEvent;
import javax.servlet.ServletContextListener;

/**
 * Initialise le job qui rafraichit les positions de drones en lisant la simulation
 */
public class JobInit implements ServletContextListener {
    Logger logger = Logger.getLogger(JobInit.class);

    @Override
    public void contextInitialized(ServletContextEvent servletContextEvent) {
        logger.info("initializing context");
        JobDetail job = JobBuilder.newJob(DronePositionRefresherJob.class)
                .withIdentity("dummyJobName", "group1").build();

        Trigger trigger = TriggerBuilder
                .newTrigger()
                .withIdentity("dummyTriggerName", "group1")
                .withSchedule(
                        SimpleScheduleBuilder.simpleSchedule()
                                .withIntervalInMilliseconds(200)
                                .repeatForever())
                .build();

        try{
            Scheduler scheduler = new StdSchedulerFactory().getScheduler();
{'fraction_non_alphanumeric': 0.10066127847171198, 'fraction_numerical': 0.008082292432035268, 'mean_word_length': 2.7506887052341598, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3526288', 'n_tokens_mistral': 770, 'n_tokens_neox': 725, 'n_words': 139}