Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LIU-396: Add additional port options to CLI for NodeManager. #277

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions daliuge-engine/dlg/manager/cmdline.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@
ISLAND_DEFAULT_REST_PORT,
MASTER_DEFAULT_REST_PORT,
REPLAY_DEFAULT_REST_PORT,
NODE_DEFAULT_RPC_PORT,
NODE_DEFAULT_EVENTS_PORT
)
from .node_manager import NodeManager
from .replay import ReplayManager, ReplayManagerServer
Expand Down Expand Up @@ -423,6 +425,23 @@ def dlgNM(parser, args):
dest="use_processes",
help="Use processes instead of threads to execute app drops, defaults to False",
)
parser.add_option(
"--rpc_port",
action="store",
type="int",
dest="rpc_port",
help="Set the port number for the NodeManager RPC client",
default=NODE_DEFAULT_RPC_PORT
)
parser.add_option(
"--event_port",
action="store",
type="int",
dest="events_port",
help="Set the port number for the NodeManager ZMQ client",
default=NODE_DEFAULT_EVENTS_PORT
)

(options, args) = parser.parse_args(args)

# No logging setup at this point yet
Expand All @@ -445,6 +464,8 @@ def dlgNM(parser, args):
"dlm_enable_replication": options.dlm_enable_replication,
"dlgPath": options.dlgPath,
"host": options.host,
"rpc_port": options.rpc_port,
"events_port": options.events_port,
"error_listener": options.errorListener,
"event_listeners": list(
filter(None, options.event_listeners.split(":"))
Expand Down
4 changes: 2 additions & 2 deletions daliuge-engine/dlg/manager/composite_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,8 @@ def _checkDM(self):
break
if not self.check_dm(host, port, timeout=self._dmCheckTimeout):
logger.error(
"Couldn't contact manager for host %s, will try again later",
host,
"Couldn't contact manager for host %s:%d, will try again later",
host, port,
)
if self._dmCheckerEvt.wait(60):
break
Expand Down
Loading