示例#1
0
    async def remove(self, persisted_data: bool = True) -> None:
        await self.cleanup()

        self.debug('removing port')
        _ports_by_id.pop(self._id, None)

        if persisted_data:
            self.debug('removing persisted data')
            persist.remove(self.PERSIST_COLLECTION, filt={'id': self._id})

        self.trigger_remove()
示例#2
0
def reset() -> None:
    logger.debug('clearing persisted data')
    persist.remove('webhooks')
示例#3
0
def reset() -> None:
    logger.debug('clearing device persisted data')
    persist.remove('device')
示例#4
0
def reset() -> None:
    logger.debug('clearing virtual ports persisted data')
    persist.remove('vports')
示例#5
0
def remove(port_id: str) -> None:
    _vport_settings.pop(port_id, None)
    logger.debug('removing virtual port settings for %s', port_id)
    persist.remove('vports', filt={'id': port_id})
示例#6
0
def reset() -> None:
    logger.debug('clearing persisted data')
    persist.remove('reverse')
示例#7
0
def reset() -> None:
    logger.debug('clearing slaves persisted data')
    persist.remove('slaves')
    persist.remove('slave_ports')
示例#8
0
def reset() -> None:
    logger.debug('clearing ports persisted data')
    persist.remove(BasePort.PERSIST_COLLECTION)