changed net_cmd to host_cmd and node_net_cmd to cmd, for simpler more logical naming

This commit is contained in:
bharnden 2019-10-18 23:28:09 -07:00
parent d4af459653
commit 6006710c32
16 changed files with 74 additions and 76 deletions

View file

@ -881,7 +881,7 @@ class CoreGrpcServer(core_pb2_grpc.CoreApiServicer):
session = self.get_session(request.session_id, context)
node = self.get_node(session, request.node_id, context)
try:
output = node.node_net_cmd(request.command)
output = node.cmd(request.command)
except CoreCommandError as e:
output = e.stderr
return core_pb2.NodeCommandResponse(output=output)

View file

@ -885,7 +885,7 @@ class CoreHandler(socketserver.BaseRequestHandler):
status = e.returncode
else:
try:
res = node.node_net_cmd(command)
res = node.cmd(command)
status = 0
except CoreCommandError as e:
res = e.stderr
@ -911,7 +911,7 @@ class CoreHandler(socketserver.BaseRequestHandler):
if message.flags & MessageFlags.LOCAL.value:
utils.mute_detach(command)
else:
node.node_net_cmd(command, wait=False)
node.cmd(command, wait=False)
except CoreError:
logging.exception("error getting object: %s", node_num)
# XXX wait and queue this message to try again later