Skip to content

Commit

Permalink
xlate/openconfig: disable cache for openconfig-telemetry
Browse files Browse the repository at this point in the history
This change disables caching for openconfig-telemetry to avoid a
deadlock with the telemetry server.
  • Loading branch information
noguchiko committed Nov 16, 2022
1 parent 0574679 commit 74430a2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
from .interfaces import InterfacesObjectTree
from .platform import PlatformObjectTree
from .terminal_device import TerminalDeviceObjectTree
from .telemetry import TelemetryObjectTree
from goldstone.lib.errors import Error as ConnectorError
from goldstone.lib.connector.sysrepo import Connector

Expand Down Expand Up @@ -39,7 +38,6 @@ def __init__(
"openconfig-terminal-device": TerminalDeviceObjectTree(
self._operational_modes
),
"openconfig-telemetry": TelemetryObjectTree(),
}
for _, object_tree in self._object_trees.items():
for data in object_tree.required_data():
Expand Down
3 changes: 2 additions & 1 deletion src/xlate/openconfig/goldstone/xlate/openconfig/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,8 @@ async def _main(cache, operational_modes):
ifserver = InterfaceServer(conn, cache)
pfserver = PlatformServer(conn, cache, operational_modes)
tdserver = TerminalDeviceServer(conn, cache, operational_modes)
tlserver = TelemetryServer(conn, cache)
# NOTE: Disable caching for the openconfig-telemetry to avoid a deadlock with the telemetry server.
tlserver = TelemetryServer(conn, None)
servers = [ifserver, pfserver, tdserver, tlserver]
if cache is not None:
cacheupdater = CacheUpdater(cache, operational_modes)
Expand Down

0 comments on commit 74430a2

Please sign in to comment.