BUG-650: speed up ResolveDataChangeState.needsProcessing() 13/10913/2
authorRobert Varga <rovarga@cisco.com>
Mon, 8 Sep 2014 16:32:39 +0000 (18:32 +0200)
committerRobert Varga <rovarga@cisco.com>
Mon, 8 Sep 2014 16:50:14 +0000 (18:50 +0200)
commite6dd23c2db4b883052f8d026c3f4c2074e2786bc
tree55ecd383acfe4bf595c0b66eba722153de34a993
parentbc6512b2e79a678f59fcf973275a19644b0dba5d
BUG-650: speed up ResolveDataChangeState.needsProcessing()

Checking for empty subBuilders allows us to reuse the parent's
collection. For simple cases with no listeners whis speeds up
needsProcessing() by completely reusing the emptyList and for
non-trivial cases it just omits object instantiation.

Change-Id: Ib3089bca2ec4f7e1ef826bf4192b8154ff154702
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/md-sal/sal-inmemory-datastore/src/main/java/org/opendaylight/controller/md/sal/dom/store/impl/ResolveDataChangeState.java