From 4aaa6218b853873c632aba0ed8696f29640041d1 Mon Sep 17 00:00:00 2001 From: Marcin Chrzanowski Date: Mon, 6 Jan 2020 16:55:11 +0100 Subject: Setup GossipGirl --- .../cloudatlas/agent/messages/InitiateGossipMessage.java | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java (limited to 'src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java') diff --git a/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java b/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java new file mode 100644 index 0000000..d216d59 --- /dev/null +++ b/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java @@ -0,0 +1,11 @@ +package pl.edu.mimuw.cloudatlas.agent.messages; + +import pl.edu.mimuw.cloudatlas.agent.modules.ModuleType; + +public class InitiateGossipMessage extends GossipGirlMessage { + private long nextGossipId = 0; + + public InitiateGossipMessage(String messageId, long timestamp) { + super(messageId, timestamp, Type.INITIATE); + } +} -- cgit v1.2.3 From ce76dbc406da1a8fe839b1e311ed699f9d5c7498 Mon Sep 17 00:00:00 2001 From: Marcin Chrzanowski Date: Mon, 6 Jan 2020 23:01:16 +0100 Subject: Start implementing gossip initiator path --- .../agent/messages/InitiateGossipMessage.java | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java') diff --git a/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java b/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java index d216d59..955570e 100644 --- a/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java +++ b/src/main/java/pl/edu/mimuw/cloudatlas/agent/messages/InitiateGossipMessage.java @@ -1,11 +1,24 @@ package pl.edu.mimuw.cloudatlas.agent.messages; import pl.edu.mimuw.cloudatlas.agent.modules.ModuleType; +import pl.edu.mimuw.cloudatlas.model.PathName; +import pl.edu.mimuw.cloudatlas.model.ValueContact; public class InitiateGossipMessage extends GossipGirlMessage { - private long nextGossipId = 0; + private PathName ourPath; + private ValueContact theirContact; - public InitiateGossipMessage(String messageId, long timestamp) { + public InitiateGossipMessage(String messageId, long timestamp, PathName ourPath, ValueContact theirContact) { super(messageId, timestamp, Type.INITIATE); + this.ourPath = ourPath; + this.theirContact = theirContact; + } + + public PathName getOurPath() { + return ourPath; + } + + public ValueContact getTheirContact() { + return theirContact; } } -- cgit v1.2.3