Mercurial > hg > Database > Alice
changeset 307:52bb813ed52e
add SendPing class
author | sugi |
---|---|
date | Tue, 19 Nov 2013 15:51:52 +0900 |
parents | 098e97954c08 |
children | a8255a831ade |
files | src/alice/topology/manager/keeparive/SendPing.java |
diffstat | 1 files changed, 20 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/alice/topology/manager/keeparive/SendPing.java Tue Nov 19 15:51:52 2013 +0900 @@ -0,0 +1,20 @@ +package alice.topology.manager.keeparive; + +import alice.codesegment.CodeSegment; +import alice.datasegment.CommandType; +import alice.datasegment.Receiver; + +public class SendPing extends CodeSegment{ + private Receiver taskInfo = ids.create(CommandType.TAKE); + + public SendPing(){ + taskInfo.setKey("_SENDPING"); + } + + @Override + public void run(){ + TaskInfo info = taskInfo.asClass(TaskInfo.class); + ods.ping(info.getManagerKey()); + //new RespondPing(); + } +}