Commit 1d849b96 authored by David Feliot's avatar David Feliot
Browse files

JORAM-193: new method to prepare a message without assigning a stamp.

parent b7541a11
......@@ -1007,6 +1007,18 @@ public abstract class Network implements MessageConsumer, NetworkMBean {
msg.save();
}
protected void prepareMessageWithoutStamp(Message msg) throws Exception {
short to = AgentServer.getServerDesc(msg.getTo().getTo()).getGateway();
// Allocates a new timestamp. Be careful, if the message needs to be
// routed we have to use the next destination in timestamp generation.
msg.source = AgentServer.getServerId();
msg.dest = to;
// Saves the message.
msg.save();
}
class NetworkAverageLoadTask extends AverageLoadTask {
public NetworkAverageLoadTask(Timer timer) {
start(timer);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment