Examples of SafeTimerTask


Examples of hudson.triggers.SafeTimerTask

        schedule(interval);
    }

    private void schedule(long interval) {
        Trigger.timer.scheduleAtFixedRate(new SafeTimerTask() {
            public void doRun() {
                triggerUpdate();
            }
        }, interval, interval);
    }
View Full Code Here

Examples of hudson.triggers.SafeTimerTask

     * Schedules the next execution.
     */
    public void schedule() {
        // randomize the scheduling so that multiple Hudson instances will write at the file at different time
        long MINUTE = 1000*60;
        Trigger.timer.schedule(new SafeTimerTask() {
            protected void doRun() {
                execute();
            }
        },(random.nextInt(30)+60)*MINUTE);
    }
View Full Code Here

Examples of hudson.triggers.SafeTimerTask

        schedule(interval);
    }

    private void schedule(long interval) {
        Trigger.timer.scheduleAtFixedRate(new SafeTimerTask() {
            public void doRun() {
                triggerUpdate();
            }
        }, interval, interval);
    }
View Full Code Here

Examples of hudson.triggers.SafeTimerTask

                        controller.install(hudson);

                        // trigger the loading of changelogs in the background,
                        // but give the system 10 seconds so that the first page
                        // can be served quickly
                        Trigger.timer.schedule(new SafeTimerTask() {
                            public void doRun() {
                                User.getUnknown().getBuilds();
                            }
                        }, 1000*10);
                    } catch (Error e) {
View Full Code Here

Examples of hudson.triggers.SafeTimerTask

     * Schedules the next execution.
     */
    public void schedule() {
        // randomize the scheduling so that multiple Hudson instances will write at the file at different time
        long MINUTE = 1000*60;
        Trigger.timer.schedule(new SafeTimerTask() {
            protected void doRun() {
                execute();
            }
        },(random.nextInt(30)+60)*MINUTE);
    }
View Full Code Here

Examples of net.socialgamer.cah.SafeTimerTask

        logger.info(String.format("Resetting game %d due to too few players after someone left.",
            id));
        resetState(true);
      } else if (wasJudge) {
        synchronized (roundTimerLock) {
          final SafeTimerTask task = new SafeTimerTask() {
            @Override
            public void process() {
              startNextRound();
            }
          };
View Full Code Here

Examples of net.socialgamer.cah.SafeTimerTask

    data.put(LongPollResponse.PLAY_TIMER, playTimer);

    broadcastToPlayers(MessageType.GAME_EVENT, data);

    synchronized (roundTimerLock) {
      final SafeTimerTask task = new SafeTimerTask() {
        @Override
        public void process() {
          warnPlayersToPlay();
        }
      };
View Full Code Here

Examples of net.socialgamer.cah.SafeTimerTask

            player.getUser().enqueueMessage(q);
          }
        }
      }

      final SafeTimerTask task = new SafeTimerTask() {
        @Override
        public void process() {
          skipIdlePlayers();
        }
      };
View Full Code Here

Examples of net.socialgamer.cah.SafeTimerTask

        data.put(LongPollResponse.GAME_ID, this.id);
        final QueuedMessage q = new QueuedMessage(MessageType.GAME_EVENT, data);
        getJudge().getUser().enqueueMessage(q);
      }

      final SafeTimerTask task = new SafeTimerTask() {
        @Override
        public void process() {
          skipIdleJudge();
        }
      };
View Full Code Here

Examples of net.socialgamer.cah.SafeTimerTask

    broadcastToPlayers(MessageType.GAME_EVENT, data);

    notifyPlayerInfoChange(getJudge());

    synchronized (roundTimerLock) {
      final SafeTimerTask task = new SafeTimerTask() {
        @Override
        public void process() {
          warnJudgeToJudge();
        }
      };
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.