added cleared exception logging for booting services and fixed rest issue with loading an xml file

This commit is contained in:
Blake J. Harnden 2018-08-20 16:01:51 -07:00
parent eec7fbb213
commit 348f208d4d
2 changed files with 7 additions and 1 deletions

View file

@ -447,7 +447,11 @@ class CoreServices(object):
"""
logger.info("booting node services: %s", boot_path)
for service in boot_path:
try:
self.boot_service(node, service)
except:
logger.exception("error booting service: %s", service.name)
raise
def boot_service(self, node, service):
"""

View file

@ -171,6 +171,8 @@ def save_xml(session_id):
@app.route("/sessions/xml", methods=["POST"])
def open_xml():
session = coreemu.create_session()
session.set_state(EventTypes.CONFIGURATION_STATE)
logger.info("open xml: %s", request.files)
_, temp_path = tempfile.mkstemp()
session_file = request.files['session']