mirror of
https://github.com/apache/activemq.git
synced 2025-02-16 23:16:52 +00:00
added size() method to return amount of disk space the store occupies on disk
git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@900420 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
27186c5ce2
commit
2e98d40065
@ -172,6 +172,17 @@ public class JobSchedulerStore extends ServiceSupport {
|
||||
public void setDirectory(File directory) {
|
||||
this.directory = directory;
|
||||
}
|
||||
|
||||
public long size() {
|
||||
if ( !isStarted() ) {
|
||||
return 0;
|
||||
}
|
||||
try {
|
||||
return journal.getDiskSize() + pageFile.getDiskSize();
|
||||
} catch (IOException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
public JobScheduler getJobScheduler(final String name) throws Exception {
|
||||
JobSchedulerImpl result = this.schedulers.get(name);
|
||||
|
Loading…
x
Reference in New Issue
Block a user