Package java.util

Examples of java.util.Timer$TimerImpl$TimerTree


    _sipFactory = (SipFactory) getServletContext().getAttribute(SipServlet.SIP_FACTORY);
    _bindings = new HashMap<String, SortedSet<Binding>>();
   
    getServletContext().setAttribute(Binding.class.getName(), _bindings);
   
    _timer = new Timer();
    _timer.scheduleAtFixedRate(new BindingScavenger(), 5000, 5000);
   
    _dateFormat = new SimpleDateFormat("EEE, d MMM yyyy HH:mm:ss z", Locale.US);
    _dateFormat.setTimeZone(TimeZone.getTimeZone("GMT"));
  }
View Full Code Here


            if (Log.isDebugEnabled())
                Log.debug("starting local scavenger thread...(period: " + getScavengerPeriod() + " secs)");
            long delay = getScavengerPeriod() * 1000;
            boolean isDaemon = true;
            _scavenger = new Timer(isDaemon);
            _scavenger.scheduleAtFixedRate(new Scavenger(), delay, delay);
            Log.debug("...local scavenger thread started");
            _started = true;
        }

View Full Code Here

    // Store LifeCycle
    public void start() throws Exception
    {
        boolean isDaemon = true;
        _scavenger = new Timer(isDaemon);
        long delay = _scavengerPeriod
                + Math.round(Math.random() * _scavengerPeriod);
        if (Log.isDebugEnabled())
          Log.debug("starting distributed scavenger thread...(period: "
                    + delay + " secs)");
View Full Code Here

    public List<Member> getMembers(){
        return this.activeMembers;
    }

    public void startApplicationMembershipTimer(){
        Timer timer = new Timer();
        timer.scheduleAtFixedRate(new MemberActivatorTask(), 1000, 500);
    }
View Full Code Here

        if (messageQueue.isPersistent()) {
            log.info("Loading the persisted messages if there are any to the message queue");
            messageQueue.load();
        }

        Timer samplingTimer = synapseEnvironment.getSynapseConfiguration().getSynapseTimer();
        messageProcessor = new MessageProcessor();
        log.info("Scheduling the sampling timer to invoke the message processor " +
                "at an interval of : " + unitTime);
        samplingTimer.schedule(messageProcessor, 0, unitTime);
    }
View Full Code Here

      long cacheRefreshDelay, String refreshThreadName, SnapshotFileInspector inspectSnapshotFiles) {
    this.fs = fs;
    this.fileInspector = inspectSnapshotFiles;
    this.snapshotDir = SnapshotDescriptionUtils.getSnapshotsDir(rootDir);
    // periodically refresh the file cache to make sure we aren't superfluously saving files.
    this.refreshTimer = new Timer(refreshThreadName, true);
    this.refreshTimer.scheduleAtFixedRate(new RefreshCacheTask(), cacheRefreshDelay,
      cacheRefreshPeriod);
  }
View Full Code Here

    /**
     * Starts timer if it is not already started
     */
    private synchronized void startTimer() {
         if (timer == null) {
            timer = new Timer();
            TimerTask task = new TimerTask() {
                public void run() {
                  try {
                    timerEvent();
                  }
View Full Code Here

    //GBeanLifeCycle
    public synchronized void doStart() throws Exception {
        load();
        if (!readOnly) {
            timer = new Timer(true);
        }
        log.debug("Started LocalAttributeManager with data on " + serverOverride.getConfigurations().size() + " configurations");
    }
View Full Code Here

            }

            synchronized (this) {
                reconfigure();

                timer = new Timer(true);

                // Periodically check the configuration file
                schedule();
            }
View Full Code Here

        this.executor = executor;
        this.transactionManager = transactionManager;
    }

    public void doStart() throws Exception {
        delegate = new Timer(true);
    }
View Full Code Here

TOP

Related Classes of java.util.Timer$TimerImpl$TimerTree

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.