Skip to content

Commit

Permalink
added debug
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanpullano committed Apr 8, 2012
1 parent 4b6a97c commit a2340e4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions rpc/RpcClientRequest.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ public class RpcClientRequest extends Thread {
private RpcMessageReply results = null;

public final static int SOCKET_TIMEOUT = 2000;
private static final boolean DEBUG = true;

public RpcClientRequest(Collection<IPP> ippList, int opCode, ArrayList<Object> arguments) {
super("ClientRequest");
Expand Down Expand Up @@ -49,6 +50,7 @@ public void run() {
byte[] outBuf = outMsg.toByteStream();
for( IPP address : ippList ) {
//TODO: Are there cases where the example code breaks? :O
if(DEBUG) System.out.println("Sending a request to:" + address);
DatagramPacket sendPkt = new DatagramPacket(outBuf, outBuf.length, address.getIp(), address.getPort());
try {
rpcSocket.send(sendPkt);
Expand Down

0 comments on commit a2340e4

Please sign in to comment.