Skip to content
This repository has been archived by the owner on Oct 1, 2020. It is now read-only.

Commit

Permalink
Removed GossipListener, Pings will no longer be sent out nor received…
Browse files Browse the repository at this point in the history
…. Connectivity is entirely based upon the metrics fetched from ict api.
  • Loading branch information
ixuz committed Mar 26, 2019
1 parent 3a4e473 commit 7873bef
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 306 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ repositories {
}

dependencies {
compile 'com.github.iotaledger:ict:20b7fbbaa7ec3b3629e5e5c1ba7478daa994d50a'
compile 'com.github.iotaledger:ict:33c4673748b829c32310ff26ee8912ea29a9636f'
compile 'com.google.code.gson:gson:2.8.5'
compile group: 'org.danilopianini', name: 'gson-extras', version: '0.2.1'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.11.1'
Expand Down
40 changes: 0 additions & 40 deletions src/main/java/com/ictreport/ixi/ReportIxiGossipListener.java

This file was deleted.

81 changes: 0 additions & 81 deletions src/main/java/com/ictreport/ixi/api/PingSender.java

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,7 @@ public class Payload {
public static String serialize(final Payload payload) {
final RuntimeTypeAdapterFactory<Payload> runtimeTypeAdapterFactory = RuntimeTypeAdapterFactory
.of(Payload.class, "type")
.registerSubtype(PingPayload.class, "PingPayload")
.registerSubtype(StatusPayload.class, "StatusPayload")
.registerSubtype(ReceivedPingPayload.class, "ReceivedPingPayload")
.registerSubtype(SubmittedPingPayload.class, "SubmittedPingPayload")
.registerSubtype(RequestUuidPayload.class, "RequestUuidPayload")
.registerSubtype(NeighborPayload.class, "NeighborPayload");

Expand All @@ -26,10 +23,7 @@ public static String serialize(final Payload payload) {
public static Payload deserialize(final String json) {
final RuntimeTypeAdapterFactory<Payload> runtimeTypeAdapterFactory = RuntimeTypeAdapterFactory
.of(Payload.class, "type")
.registerSubtype(PingPayload.class, "PingPayload")
.registerSubtype(StatusPayload.class, "StatusPayload")
.registerSubtype(ReceivedPingPayload.class, "ReceivedPingPayload")
.registerSubtype(SubmittedPingPayload.class, "SubmittedPingPayload")
.registerSubtype(RequestUuidPayload.class, "RequestUuidPayload")
.registerSubtype(NeighborPayload.class, "NeighborPayload");

Expand Down
14 changes: 0 additions & 14 deletions src/main/java/com/ictreport/ixi/exchange/payloads/PingPayload.java

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

8 changes: 0 additions & 8 deletions src/main/java/org/iota/ict/ixi/ReportIxi.java
Original file line number Diff line number Diff line change
@@ -1,21 +1,17 @@
package org.iota.ict.ixi;

import com.ictreport.ixi.ReportIxiContext;
import com.ictreport.ixi.ReportIxiGossipListener;
import com.ictreport.ixi.api.PingSender;
import com.ictreport.ixi.api.StatusSender;
import com.ictreport.ixi.configuration.Migrator;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.iota.ict.ixi.context.IxiContext;
import org.iota.ict.network.gossip.GossipListener;

public class ReportIxi extends IxiModule {

private static final Logger log = LogManager.getLogger("ReportIxi");

private final ReportIxiContext context = new ReportIxiContext();
private final GossipListener gossipListener = new ReportIxiGossipListener(this);

public ReportIxi(Ixi ixi) {
super(ixi);
Expand All @@ -38,9 +34,6 @@ public void onStart() {
log.info("Starting ReportIxi ...");

subWorkers.add(new StatusSender(this));
subWorkers.add(new PingSender(this));

getIxi().addGossipListener(gossipListener);
}

@Override
Expand All @@ -61,7 +54,6 @@ public void run() {

@Override
public void onTerminate() {
getIxi().removeGossipListener(gossipListener);
log.info("Stopped ReportIxi.");
}

Expand Down
23 changes: 0 additions & 23 deletions src/test/java/com/ictreport/ixi/exchange/PingPayloadTest.java

This file was deleted.

This file was deleted.

This file was deleted.

0 comments on commit 7873bef

Please sign in to comment.