Skip to content

Commit

Permalink
Minor reformatting of debug statements in rest.py (not sending tuples)
Browse files Browse the repository at this point in the history
  • Loading branch information
pritchardn committed May 25, 2022
1 parent 9f94be5 commit 0620f5a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions daliuge-engine/dlg/manager/rest.py
Original file line number Diff line number Diff line change
Expand Up @@ -621,21 +621,21 @@ def getNMs(self):
@daliuge_aware
def startNM(self, host):
port = constants.DAEMON_DEFAULT_REST_PORT
logger.debug("Sending NM start request to %s:%s", (host, port))
logger.debug("Sending NM start request to %s:%s", host, port)
with RestClient(host=host, port=port, timeout=10) as c:
return json.loads(c._POST("/managers/node/start").read())

@daliuge_aware
def stopNM(self, host):
port = constants.DAEMON_DEFAULT_REST_PORT
logger.debug("Sending NM stop request to %s:%s", (host, port))
logger.debug("Sending NM stop request to %s:%s", host, port)
with RestClient(host=host, port=port, timeout=10) as c:
return json.loads(c._POST("/managers/node/stop").read())

@daliuge_aware
def addNM(self, host, node):
port = constants.ISLAND_DEFAULT_REST_PORT
logger.debug("Adding NM %s to DIM %s", (node, host))
logger.debug("Adding NM %s to DIM %s", node, host)
with RestClient(host=host, port=port, timeout=10, url_prefix="/api") as c:
return json.loads(
c._POST(
Expand All @@ -646,14 +646,14 @@ def addNM(self, host, node):
@daliuge_aware
def removeNM(self, host, node):
port = constants.ISLAND_DEFAULT_REST_PORT
logger.debug("Removing NM %s from DIM %s", (node, host))
logger.debug("Removing NM %s from DIM %s", node, host)
with RestClient(host=host, port=port, timeout=10, url_prefix="/api") as c:
return json.loads(c._DELETE(f"/nodes/{node}").read())

@daliuge_aware
def getNMInfo(self, host):
port = constants.DAEMON_DEFAULT_REST_PORT
logger.debug("Sending request %s:%s/managers/node", (host, port))
logger.debug("Sending request %s:%s/managers/node", host, port)
with RestClient(host=host, port=port, timeout=10) as c:
return json.loads(c._GET("/managers/node").read())

Expand Down

0 comments on commit 0620f5a

Please sign in to comment.