Skip to content

Commit

Permalink
add ability to turn on routing on command line commands
Browse files Browse the repository at this point in the history
  • Loading branch information
mdavis95 committed May 12, 2022
1 parent 1136a71 commit a73ba61
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ public class ConnectionInfo {
@CommandLine.Option(names = "--port", description = "Zulia Port")
public Integer port = 32191;

@CommandLine.Option(names = "--routing", description = "Use smart routing to route request to the correct node (do not use with ssh port forwarding)")
public boolean routingEnabled;

public ZuliaWorkPool getConnection() throws Exception {
ZuliaPoolConfig config = new ZuliaPoolConfig().addNode(address, port).setRoutingEnabled(false);
ZuliaPoolConfig config = new ZuliaPoolConfig().addNode(address, port).setRoutingEnabled(routingEnabled);
return new ZuliaWorkPool(config);
}

Expand Down

0 comments on commit a73ba61

Please sign in to comment.