@Override public void setup(final RegionServerServices server) { server.getChoreService().scheduleChore( new ScheduledChore("CompactionThroughputTuner", this, tuningPeriod) { @Override protected void chore() { tune(server.getCompactionPressure()); } }); }
@Override public void setup(final RegionServerServices server) { server.getChoreService().scheduleChore( new ScheduledChore("FlushThroughputTuner", this, tuningPeriod, this.tuningPeriod) { @Override protected void chore() { tune(server.getFlushPressure()); } }); }
public void start() throws IOException { stopped = false; // TODO: This will be replaced once we have the notification bus ready. Configuration conf = rsServices.getConfiguration(); int period = conf.getInt(REFRESH_CONF_KEY, REFRESH_DEFAULT_PERIOD); refreshChore = new QuotaRefresherChore(period, this); rsServices.getChoreService().scheduleChore(refreshChore); }
public synchronized void start() throws IOException { if (!QuotaUtil.isQuotaEnabled(rsServices.getConfiguration())) { LOG.info("Quota support disabled, not starting space quota manager."); return; } if (started) { LOG.warn("RegionServerSpaceQuotaManager has already been started!"); return; } // Start the chores this.spaceQuotaRefresher = new SpaceQuotaRefresherChore(this, rsServices.getClusterConnection()); rsServices.getChoreService().scheduleChore(spaceQuotaRefresher); this.regionSizeReporter = new RegionSizeReportingChore(rsServices); rsServices.getChoreService().scheduleChore(regionSizeReporter); // Instantiate the real RegionSizeStore this.regionSizeStore = RegionSizeStoreFactory.getInstance().createStore(); started = true; }
@Override public void setup(final RegionServerServices server) { server.getChoreService().scheduleChore( new ScheduledChore("CompactionThroughputTuner", this, tuningPeriod) { @Override protected void chore() { tune(server.getCompactionPressure()); } }); }
public void start() throws IOException { stopped = false; // TODO: This will be replaced once we have the notification bus ready. Configuration conf = rsServices.getConfiguration(); int period = conf.getInt(REFRESH_CONF_KEY, REFRESH_DEFAULT_PERIOD); refreshChore = new QuotaRefresherChore(period, this); rsServices.getChoreService().scheduleChore(refreshChore); }