[NETCONF-1104] Turn ListenersBroker into a component Created: 31/Jul/23  Updated: 05/Oct/23  Resolved: 05/Oct/23

Status: Resolved
Project: netconf
Component/s: restconf-nb
Affects Version/s: None
Fix Version/s: 7.0.0

Type: Improvement Priority: Highest
Reporter: Robert Varga Assignee: Oleksandr Zharov
Resolution: Done Votes: 0
Labels: pt
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: Rewire restconf-nb

 Description   

ListenersBroker hosts node-local state about what notification streams have been defined. At the end of the day, it it has three distinct parts:

  • dataChangeListeners, backed by DOMDataTreeChangeService
  • notificationListeners, backed by DOMNotificationService
  • deviceNotificationListeners, backed by NETCONF mounted devices

This is a ClassLoader singleton, accessed via static ListenersBroker.getInstance() – which is completely wrong, as it should be a a normal singleton managing the contents of ietf-restconf-monitoring streams' content, with the three parts managed separately as:

  • SalRemoteImpl, which handles dataChangeListeners and notificationListeners
  • OdlDeviceNotificationImpl, which handles deviceNotificationListeners

This deals with the first part of the problem: getting rid of ListenersBroker.getInstance() and properly injecting the appropriate service into all components accessing ListenersBroker instances.


Generated at Wed Feb 07 20:16:41 UTC 2024 using Jira 8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d.