Cleanup NormalizedNodeContext lifecycle 62/98062/2
authorRobert Varga <robert.varga@pantheon.tech>
Sat, 23 Oct 2021 09:11:21 +0000 (11:11 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Sat, 23 Oct 2021 10:11:43 +0000 (12:11 +0200)
commitd152b6b85cf24a9eb48c3a3c45c0c7c493f9c426
tree21ba01ed675afdbb482b334f5b4550bd75c03371
parentd76ff11933c5751ba3371a23e5621784920a0721
Cleanup NormalizedNodeContext lifecycle

We have headers as a non-final field with a leaking HashMap. As it turns
out, this is only used for stream listers, which can use ImmutableMap.
Cleanup constructors to express this, so we know what gets filled in.

Change-Id: I43f3b77c8c2a9640b6edbd815ce72bc3637819ba
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
restconf/restconf-common/src/main/java/org/opendaylight/restconf/common/context/NormalizedNodeContext.java
restconf/restconf-nb-bierman02/src/main/java/org/opendaylight/netconf/sal/restconf/impl/RestconfImpl.java
restconf/restconf-nb-rfc8040/src/main/java/org/opendaylight/restconf/nb/rfc8040/rests/services/impl/RestconfStreamsSubscriptionServiceImpl.java