mdsal.git
4 years agoFix Builder javadoc mis-reference 81/84181/2
Robert Varga [Tue, 3 Sep 2019 19:24:17 +0000 (21:24 +0200)]
Fix Builder javadoc mis-reference

Builders should reference target type in their documentation.

Change-Id: I3ba9c31c77be9d86bc4e2d854360b6f8cf0fb86b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoChange mapping of uint{8,16,32,64} 55/83955/25
Robert Varga [Mon, 2 Sep 2019 08:34:32 +0000 (10:34 +0200)]
Change mapping of uint{8,16,32,64}

This changes the mapping of uint types to non-widening yang.common
classes and deals with them being used by yang.{data,model}.api:

YANG type  Old Java type         New Java Type
uint8      java.lang.Short       org.opendaylight.yangtools.yang.common.Uint8
uint16     java.lang.Integer     org.opendaylight.yangtools.yang.common.Uint16
uint32     java.lang.Long        org.opendaylight.yangtools.yang.common.Uint32
uint64     java.math.BigInteger  org.opendaylight.yangtools.yang.common.Uint64

This affects all getters, setters and value wrapper classes. For
setters, code generator emits a deprecated setter, which performs
the conversion internally.

JIRA: MDSAL-330
JIRA: YANGTOOLS-1018
Change-Id: Ic3913adc4a5d707b01671a982c58221cb028f6d9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd a workaround for ARIES-1923 48/84148/1
Robert Varga [Mon, 2 Sep 2019 20:58:28 +0000 (22:58 +0200)]
Add a workaround for ARIES-1923

proxy-impl does not have an Opcodes.ASM7-compatible release, hence
it fails when it encounters JEP-181 nestmates.

As an interim solution, force mdsal-binding-api to target Java 10,
which does not have JEP-181.

Change-Id: I727082c7bc32e905ca4c23f8a35963bc69986f58
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove BindingMapping lookup 34/84134/1
Robert Varga [Mon, 2 Sep 2019 15:57:36 +0000 (17:57 +0200)]
Improve BindingMapping lookup

Expose the fact that JAVA_RESERVED_WORDS is an ImmutableSet,
allowing callers to better bind to it.

Change-Id: I8131aa8d2be9a2b8b1e13f7c5d6231b9ccb5fd2d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove BaseYangTypes lookups 32/84132/2
Robert Varga [Mon, 2 Sep 2019 15:42:40 +0000 (17:42 +0200)]
Improve BaseYangTypes lookups

Update constant definition to be bound to ImmutableSet, so that
JIT has an easier time optimizing these lookups.

Change-Id: I7becd988d46f84972ef0c573ff5efeadcba2cc62
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove TimerValue builder lookups 29/84129/1
Robert Varga [Mon, 2 Sep 2019 15:13:02 +0000 (17:13 +0200)]
Improve TimerValue builder lookups

The constant is an ImmutableMap, make that explicit, so lookups
can binding directly to it.

Change-Id: Ia4026c5dc10c6e7dcb2e8c2f99709d97e3876e84
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd a dependency on blueprint annotations 23/84123/2
Robert Varga [Mon, 2 Sep 2019 12:55:20 +0000 (14:55 +0200)]
Add a dependency on blueprint annotations

We are using these and docs is complaining about not being able
to find the classes. Fix that up.

Change-Id: Ibbab75fb1226ff50dbca43e74711dafeb0c40789
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove sun.reflect meddling 97/84097/1
Robert Varga [Fri, 30 Aug 2019 15:11:48 +0000 (17:11 +0200)]
Remove sun.reflect meddling

It seems the issue has been somehow resolved, let's remove the
configuration.

Change-Id: Iee9baeb947c142c5749d5a8ab794fc3871990c56
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove ietf-restconf 88/84088/3
Robert Varga [Fri, 30 Aug 2019 08:24:40 +0000 (10:24 +0200)]
Remove ietf-restconf

This model has been superseded by RFC8040 and there the only
downstream user (netconf.git) is hosting the new version. This
model will live in the restconf projeect until it is needed.

Change-Id: I521d5f720a19c4885df5e8ba3483e6c1af7dbc0b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFixup leaf caching test in face of lazy leaf nodes 94/84094/2
Robert Varga [Fri, 30 Aug 2019 11:18:02 +0000 (13:18 +0200)]
Fixup leaf caching test in face of lazy leaf nodes

In case we are doing lazy leaves, we end up not retaining them
and hence the test needs to do something different.

Change-Id: I68fded3a799d3c6c023eaa63336b7002ea4594c7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove use of YangInstanceIdentifier.EMPTY 47/84047/3
Robert Varga [Wed, 28 Aug 2019 19:22:36 +0000 (21:22 +0200)]
Remove use of YangInstanceIdentifier.EMPTY

This constant is deprecated, migrate users to empty().

Change-Id: I8e71f90fb458f1155a0f4fb52ba40595b8e9e6bf
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd @ConstructorParameters to generated classes 40/84040/3
Robert Varga [Wed, 28 Aug 2019 15:09:12 +0000 (17:09 +0200)]
Add @ConstructorParameters to generated classes

This allows generated classes to be used with both java.beans
and javax.management even either of java.desktop or java.management
module is missing.

JIRA: MDSAL-468
Change-Id: I9903558102d094efeb60201673980685e2b5a253
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoExpose service group name from ServiceGroupIdentifier 41/84041/2
Robert Varga [Wed, 28 Aug 2019 15:34:08 +0000 (17:34 +0200)]
Expose service group name from ServiceGroupIdentifier

AbstractIdentifier has removed public view of getValue(), hence
we need to expose a domain-specific accessor. This patch does that
and fixes up users.

Change-Id: I1645e86e5417e0a8c13660f8820a9df8b4c7cad7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoSwitch to using VarHandles 48/81848/26
Robert Varga [Wed, 1 May 2019 12:23:15 +0000 (14:23 +0200)]
Switch to using VarHandles

VarHandles allow us to relax the memory ordering when accessing
cached CodecDataObject fields. Use them instead of
AtomicReferenceFieldUpdaters.

Change-Id: If95e4e058491cee4babfcbb49bb7cf47e62f9444
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize BindingSchemaContextUtils.findDataNodeContainer() 90/83690/5
Robert Varga [Fri, 16 Aug 2019 11:27:00 +0000 (13:27 +0200)]
Optimize BindingSchemaContextUtils.findDataNodeContainer()

The method is performing duplicate instanceof check, refactor it
to to performing only one such check.

Change-Id: I64ba25f4c35dcc5aeaf81e1200ce50a971566973
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize BindingNormalizedNodeCodecRegistry representation checks 06/83706/4
Robert Varga [Fri, 16 Aug 2019 13:40:24 +0000 (15:40 +0200)]
Optimize BindingNormalizedNodeCodecRegistry representation checks

isBindingRepresentable() is a hot method, which performs a few
type checks. This patch folds those checks into a single return,
inverting the logic (which is negated anyway at the sole caller).
This cuts the amount of byte code to half, thus aiding inlining.

Futhermore we take advantage of ValueNode covering two cases we
explicitly test for, reducing the number of checks performed.

Finally we reorder the checks to improve their efficiency by
tackling most-common constructs first.

Change-Id: I556d1098a9d7dd043b2f8d756c2388f339f6b8ec
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize IdentifiableItemCodec a bit 64/83964/7
Robert Varga [Mon, 26 Aug 2019 08:47:59 +0000 (10:47 +0200)]
Optimize IdentifiableItemCodec a bit

Do not force instantiation of the backing map, as for single-item
NodeIdentifierWithPredicates it is just wasteful.

Change-Id: I0cc13d0afe2f3329f4757e9da414500de132acf6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoTake advantage of singleton NodeIdentifierWithPredicates 11/84011/1
Robert Varga [Tue, 27 Aug 2019 11:09:43 +0000 (13:09 +0200)]
Take advantage of singleton NodeIdentifierWithPredicates

NodeIdentifierWithPredicates now includes an efficient single-entry
implementation, which is rendering instantiation through
SharedSingletonMap superfluous. Take advantage of this new
constructor.

Change-Id: I9c724ceeef829ac5dc0cfded38410ab417ed4d47
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove BindingCodec and BindingSerializer 68/83968/2
Robert Varga [Mon, 26 Aug 2019 09:38:38 +0000 (11:38 +0200)]
Remove BindingCodec and BindingSerializer

These interfaces are not used anywhere, remove them.

Change-Id: I7b302cd4f0e397cbe99f2fc1b3d85103ccd47739
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMass-migrate binding-dom-codec to IllegalArgumentCodec 65/83965/4
Robert Varga [Mon, 26 Aug 2019 08:51:52 +0000 (10:51 +0200)]
Mass-migrate binding-dom-codec to IllegalArgumentCodec

This new interface most closely resembles the old intent behind
concepts.Codec, except it does not quite match nullness guaratees.

JIRA: YANGTOOLS-1017
Change-Id: I7675743ac29834ffa4b15fa70b62d1a3dad2d18b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake IdentifiableItemCodec an IllegalArgumentCodec 63/83963/3
Robert Varga [Mon, 26 Aug 2019 08:43:25 +0000 (10:43 +0200)]
Make IdentifiableItemCodec an IllegalArgumentCodec

The interface contract matches the expectations, hence we can
cleanly apply the pattern.

JIRA: YANGTOOLS-1017
Change-Id: I7b0efcfa0981646071c3715daa691559f923c285
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake IdentityCodec an AbstractIllegalArgumentCodec 62/83962/3
Robert Varga [Mon, 26 Aug 2019 08:30:35 +0000 (10:30 +0200)]
Make IdentityCodec an AbstractIllegalArgumentCodec

The behaviour is pretty much the same, except for throwing IAE
on nulls -- this is made consistent to throw a NPE.

JIRA: YANGTOOLS-1017
Change-Id: I23fea88b2c32336400ab1120949507c7442d8076
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMove Binding codec interfaces 60/83960/3
Robert Varga [Mon, 26 Aug 2019 07:14:49 +0000 (09:14 +0200)]
Move Binding codec interfaces

This moves codec interfaces from yang-binding to binding-dom-codec,
as they are an implementation detail and should never have been
exposed here.

Change-Id: I90a24527d60398ea428eff12f4359501865d3b36
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoGuard generator lookup against nulls 54/83954/1
Robert Varga [Sat, 24 Aug 2019 08:46:16 +0000 (10:46 +0200)]
Guard generator lookup against nulls

If we encounter an unsupported type we can end up throwing a NPE
without any details. This hardens the lookup to verify we have
a hit, and report the type if we have a miss.

Change-Id: I89cb988d8705772065d12b4074775ad9bc538499
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd missing yanglib docs references 94/83894/1
Robert Varga [Thu, 22 Aug 2019 11:48:08 +0000 (13:48 +0200)]
Add missing yanglib docs references

Reactor build order is showing that we are not documenting
these in mdsal-docs. Fix that.

Change-Id: I649f35d75249f61fb5dd92cd0d2fe56761da336d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd missing RFC8542 docs dependency 92/83892/1
Robert Varga [Thu, 22 Aug 2019 11:42:54 +0000 (13:42 +0200)]
Add missing RFC8542 docs dependency

Reactor build order is showing that we have forgotten this
little dependency.

JIRA: MDSAL-431
Change-Id: I2ceb49ba08521c6a2162aacb7e7ecac78f005432
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unneeded checkstyle/spotbugs declarations 89/83889/2
Robert Varga [Thu, 22 Aug 2019 11:05:03 +0000 (13:05 +0200)]
Remove unneeded checkstyle/spotbugs declarations

odlparent is forcing enforcement of both, there is no point
in us repeating the declarations.

Change-Id: I0896e446ab587cb9d5b5b746bae030d58497cf71
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDisable SpotBugs on select artifacts 88/83888/2
Robert Varga [Thu, 22 Aug 2019 11:13:15 +0000 (13:13 +0200)]
Disable SpotBugs on select artifacts

This marks specific artifacts to disable SpotBugs, as these are now
enforced by default.

Change-Id: I2e76979bddaec7c6db9f9460493f2c9f42d8e34f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix checkstyle 91/83891/1
Robert Varga [Thu, 22 Aug 2019 11:22:40 +0000 (13:22 +0200)]
Fix checkstyle

Enabled-by-default checkstyle is finding violations, fix them up.

Change-Id: I77933154813faecc87fd494caa5c51f96a56c0d1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd RFC8542 models 85/83785/4
Robert Varga [Tue, 20 Aug 2019 08:54:25 +0000 (10:54 +0200)]
Add RFC8542 models

This adds the two models present in RFC8542.

JIRA: MDSAL-431
Change-Id: I4745703bf3de0338922da2568ef9c0530348fa05
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove the ability to return mutable lists 06/82306/7
Robert Varga [Wed, 29 May 2019 12:07:21 +0000 (14:07 +0200)]
Remove the ability to return mutable lists

This patch removes the legacy opt-in to return mutable lists instead
of immutable ones.

JIRA: MDSAL-446
Change-Id: I73c09e036f8c3f92d27e6706ef4133da2c4232a2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake wrapped class equals() final 66/83766/2
Robert Varga [Mon, 19 Aug 2019 14:21:51 +0000 (16:21 +0200)]
Make wrapped class equals() final

This forbids overriding equals() for wrapper classes, meaning
the first class in hierarchy defines the proper equality
contract, which cannot be overridden.

This means that all objects within that hierarchy are considered
equal if they have the same representation (i.e. fields).

JIRA: MDSAL-440
Change-Id: I0c90ad9553071be8a8fc1109b663fe631b5599b9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump to yangtools-4.0.0-SNAPSHOT 81/83381/8
Robert Varga [Mon, 5 Aug 2019 09:04:46 +0000 (11:04 +0200)]
Bump to yangtools-4.0.0-SNAPSHOT

For some of the integration work we'll need a preview of yangtools,
switch to using their snapshots.

Change-Id: I46914e83b96d47353f1512b63e42b51383600e02
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump to odlparent-6.0.0-SNAPSHOT 80/83380/13
Robert Varga [Mon, 5 Aug 2019 09:01:48 +0000 (11:01 +0200)]
Bump to odlparent-6.0.0-SNAPSHOT

We will need settings from upstream to enable JDK11-specific work,
use odlparent snapshots for now.

Change-Id: If8f9d1118f0441a6b9df89745f2eef8d14c5e78c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoSwitch mutable lists into an opt-in 05/82305/7
Robert Varga [Wed, 29 May 2019 12:04:25 +0000 (14:04 +0200)]
Switch mutable lists into an opt-in

This changes the default handling of lists the codec uses, when

org.opendaylight.mdsal.binding.dom.codec.impl.compat-mutable-lists

property is not set. The default is now to use immutable lists
unless the property is explicitly set to "true".

JIRA: MDSAL-446
Change-Id: Ie996be8098b44d109ede9fe78511ad9746cc8e78
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix mergeable if-the-else statements 05/83705/3
Robert Varga [Fri, 16 Aug 2019 13:32:11 +0000 (15:32 +0200)]
Fix mergeable if-the-else statements

This fixes DTOs to use simple return expressions. While we are in
the area, also optimize toString() methods to lower their footprint.

Change-Id: Ie206c2942c5fb9b6cbbdc2a31d197560559fd660
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDo not emit empty lists to NormalizedNodes 58/82558/7
Robert Varga [Tue, 18 Jun 2019 19:26:20 +0000 (21:26 +0200)]
Do not emit empty lists to NormalizedNodes

This patch changes the representation of empty Binding lists in
DOM world. Empty lists are equivalent to being non-present, hence
they are not emitted.

This mirrors the getFoo()/nonnullFoo() accessor duality, i.e. empty
lists can be instantiated on-demand as placeholders for nulls.

In DOM world, list nodes are virtual containers, which do not hold
any semantics and are created on demand -- hence it does not make
sense to pass them down to DOM.

This does not create data tree operation changes, as lists are not
directly addressable, hence their WRITE/MERGE semantics are shared
by their parent. Empty merges have not semantic value, as empty
lists disappear on touch. Empty writes end up correctly observing
lifecycle -- empty lists end up disappearing, just as they would
be expected if they have undergone a lifecycle event (such as an
empty merge).

JIRA: MDSAL-456
Change-Id: I78efc4aa4c3b4100ff52490fefe94e2f65f43efc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove YangSyntaxErrorException throws 94/83694/2
Robert Varga [Fri, 16 Aug 2019 11:49:23 +0000 (13:49 +0200)]
Remove YangSyntaxErrorException throws

YangSyntaxErrorException is a subclass of YangParserException, hence
there is no need to declare it separately, as pointed out by Sonar.

Change-Id: I22b72d1e79b283db7d77b9cc720c3b80054cd03d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix string duplication in Ipv6Utils 92/83692/1
Robert Varga [Fri, 16 Aug 2019 11:40:52 +0000 (13:40 +0200)]
Fix string duplication in Ipv6Utils

This is minor code smell, create a method to concentrate common
functionality.

Change-Id: I32fb6c5c29a099885413cf18361e53098593054e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix runtime builder string duplication 91/83691/1
Robert Varga [Fri, 16 Aug 2019 11:36:16 +0000 (13:36 +0200)]
Fix runtime builder string duplication

This is a minor code smell, concentrate exception allocation to
get rid of it.

Change-Id: I3343b5dd844e4796cd781ef478412dd40e980152
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove trailing comments 89/83689/1
Robert Varga [Fri, 16 Aug 2019 11:20:53 +0000 (13:20 +0200)]
Remove trailing comments

This fixes up minor code smells reported by sonar.

Change-Id: Ic7abd5e431f2fc5e91ebc251d5a1e65d3c26c2bc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRestructure LengthGenerator.createExpressions() 66/83666/3
Robert Varga [Thu, 15 Aug 2019 11:36:49 +0000 (13:36 +0200)]
Restructure LengthGenerator.createExpressions()

SpotBugs is warning about INT_VACUOUS_COMPARISON at the head
of the 'min <= Integer.MAX_VALUE' comparison. This restructures
the logic to eliminate this check.

Change-Id: Ie465bb16443d9912a12a8b2f712851a24d339d78
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAlign CodecDataObject augmentations toString() 71/82571/3
Robert Varga [Wed, 19 Jun 2019 14:18:49 +0000 (16:18 +0200)]
Align CodecDataObject augmentations toString()

Compile-time generated codecs are using only values() from
augmentation in their toString() method. Make sure
AugmentableCodecDataObjects are following the same pattern.

Change-Id: I876dd3f2e8b6e42685198c9e1d4304592da87334
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd ow2 as provided 22/83622/7
Robert Varga [Wed, 14 Aug 2019 12:12:32 +0000 (14:12 +0200)]
Add ow2 as provided

This adds ow2.asm as provided to javadocs, and defang bytebuddy's
references to sun.reflect.

Change-Id: I576f3c4eaaf2a0fe4af8aef44b7b0b7712dfebc6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDo not include byte-buddy META-INF in shade 76/83676/1
Robert Varga [Thu, 15 Aug 2019 12:23:33 +0000 (14:23 +0200)]
Do not include byte-buddy META-INF in shade

We do not want to leak module-info.class from byte-buddy, hence
filter all of its META-INF, as it does not provide anything of
value.

Change-Id: Ie74968147f281f58c5692affcfe6e087d7b3650f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoEliminate 'txt' temporary 65/83665/1
Robert Varga [Thu, 15 Aug 2019 11:29:15 +0000 (13:29 +0200)]
Eliminate 'txt' temporary

This variable is not really needed and the way it is used SpotBugs
reports a (valid) dead local store. Eliminate the variable completely.

Change-Id: I4fec53be80a54bedfc7481063bf507c9f10990a8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix use of StringTokenizer methods 64/83664/2
Robert Varga [Thu, 15 Aug 2019 11:21:56 +0000 (13:21 +0200)]
Fix use of StringTokenizer methods

Rather than using Enumeration-related methods (*Element()), use
the methods provided by StringTokenizer (*Token()), which have
the same functionality, but are not down-casted to Object.

Change-Id: I5c0c258db8e70cafef058d628c20bf9cbeb26cb0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake AlphabeticallyTypeMemberComparator Serializable 62/83662/2
Robert Varga [Thu, 15 Aug 2019 11:07:20 +0000 (13:07 +0200)]
Make AlphabeticallyTypeMemberComparator Serializable

Comparators are recommended to be serializable, this fulfills
the need.

Change-Id: Id038ff9fb96c54ecee7cef22b881396d8302590f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix SpotBugs complaing around locale 61/83661/2
Robert Varga [Thu, 15 Aug 2019 11:05:50 +0000 (13:05 +0200)]
Fix SpotBugs complaing around locale

We are using english locale, which should work across the platform.

Change-Id: I552d4212d976c5034b76fb27bce887014b5edb9e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix InterfaceTemplate documentation 60/83660/1
Robert Varga [Thu, 15 Aug 2019 11:04:26 +0000 (13:04 +0200)]
Fix InterfaceTemplate documentation

InterfaceTemplate will fail to instantiate with a NPE if a null
type is ever passed in. Fix documentation and remove dead code.

Change-Id: Ief395cbf0d4d417e8041de39feee1e50d09157e0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBindingReflections.getQName() should return nonnull 80/83280/4
Robert Varga [Fri, 26 Jul 2019 13:28:38 +0000 (15:28 +0200)]
BindingReflections.getQName() should return nonnull

It is a hard error if we cannot find the QName corresponding to
an BaseIdentity subclass. Fix getQName() to guarantee a non-null
return, throwing ISE if we should ever not find the QName.

Change-Id: I551499a8daec87e74669ba93177ad0e795367eae
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoOptimize whitespace replacement 90/83490/7
Robert Varga [Tue, 6 Aug 2019 15:27:33 +0000 (17:27 +0200)]
Optimize whitespace replacement

Rather than doing two replacements, use a single two-character
matcher and a single replacement pass. While we're in the area,
also create a SPACE constant and use it where we mean ' ' as a
char (not a string).

Change-Id: I30d7c16074fe172a834ecf1bb0fe30a18fdc6bac
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDo not lose newlines/tabs from javadoc 29/83429/7
Robert Varga [Tue, 6 Aug 2019 14:24:44 +0000 (16:24 +0200)]
Do not lose newlines/tabs from javadoc

When we are formatting javadoc for a accessor method, we must treat
any newlines/tabs as whitespace and not lose them, otherwise we would
end up with concatenated words.

JIRA: MDSAL-416
Change-Id: I3c0fc296692a141d6787a5cba8b17738a108274e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse bulk-close for internal registrations 26/83626/1
Robert Varga [Wed, 14 Aug 2019 14:49:59 +0000 (16:49 +0200)]
Use bulk-close for internal registrations

Rather than using wrapped registrations through the public API,
we really want to first remove all modules and then update the
context (if needed).

JIRA: MDSAL-466
Change-Id: Ib281fff7264b3dd11b222095f8286087cb488002
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDisable updates when we are stopping 93/83493/4
Robert Varga [Tue, 6 Aug 2019 17:48:05 +0000 (19:48 +0200)]
Disable updates when we are stopping

We should not be propagating bundle updates when we know we are
stopping. This patch marks that knowledge in the tracker.

JIRA: MDSAL-466
Change-Id: Ie4e8b96907a8909150b4080000888d1d10ce8e54
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix curly braces 26/83426/3
Robert Varga [Tue, 6 Aug 2019 12:24:20 +0000 (14:24 +0200)]
Fix curly braces

These anonymous classes should be properly spelled out, as should
private constructors.

Change-Id: I314c92660703e68019da0562172ce3e9519ce882
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix checkstyle in javadocs 23/83423/4
Robert Varga [Tue, 6 Aug 2019 11:29:45 +0000 (13:29 +0200)]
Fix checkstyle in javadocs

Updated checkstyle is catching more violations, fix them up.

Change-Id: I1048fea86966113184fe49fe707d6d0d328c3508
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix bad javadoc license headers 92/83392/5
Robert Varga [Mon, 5 Aug 2019 14:20:31 +0000 (16:20 +0200)]
Fix bad javadoc license headers

License headers should not be javadocs, fix that up.

Change-Id: I6496008bfa2e8d227de8bb2aab0b2888c3ffed83
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoReduce use of java.lang constructors 25/83425/3
Robert Varga [Tue, 6 Aug 2019 12:12:19 +0000 (14:12 +0200)]
Reduce use of java.lang constructors

Long/Integer constructors have been deprecated, reduce their use.

Change-Id: I2ce4e63904694d3fe442622b85d831253b4a87fb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFixup cast in BindingReflections 24/83424/3
Robert Varga [Tue, 6 Aug 2019 11:37:54 +0000 (13:37 +0200)]
Fixup cast in BindingReflections

Use an explicit typed Class instead of raw class.

Change-Id: I613d81fc3162ee3bea4955aa2afacf728e2cfab6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump odlparent to 5.0.2-SNAPSHOT 60/83560/1
Robert Varga [Mon, 12 Aug 2019 21:32:25 +0000 (23:32 +0200)]
Bump odlparent to 5.0.2-SNAPSHOT

This bump is needed to get javadoc plugin to work with JDK11.

Change-Id: I2e94611c95e4741a374d2944afb5087e82a58bdf
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse refcounting to lower the number of registrations 96/83296/2
Robert Varga [Mon, 29 Jul 2019 11:09:13 +0000 (13:09 +0200)]
Use refcounting to lower the number of registrations

The fix for MDSAL-461 has introduced multiple registrations for
each YangModuleInfo, which while correct ends up parsing the same
sources multiple times.

This patch updates the handling to guard against that possibility
by adding an explicit reference counting layer, so that each
instance of YangModuleInfo is registered exactly once.

Change-Id: Id925391241cd36a26bfa05cd28f8b747d5d7ba24
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove javassist-based code 57/83357/2
Robert Varga [Thu, 1 Aug 2019 12:52:09 +0000 (14:52 +0200)]
Remove javassist-based code

This removes deprecated use of javassist.

Change-Id: Ia5686ce24052222cadb7465e66916b0db5b05ff3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions for mdsal-5.0.0 56/83356/1
Robert Varga [Thu, 1 Aug 2019 12:34:39 +0000 (14:34 +0200)]
Bump versions for mdsal-5.0.0

This starts the next major version development.

Change-Id: I5b0de45da268a68d89eb2973b276a0a2d43dfbdc
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 4.0.4-SNAPSHOT 98/83298/1
Robert Varga [Mon, 29 Jul 2019 11:12:07 +0000 (13:12 +0200)]
Bump versions to 4.0.4-SNAPSHOT

This starts the next development iteration.

Change-Id: I168f77460463cc5a50521f60bdf79a1e802c0f4a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 3.0.4 97/83297/1
Robert Varga [Mon, 29 Jul 2019 11:11:34 +0000 (13:11 +0200)]
Bump yangtools to 3.0.4

We have validated yangtools-3.0.4, bump to the release version.

Change-Id: Ib56bb6b87e8fd8609d86b310a74fde7f491449c3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove YangModuleInfo when it is unregistered 71/83071/12
Robert Varga [Tue, 23 Jul 2019 13:47:22 +0000 (15:47 +0200)]
Remove YangModuleInfo when it is unregistered

This patch addresses a FIXME, which was left in the code base
and thus makes sure we do not retain stale class loaders from
explicit registrations.

Unfortunately the design of this class mixes quite a few aspects:
- the ability to build SchemaContext
- the ability to explicitly register YangModuleInfos (with their
  dependencies)
- the ability to implicitly register YangModuleInfos through
  ClassLoadingStrategy.loadClass() failure path
- the ability to create an instance with pre-populated set of entries
  used only for testing/static purposes

The interplay between these aspects is ill-defined, especially
items 2 and 3, hence fixing the issue in most correct way possible
requires redesigning internal state tracking, explicitly
differentiating between the two cases.

JIRA: MDSAL-461
Change-Id: I8f99d3975e971e32b267788a463d9b73bb57e49e
Signed-off-by: Jie Han <han.jie@zte.com.cn>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoExpose IdentityCodec from BindingCodecTree 56/83256/16
Robert Varga [Thu, 25 Jul 2019 19:37:14 +0000 (21:37 +0200)]
Expose IdentityCodec from BindingCodecTree

Transcoding identities is needed to make sense of yangtools
identifiers (such as DatastoreIdentifier) versus binding classes.

Expose this functionality as BindingIdentityCodec from
BindingCodecTree and make use of it.

JIRA: MDSAL-460
Change-Id: I8b4110dd711eb18a2586fd1bd036d09fab13871a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd yanglib-rfc8525 52/83252/20
Robert Varga [Thu, 25 Jul 2019 14:04:28 +0000 (16:04 +0200)]
Add yanglib-rfc8525

This adds the necessary support for constructing mount points
described through RFC8525 (NMDA) YANG Library.

JIRA: MDSAL-463
Change-Id: I22b4449f544e3d0225bac59fa3928ecb434f8f13
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd a yanglib component 49/83249/13
Robert Varga [Wed, 24 Jul 2019 21:08:51 +0000 (23:08 +0200)]
Add a yanglib component

This adds the basic bridging between YANG Library and yangtools,
along with RFC7895 (non-NMDA) implementation. This allows schema
mounts described through RFC7895 to be parsed, when the provided
MountPointContextFactory implementation is fed into the parsers.

JIRA: MDSAL-464
Change-Id: I8092dd874648a4d115a5c16c3bbbbbc2b906419e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 3.0.4-SNAPSHOT 48/83248/2
Robert Varga [Thu, 25 Jul 2019 10:11:27 +0000 (12:11 +0200)]
Bump yangtools to 3.0.4-SNAPSHOT

This adopts yangtools-3.0.4 for the improvements made to rfc8528
support infrastructure.

Change-Id: Ic51134f1abdf8120a9071b4aeff7a054c707d941
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse checkState() in ModuleInfoBackedContext 09/83209/1
Robert Varga [Tue, 23 Jul 2019 12:03:43 +0000 (14:03 +0200)]
Use checkState() in ModuleInfoBackedContext

This simplifies the code a bit, by performing a checkState()
instead of explicit if/throw.

Change-Id: I1479c664a0f2c68585648df7ef9f3275aed16329
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoDecrease try-catch block size 07/83207/1
Robert Varga [Tue, 23 Jul 2019 10:33:23 +0000 (12:33 +0200)]
Decrease try-catch block size

We do not want to cover the registration process in (catch Exception),
as that will mask other failures.

Change-Id: I7942e5be1671b396a7daca117538e4d275d604cb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove trailing semicolons 98/83198/1
Robert Varga [Mon, 22 Jul 2019 13:21:48 +0000 (15:21 +0200)]
Remove trailing semicolons

These are throwing off sonar, remove them to keep it happy

Change-Id: I2cd19e34825916721512f956bcfc678953ebfb6f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoReorganize ModuleInfoBackedContext 92/83092/1
Robert Varga [Thu, 18 Jul 2019 09:08:30 +0000 (11:08 +0200)]
Reorganize ModuleInfoBackedContext

This is just a shuffle of methods, cleaning up the structure
of the file, making things more discoverable.

JIRA: MDSAL-461
Change-Id: Ibf80248cd91880cc0169e1d9a86eb6a95b2f7860
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse ActionNodeContainer.findAction() 48/82948/4
Robert Varga [Mon, 8 Jul 2019 09:21:40 +0000 (11:21 +0200)]
Use ActionNodeContainer.findAction()

This removes custom-coded lookup in favor of the common utility
method.

Change-Id: Ib2524b9bc8ef0a650dd1b78d694c250dffaae893
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 3.0.3 95/82895/4
Robert Varga [Fri, 21 Jun 2019 05:16:48 +0000 (07:16 +0200)]
Bump yangtools to 3.0.3

This picks up the latest yangtools release.

Change-Id: I5baeb81e3d947ba30f887ffd17ea437ec5f51fd3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd rfc8525 to docs 84/83084/1
Robert Varga [Thu, 18 Jul 2019 05:39:10 +0000 (07:39 +0200)]
Add rfc8525 to docs

Previous patch omitted adding the new artifact to docs, fix that.

JIRA: MDSAL-462
Change-Id: I48e3f66e9d261f624c66a12ceb13856e0edab3cd
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd RFC8525 ietf-yang-library model 80/83080/2
Robert Varga [Wed, 17 Jul 2019 15:54:47 +0000 (17:54 +0200)]
Add RFC8525 ietf-yang-library model

This is a NMDA-updated version of the model.

JIRA: MDSAL-462
Change-Id: Id82bf47439b6c726f352e3fa8a5628a88ec70b96
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump byte-buddy to 1.9.14 66/82966/1
Robert Varga [Mon, 8 Jul 2019 19:04:06 +0000 (21:04 +0200)]
Bump byte-buddy to 1.9.14

https://github.com/raphw/byte-buddy/releases/tag/byte-buddy-1.9.13
https://github.com/raphw/byte-buddy/releases/tag/byte-buddy-1.9.14

Change-Id: Ibef83b93b914945f48902ad54df822a656d41df2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unneeded null check 46/82946/1
Robert Varga [Mon, 8 Jul 2019 09:24:06 +0000 (11:24 +0200)]
Remove unneeded null check

We are performing a null and an instanceof check, where the latter
can also serve as a a null check. Remove the explicit null check.

Change-Id: Iac43aae00d8832cb7ade2f45041375451d5bedf4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unneeded temporary variables 45/82945/1
Robert Varga [Mon, 8 Jul 2019 09:16:24 +0000 (11:16 +0200)]
Remove unneeded temporary variables

getRpcs/getNotifications() result is only ever iterated over,
we do not need a full Set.

Change-Id: If066a9cbdba098116a3e8aa1a22b0ff05bf35df4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMark API bundles with Automatic-Module-Name 22/82922/3
Robert Varga [Wed, 3 Jul 2019 23:04:38 +0000 (01:04 +0200)]
Mark API bundles with Automatic-Module-Name

This patch updates core API packages to interact with JPMS, so
that they become automatic modules.

Change-Id: I9aa2f7dd7a82c9d7eaf4080d541db19991446da4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMake LogicalDatastoreType a WritableObject 21/82921/3
Robert Varga [Wed, 3 Jul 2019 22:37:53 +0000 (00:37 +0200)]
Make LogicalDatastoreType a WritableObject

This is a low-cardinality enum, which we need to serialize quite
often. Make it a simple WritableObject, so users can get common
handling. One specific user is sal-remoterpc-connector, which
needs to be able to serialize DOMDataTreeIdentifier.

JIRA: CONTROLLER-1894
Change-Id: Iee4610e093639629039a2e21ab1cfc852b756169
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump odlparent to 5.0.1 94/82894/1
Robert Varga [Fri, 21 Jun 2019 05:16:10 +0000 (07:16 +0200)]
Bump odlparent to 5.0.1

This picks up the latest odlparent release.

Change-Id: I72ce6fda88b8acf51e534e8366b590ae66cd8de4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix augmented action code generation 87/82887/2
Robert Varga [Tue, 2 Jul 2019 11:49:06 +0000 (13:49 +0200)]
Fix augmented action code generation

When an action is introduced as part of an augment statement, we
attempt to generate it in the augmented module, which refuses to
generate its input/output statements, leading to a NPE.

This patch updates codegen to ignore augmenting actions in the
augmented module and process them as part of augmentation.

JIRA: MDSAL-459
Change-Id: Ibd7d7abc5ec1eec6d32ee1885da00a0de69b2445
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoResolve bits/union nested type naming 44/82744/3
Robert Varga [Tue, 25 Jun 2019 13:07:06 +0000 (15:07 +0200)]
Resolve bits/union nested type naming

The cases where we allocate an enumeration, bits or union type
for a leaf-like construct (leaf, leaf-list) need to handle an
edge case -- JLS does not allow nested classes to be named the
same as the enclosing class.

Enumeration case was already handled in
AbstractGeneratedTypeBuilder, this patch extends that support
to handle bits and union.

JIRA: MDSAL-458
Change-Id: Idc19b179274c7973ed205ffdae1d2242cbd2dbf6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove unused Matcher 43/82743/2
Robert Varga [Wed, 26 Jun 2019 11:20:33 +0000 (13:20 +0200)]
Remove unused Matcher

DOT_MATCHER is not used anywhere, remove it.

Change-Id: Ibc9cbdab0d9008cfd63522db951c93843ea20a66
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoReuse SUCCESS_FUTURE 88/82688/2
Robert Varga [Mon, 24 Jun 2019 15:36:40 +0000 (17:36 +0200)]
Reuse SUCCESS_FUTURE

Rather than allocating new temporary objects reuse a constant
we have handy.

Change-Id: I3b27eb1cc75c967e4f880e2c5f287c040276f674
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoRemove use of getKeyValues() 81/82681/2
Robert Varga [Mon, 24 Jun 2019 10:32:26 +0000 (12:32 +0200)]
Remove use of getKeyValues()

This adjusts callers of deprecated method, fixing warnings and
allowing better integration in future.

Change-Id: I6f5bb82af22cfa94e7c532f596c813058b3511d4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoModuleInfoBackedContext cache 79/82679/1
Robert Varga [Mon, 24 Jun 2019 09:21:26 +0000 (11:21 +0200)]
ModuleInfoBackedContext cache

ModuleInfoBackedContext can be effectively cached based on
the set of class loading strategy and infos that go into it. This
patch adds such a cache.

JIRA: MDSAL-418
Change-Id: Icbb7ac5270c76c374a6e839010090a002b0ab176
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoMigrate ModuleInfo cache to BindingReflections 72/82672/3
Robert Varga [Sun, 23 Jun 2019 21:54:34 +0000 (23:54 +0200)]
Migrate ModuleInfo cache to BindingReflections

Reflections are using a cache already, so adding another one does
not really hurt. This allows code reuse between our test suite
and downstreams.

JIRA: MDSAL-418
Change-Id: Id4474a0754f33b880afaff333279969f947df494
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoAdd CDI annotations to mdsal-binding-dom-adapter 88/79888/18
Michael Vorburger [Thu, 24 Jan 2019 21:47:07 +0000 (22:47 +0100)]
Add CDI annotations to mdsal-binding-dom-adapter

This annotates core classes, so they can be used via CDI.

JIRA: MDSAL-418
Change-Id: Ia943dd10cad35481ef742400c79491c1d092c6c7
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFlatten submodule hierarchy for YangModuleInfo 70/82470/4
Anna Bencurova [Mon, 10 Jun 2019 12:55:49 +0000 (14:55 +0200)]
Flatten submodule hierarchy for YangModuleInfo

YANG inherently contains modules and submodules, where submodules
do not really have further submodules. While YANG 1.0 allowed
inclusion of submodules in other submodules, and that is modeled
in yang-model-api, this practice has been deprecated with YANG 1.1.

If we are faced with multiple such includes, for example both
module and submodule including a second submodule, we could end up
generating superfluous classes, just to represent the second
submodule twice (once for module's purposes and once for submodule's
purposes) -- hence when all of them are collected recursively, we
would end up with two distinct instances for the same source.

Since submodules are not directly visible outside of the main class,
this hierarchy is not public API and is a purely internal thing.

This patch re-organizes generation so that we present all submodules
as dependencies of the main module, which automatically solves the
problem, while also making for nicer class layout, as we do not get
multiply-nested classes.

JIRA: MDSAL-457
Change-Id: Ic78edaf852f3497f3c4c96fdca3a77de30b7f8c1
Signed-off-by: Anna Bencurova <Anna.Bencurova@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoFix superfluous warning 59/82559/2
Robert Varga [Tue, 18 Jun 2019 20:07:54 +0000 (22:07 +0200)]
Fix superfluous warning

We can end up warning about choices which are not cached, just
because we have a miss. Fix this up so that we properly handle
rejected caching.

Change-Id: I90589e50a749c65226a1e174409e9fd744d7bc30
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoCheck registration being closed 37/82537/1
Robert Varga [Tue, 30 Apr 2019 03:35:41 +0000 (05:35 +0200)]
Check registration being closed

Check if the registration has been closed before firing events.
This way we stop delivering events a bit sooner, improving shutdown
speed and correctness.

JIRA: MDSAL-429
Change-Id: I533f2b07e8cd14597c29d2d3d9c11c44a1bb7ff5
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump yangtools to 3.0.2 95/82495/1
Robert Varga [Wed, 12 Jun 2019 00:44:37 +0000 (02:44 +0200)]
Bump yangtools to 3.0.2

The release brings a number of improvements, bring it in.

Change-Id: I1bbbb09cea86f1d73119ae3948dba4f9e362a485
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoBump versions to 4.0.3-SNAPSHOT 55/82355/2
Robert Varga [Fri, 31 May 2019 14:06:54 +0000 (16:06 +0200)]
Bump versions to 4.0.3-SNAPSHOT

This starts the next development iteration.

Change-Id: I8220119b4898fbc8c6a49d13eac79f4080c729e4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoUse cached AugmentationIdentifiers in BindingRuntimeContext 52/82352/2
Robert Varga [Fri, 31 May 2019 10:55:50 +0000 (12:55 +0200)]
Use cached AugmentationIdentifiers in BindingRuntimeContext

AugmentationIdentifiers allocated from BindingRuntimeContext
end up being used across the system. This ensures we squash
instances to system-wide cache.

Change-Id: I0d75dc8815f86cb1dda13ef118ceb9b6455a31e3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
4 years agoImprove getResolvedAugmentationSchema() 51/82351/1
Robert Varga [Fri, 31 May 2019 10:11:08 +0000 (12:11 +0200)]
Improve getResolvedAugmentationSchema()

This method is used for instantiating prototypes, from whence
it is used all over the place. Sharing a single instance allows
us to slightly improve lookups.

Change-Id: I93eb21ef83aef80ab0f26614950ebb042a7473ed
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>