This commit is contained in:
grossmj committed 2018-08-25 14:10:47 +07:00
1 parent ad9b6f42bf
commit 902de3dd47
12 files changed
+57 -42

No files matched your search

+3 -2
View File
@@ -27,7 +27,7 @@ from operator import itemgetter
from ..utils import parse_version
from ..utils.images import list_images
from ..utils.asyncio import locked_coroutine, asyncio_ensure_future
from ..utils.asyncio import locking, asyncio_ensure_future
from ..controller.controller_error import ControllerError
from ..version import __version__, __version_info__
@@ -400,7 +400,8 @@ class Compute:
except aiohttp.web.HTTPConflict:
pass
@locked_coroutine
@locking
@asyncio.coroutine
def connect(self):
"""
Check if remote server is accessible
+7 -4
View File
@@ -21,7 +21,7 @@ import asyncio
import aiohttp
import ipaddress
from ...utils.asyncio import locked_coroutine, asyncio_ensure_future
from ...utils.asyncio import locking, asyncio_ensure_future
from .vmware_gns3_vm import VMwareGNS3VM
from .virtualbox_gns3_vm import VirtualBoxGNS3VM
from .remote_gns3_vm import RemoteGNS3VM
@@ -265,7 +265,8 @@ class GNS3VM:
except GNS3VMError as e:
log.warn(str(e))
@locked_coroutine
@locking
@asyncio.coroutine
def start(self):
"""
Start the GNS3 VM
@@ -339,7 +340,8 @@ class GNS3VM:
except aiohttp.web.HTTPConflict as e:
log.warning("Could not check the VM is in the same subnet as the local server: {}".format(e.text))
@locked_coroutine
@locking
@asyncio.coroutine
def _suspend(self):
"""
Suspend the GNS3 VM
@@ -351,7 +353,8 @@ class GNS3VM:
log.info("Suspend the GNS3 VM")
yield from engine.suspend()
@locked_coroutine
@locking
@asyncio.coroutine
def _stop(self):
"""
Stop the GNS3 VM
+5 -3
View File
@@ -36,7 +36,7 @@ from .udp_link import UDPLink
from ..config import Config
from ..utils.path import check_path_allowed, get_default_project_directory
from ..utils.asyncio.pool import Pool
from ..utils.asyncio import locked_coroutine
from ..utils.asyncio import locking
from ..utils.asyncio import wait_run_in_executor
from ..utils.asyncio import asyncio_ensure_future
from .export_project import export_project
@@ -525,7 +525,8 @@ class Project:
self.dump()
return node
@locked_coroutine
@locking
@asyncio.coroutine
def __delete_node_links(self, node):
"""
Delete all link connected to this node.
@@ -783,7 +784,8 @@ class Project:
def _topology_file(self):
return os.path.join(self.path, self._filename)
@locked_coroutine
@locking
@asyncio.coroutine
def open(self):
"""
Load topology elements