pekko-sample-cluster-java/src/main/java/sample/cluster/stats/App.java [52:80]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
        return Behaviors.empty();
      });
    }
  }

  public static void main(String[] args) {
    if (args.length == 0) {
      startup("compute", 17356);
      startup("compute", 17357);
      startup("compute", 0);
      startup("client", 0);
    } else {
      if (args.length != 2)
        throw new IllegalArgumentException("Usage: role port");
      startup(args[0], Integer.parseInt(args[1]));
    }
  }

  private static void startup(String role, int port) {

      // Override the configuration of the port
      Map<String, Object> overrides = new HashMap<>();
      overrides.put("org.apache.pekko.remote.artery.canonical.port", port);
      overrides.put("org.apache.pekko.cluster.roles", Collections.singletonList(role));

      Config config = ConfigFactory.parseMap(overrides)
          .withFallback(ConfigFactory.load("stats"));

      ActorSystem<Void> system = ActorSystem.create(RootBehavior.create(), "ClusterSystem", config);
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



pekko-sample-cluster-java/src/main/java/sample/cluster/stats/AppOneMaster.java [67:95]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
        return Behaviors.empty();
      });
    }
  }

  public static void main(String[] args) {
    if (args.length == 0) {
      startup("compute", 17356);
      startup("compute", 17357);
      startup("compute", 0);
      startup("client", 0);
    } else {
      if (args.length != 2)
        throw new IllegalArgumentException("Usage: role port");
      startup(args[0], Integer.parseInt(args[1]));
    }
  }

  private static void startup(String role, int port) {

    // Override the configuration of the port
    Map<String, Object> overrides = new HashMap<>();
    overrides.put("org.apache.pekko.remote.artery.canonical.port", port);
    overrides.put("org.apache.pekko.cluster.roles", Collections.singletonList(role));

    Config config = ConfigFactory.parseMap(overrides)
        .withFallback(ConfigFactory.load("stats"));

    ActorSystem<Void> system = ActorSystem.create(RootBehavior.create(), "ClusterSystem", config);
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



