01: /*
02: * All content copyright (c) 2003-2007 Terracotta, Inc., except as may otherwise be noted in a separate copyright
03: * notice. All rights reserved.
04: */
05: package com.tc.net.groups;
06:
07: import com.tc.logging.TCLogger;
08:
09: public class DefaultZapNodeRequestProcessor implements
10: ZapNodeRequestProcessor {
11:
12: private final TCLogger logger;
13:
14: public DefaultZapNodeRequestProcessor(TCLogger logger) {
15: this .logger = logger;
16: }
17:
18: public boolean acceptOutgoingZapNodeRequest(NodeID nodeID,
19: int type, String reason) {
20: return true;
21: }
22:
23: public void incomingZapNodeRequest(NodeID nodeID, int zapNodeType,
24: String reason, long[] weights) {
25: logger
26: .warn("DefaultZapNodeRequestProcessor : Received Zap Node request from "
27: + nodeID
28: + " type = "
29: + zapNodeType
30: + " reason = " + reason);
31: System.exit(zapNodeType);
32: }
33:
34: public long[] getCurrentNodeWeights() {
35: return new long[0];
36: }
37:
38: }
|