package com.steering.jobface.Mcms;

import com.steering.jobface.mch.CoreRtdMeasurePosDataHelper;
import com.steering.jobface.qcm.SampleHeatTreatmentToQcm;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import java.util.Timer;
import java.util.TimerTask;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;


public class McmsServlet extends HttpServlet {
    /**
     * @Fields serialVersionUID :
     */

    public void init() throws ServletException {
        try {

            new Timer().scheduleAtFixedRate(new TimerTask() {
                                                @Override
                                                public void run() {
                                                    synchronized (this) {

                                                        new CarEffServer().DoUpdateRecord();

                                                    }
                                                }
                                            }, 0,
                    100 * 1000);
        } catch (Exception e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    }



}
