org.alfresco.repo.usage
Class RepoUsageMonitor

java.lang.Object
  extended by org.alfresco.repo.usage.RepoUsageMonitor
All Implemented Interfaces:
RepoUsageComponent.RestrictionObserver

public class RepoUsageMonitor
extends java.lang.Object
implements RepoUsageComponent.RestrictionObserver

This component monitors the repository usages, issuing warnings and errors as necessary.

Since:
3.5

Nested Class Summary
static class RepoUsageMonitor.RepoUsageMonitorJob
          The job that kicks off the usage monitoring.
 
Constructor Summary
RepoUsageMonitor()
           
 
Method Summary
 void checkUsages()
          Performs the physical checking of usages.
 void init()
          Check that all properties are properly set
 void onChangeRestriction(RepoUsage restrictions)
          Checks the current status, logs messages and sets a read-write veto, if necessary
 void setRepoUsageComponent(RepoUsageComponent repoUsageComponent)
           
 void setScheduler(org.quartz.Scheduler scheduler)
           
 void setTransactionService(TransactionService transactionService)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RepoUsageMonitor

public RepoUsageMonitor()
Method Detail

setScheduler

public void setScheduler(org.quartz.Scheduler scheduler)
Parameters:
scheduler - Timed updates

setTransactionService

public void setTransactionService(TransactionService transactionService)
Parameters:
transactionService - service that tells if the server is read-only or not

setRepoUsageComponent

public void setRepoUsageComponent(RepoUsageComponent repoUsageComponent)
Parameters:
repoUsageComponent - provides data on usages

init

public void init()
          throws org.quartz.SchedulerException
Check that all properties are properly set

Throws:
org.quartz.SchedulerException

checkUsages

public void checkUsages()
Performs the physical checking of usages.


onChangeRestriction

public void onChangeRestriction(RepoUsage restrictions)
Checks the current status, logs messages and sets a read-write veto, if necessary

Specified by:
onChangeRestriction in interface RepoUsageComponent.RestrictionObserver
Parameters:
restrictions - the new restrictions


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.