comparison src/org/dancres/blitz/notify/CleanTask.java @ 0:3dc0c5604566

Initial checkin of blitz 2.0 fcs - no installer yet.
author Dan Creswell <dan.creswell@gmail.com>
date Sat, 21 Mar 2009 11:00:06 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:3dc0c5604566
1 package org.dancres.blitz.notify;
2
3 import java.io.IOException;
4
5 import java.util.logging.*;
6
7 import org.dancres.blitz.task.Task;
8
9 import org.dancres.blitz.disk.DiskTxn;
10
11 import org.dancres.blitz.oid.OID;
12
13 /**
14 If SendTask determines that a particular client and it's associated
15 notify() registration are no longer useful (due to particular exceptions
16 being received from the client), an instance of this task will be scheduled
17 to do the cleanup.
18 */
19 class CleanTask implements Task {
20 private OID theId;
21
22 CleanTask(OID anId) {
23 theId = anId;
24 }
25
26 public void run() {
27 try {
28 EventGeneratorFactory.get().killTemplate(theId);
29 } catch (IOException anIOE) {
30 RemoteEventDispatcher.theLogger.log(Level.SEVERE,
31 "Failed to clean dead lease",
32 anIOE);
33 }
34 }
35 }