controller.git
10 months agoDo not use optional in ShardLeaderStateChanged 11/109511/7
Robert Varga [Sun, 31 Dec 2023 05:01:47 +0000 (06:01 +0100)]
Do not use optional in ShardLeaderStateChanged

Use a simple nullable, as all users know what's going on.

Change-Id: I931e71763d137c5a50432604214a75e0bfdcdd37
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoBump Kryo to 4.0.3 26/109526/3
Robert Varga [Sun, 31 Dec 2023 12:16:35 +0000 (13:16 +0100)]
Bump Kryo to 4.0.3

https://github.com/EsotericSoftware/kryo/releases/tag/kryo-parent-4.0.3

Change-Id: Iebb8fb4a24c2406053a77fc141fc6ed8ad9b2462
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoMake LocalSnapshotStore final 30/109530/2
Robert Varga [Sun, 31 Dec 2023 18:36:31 +0000 (19:36 +0100)]
Make LocalSnapshotStore final

We have a SpotBugs suppression which ends up being unnecessary if the
class is final.

Change-Id: If58497303871ae136875c80b8b094276ccda9d64
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoTurn LongSerdes into an enum 28/109528/1
Robert Varga [Sun, 31 Dec 2023 14:38:29 +0000 (15:38 +0100)]
Turn LongSerdes into an enum

Use proper singleton for reuse.

JIRA: CONTROLLER-2089
Change-Id: Ia03b8610370521e97e45f67def07a32f1bf7d59b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRename DataJournalEntrySerializer 27/109527/1
Robert Varga [Sun, 31 Dec 2023 14:39:50 +0000 (15:39 +0100)]
Rename DataJournalEntrySerializer

DataJournalEntrySerdes is the proper name, use that.

JIRA: CONTROLLER-2089
Change-Id: I53247f7b226ed7ab0ff42ac24ad6f4d549e5db97
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoModernize sal-akka-segmented-journal 85/109485/6
Robert Varga [Fri, 29 Dec 2023 11:58:53 +0000 (12:58 +0100)]
Modernize sal-akka-segmented-journal

Use local variable type inference, instanceof patterns and seal
DataJournalEntry.

JIRA: CONTROLLER-2089
Change-Id: I3c2ee2de5eaae6874e2f75a44dfd6fce0942e8ae
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoServerInfo should be a plain record 86/109486/4
Robert Varga [Fri, 29 Dec 2023 12:30:50 +0000 (13:30 +0100)]
ServerInfo should be a plain record

This is a pure DTO, turn it into a record, eliminating quite a bit of
verbosity.

Also clean up RaftActorContextImpl.updatePeerIds() so we do not juggle
two booleans and set/reset our voting status.

Change-Id: Ifbb2ae0c8163472b8ef3b59210f12dccb1b8e30d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoMerge ClientRequestTracker 08/109508/6
Robert Varga [Sun, 31 Dec 2023 03:31:50 +0000 (04:31 +0100)]
Merge ClientRequestTracker

The split between interface and implementation is completely
unnecessary, this is just a simple DTO.

Change-Id: Ie10a68b003b6ef82f59fb298cd433c8b876afcc3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDo not leak ReplicatedLogEntry in Replicate message 07/109507/7
Robert Varga [Sun, 31 Dec 2023 03:15:08 +0000 (04:15 +0100)]
Do not leak ReplicatedLogEntry in Replicate message

While convenient, this is a leak of constructs and contains a debug-only
access to data. While we are at it make Replicate a simple record.

JIRA: CONTROLLER-2044
Change-Id: I92a364a9590771f0bb9278e2e8ca8176691b8f75
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoIntroduce CommitTransactionPayload.CandidateTransaction 04/109504/5
Robert Varga [Sun, 31 Dec 2023 02:25:32 +0000 (03:25 +0100)]
Introduce CommitTransactionPayload.CandidateTransaction

Do not use an Entry but rather a dedicated type, which allows us to
unbox things a bit.

Change-Id: I16e97cbe8aa6e3f4f9543a9f71a95a09191689c0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoFrontendClientMetadata(Builder) should not be Identifiable 03/109503/6
Robert Varga [Sun, 31 Dec 2023 00:45:01 +0000 (01:45 +0100)]
FrontendClientMetadata(Builder) should not be Identifiable

Expose a clientId() to internal package users instead.

Change-Id: I7f14170a50e04a5d8752c24a7137c218b9960082
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoSeal FrontendClientMetadataBuilder 02/109502/5
Robert Varga [Sun, 31 Dec 2023 00:24:42 +0000 (01:24 +0100)]
Seal FrontendClientMetadataBuilder

This is a simple specialization, seal it.

Change-Id: I5516da14e423b83369e5da1c64e45da3c2ed24d7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoSeal AbstractProxyTransaction 00/109500/5
Robert Varga [Sun, 31 Dec 2023 00:19:58 +0000 (01:19 +0100)]
Seal AbstractProxyTransaction

Class hierarchy here is firmly defined, express that through
seal/permits.

Change-Id: I3fc8f04133a788b0c89e156d0e8deb5a5abead7a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoAccess clientActor exactly once 06/109506/5
Robert Varga [Sun, 31 Dec 2023 02:39:35 +0000 (03:39 +0100)]
Access clientActor exactly once

Make sure the null check is explicit to everyone.

Change-Id: I299728e411712ad73a83e78d66d078b0d79453b4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoTurn ShardContainer into a record 01/109501/4
Robert Varga [Sun, 31 Dec 2023 00:23:35 +0000 (01:23 +0100)]
Turn ShardContainer into a record

We have Java 17 now, use a record instead of a final class.

Change-Id: I340bf3f288ef8264dafc7d77403c5482f307a671
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse instanceof patterns in ShardManager 96/109496/4
Robert Varga [Sat, 30 Dec 2023 21:58:36 +0000 (22:58 +0100)]
Use instanceof patterns in ShardManager

Reduce the amount of casts we perform by using instanceof patterns.

Change-Id: I918a15cf52f67ee072a1e7e88d5624bf161cdb3e
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse a switch expression in getServerChangeException() 95/109495/2
Robert Varga [Sat, 30 Dec 2023 22:08:37 +0000 (23:08 +0100)]
Use a switch expression in getServerChangeException()

Improve clarity and defenses by using a switch expression, which ensures
we cover all cases.

Change-Id: Ibe39c25a780b1776985ffdb1d968c58fa922f51d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoShardDataTreeCohort should not be identifiable 99/109499/2
Robert Varga [Sun, 31 Dec 2023 00:12:30 +0000 (01:12 +0100)]
ShardDataTreeCohort should not be identifiable

Having a public getIdentifier() member does not make carry domain
information.

Define a package-local transactionId() method serving the same purpose.

Change-Id: If60b02ea6a07b094cd655e3c50dc6ba428c263c3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoSeal LeaderFrontendState 98/109498/2
Robert Varga [Sat, 30 Dec 2023 23:56:20 +0000 (00:56 +0100)]
Seal LeaderFrontendState

We have only internal implementations, express that in the class
hierarchy explicitly.

Change-Id: I56dda91d8c14fc4e6ed10424dfbc5da2629092cb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDo not use static import for Patterns.ask() 97/109497/3
Robert Varga [Sat, 30 Dec 2023 21:46:02 +0000 (22:46 +0100)]
Do not use static import for Patterns.ask()

Improve call site visibility by explicitly referencing this method as
Patterns.ask().

Change-Id: I94f21ba9a5e2d0a2e3de89f6826896ea98a24641
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove SuccessReply 91/109491/2
Robert Varga [Sat, 30 Dec 2023 20:40:18 +0000 (21:40 +0100)]
Remove SuccessReply

This message is not used, remove it.

Change-Id: I23c9be05063d7ed92779e4fb66904a0fd848062d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDeprecate SuccessReply for removal 90/109490/2
Robert Varga [Sat, 30 Dec 2023 20:39:31 +0000 (21:39 +0100)]
Deprecate SuccessReply for removal

This class is not used anywhere, deprecate it for removal.

Change-Id: I26b51aeda81ed9811171b53e9f797baa1c2bf994
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove EmptyExternalizable 93/109493/2
Robert Varga [Sat, 30 Dec 2023 20:45:29 +0000 (21:45 +0100)]
Remove EmptyExternalizable

This class is not used, remove it.

Change-Id: I1cd54f24b07075c386f357c9be7af486985239b0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDeprecate EmptyExternalizable for removal 92/109492/2
Robert Varga [Sat, 30 Dec 2023 20:44:53 +0000 (21:44 +0100)]
Deprecate EmptyExternalizable for removal

This class is not used anywhere, deprecate it for removal.

Change-Id: I3303a14570bfadaa524841e7622f20dd955f67e3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove ask-based protocol client 67/108867/13
bentom-binoy [Tue, 7 Nov 2023 06:44:41 +0000 (06:44 +0000)]
Remove ask-based protocol client

Remove the use-tell-based-protocol knob, effectively making it always
true.

This means DistributedDataStore cannot be instantiated, which leads to
its removal. That in turn makes all of DatastoreContext,
OperationLimiter and similar classes superfluous, so we remove those as
well.

A few classes are used to drive the shard backend in integration tests,
and hence those are moved to test sources.

JIRA: CONTROLLER-2054
Change-Id: Ie20b1c898576d3c89b70b34121310e58faddbf8e
Signed-off-by: bentom-binoy <bentom.binoy@infosys.com>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUnconditionally remove knownFrontends 89/109489/1
Robert Varga [Sat, 30 Dec 2023 19:58:06 +0000 (20:58 +0100)]
Unconditionally remove knownFrontends

As noted in the comment, known frontends end up being restored from
metadata when we unpause (or become leader for that matter).

The DatastoreContext property being used in this conditional is a
frontend thing anyway, so the only thing it could really affect is
tests.

The only case where this would be needed is when we are the leader, have
started persisting the DisableTrackingPayload, but it has not propagated
during pause/unpause.

That is okay, as the leader handover ensures that all locally-appended
entries are appended, so that the new leader just continues on.

Change-Id: Icf775823aed91c15f7a8f74fa2f07faee3a084a0
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoMigrate ActorBehaviorTest to JUnit5 81/109481/2
Robert Varga [Fri, 29 Dec 2023 11:10:26 +0000 (12:10 +0100)]
Migrate ActorBehaviorTest to JUnit5

Eliminate the need for mockito-subclass by migrating to JUnit5 and
correcting mocking configuration.

Change-Id: I3d3a772abe71e0d0576474aa9f2b22cef7fbea0a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoClean up DistributedDataStoreRemotingIntegrationTest 62/109462/6
Robert Varga [Fri, 29 Dec 2023 02:10:21 +0000 (03:10 +0100)]
Clean up DistributedDataStoreRemotingIntegrationTest

Migrate checks so they do not reference DistributedDataStore.

JIRA: CONTROLLER-2054
Change-Id: I3735f45661a31bed1e5da14750e48b7fefd782da
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDo not special-case AbstractDistributedDataStoreIntegrationTest 60/109460/6
Robert Varga [Fri, 29 Dec 2023 01:52:25 +0000 (02:52 +0100)]
Do not special-case AbstractDistributedDataStoreIntegrationTest

AbstractDistributedDataStoreIntegrationTest has a few references to
DistributedDataStore. Remove them in favor of alternatives assuming
ClientBackedDataStore.

JIRA: CONTROLLER-2054
Change-Id: I99ae9584b9dd14cc39f7ca23eac56d9deef472d6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove ask-based datastore integration tests 56/109456/7
Robert Varga [Fri, 29 Dec 2023 01:12:38 +0000 (02:12 +0100)]
Remove ask-based datastore integration tests

Eliminate DistributedDataStore as an argument.

JIRA: CONTROLLER-2054
Change-Id: If44dd72706c028f5d3901a759549fec27257d5d3
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove DistributedDataStoreTest 55/109455/7
Robert Varga [Fri, 29 Dec 2023 00:56:48 +0000 (01:56 +0100)]
Remove DistributedDataStoreTest

Rehost the tests for waiting into ClientBackedDataStoreTest, leaving
only limiter tests around -- and those are no longer useful.

JIRA: CONTROLLER-2054
Change-Id: Idf908cd33110c610c8fe0c0b37cd69dabdd3f367
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoSwitch MemberNode to ClientBackedDatastore 59/109459/6
Robert Varga [Fri, 29 Dec 2023 01:44:19 +0000 (02:44 +0100)]
Switch MemberNode to ClientBackedDatastore

DistributedDataStore is on its way out, switch to using the sole
AbstractDataStore implementation.

JIRA: CONTROLLER-2054
Change-Id: I5a8ee344c56a7a768c373ffa4bc489ef249529ff
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoSwitch DataTreeCohortIntegrationTest to tell-based datastore 61/109461/5
Robert Varga [Fri, 29 Dec 2023 01:57:39 +0000 (02:57 +0100)]
Switch DataTreeCohortIntegrationTest to tell-based datastore

DistributedDataStore is going away and this test should not care anyway.
Migrate it to use ClientBackedDataStore.

JIRA: CONTROLLER-2054
Change-Id: I67f92c91a8aa441ac52a5f9ad9c178c5c6faff01
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoBump versions to 9.0.0-SNAPSHOT 72/109472/1
Robert Varga [Fri, 29 Dec 2023 07:28:57 +0000 (08:28 +0100)]
Bump versions to 9.0.0-SNAPSHOT

This starts the next major development iteration.

Change-Id: I4b34962db224b70d3c13f365acbb5f0986937fed
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoBump versions to 8.0.5-SNAPSHOT 71/109471/1
Robert Varga [Fri, 29 Dec 2023 07:27:57 +0000 (08:27 +0100)]
Bump versions to 8.0.5-SNAPSHOT

This starts the next development iteration.

Change-Id: Ib1a36a0278af6034f2378fa91a7e2103b9abf0ce
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRelease controller v8.0.4
jenkins-releng [Fri, 29 Dec 2023 05:11:03 +0000 (05:11 +0000)]
Release controller

10 months agoClean up Shard a bit 63/109463/2
Robert Varga [Fri, 29 Dec 2023 02:40:00 +0000 (03:40 +0100)]
Clean up Shard a bit

Use instanceof patterns and local variable type inference to simplify
code a bit.

Change-Id: If437909b1a012a60fa5fd296dda6bffeb161fd25
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months ago{Start,Stop}DropMessages is generic 57/109457/3
Robert Varga [Fri, 29 Dec 2023 01:19:26 +0000 (02:19 +0100)]
{Start,Stop}DropMessages is generic

Add a diamond to constructor invocations to remove warnings.

Change-Id: I29f063eaf65656aef6715a8fe710e2afb35169e7
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove setupDistributedDataStore() 58/109458/1
Robert Varga [Fri, 29 Dec 2023 01:40:16 +0000 (02:40 +0100)]
Remove setupDistributedDataStore()

These methods are no longer in use, remove them.

JIRA: CONTROLLER-2054
Change-Id: I8be5220eddb093e43ff3c71aa13fa40a60ddcc5a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoBump upstreams 48/109448/4
Robert Varga [Thu, 28 Dec 2023 20:35:07 +0000 (21:35 +0100)]
Bump upstreams

Adopt:
- odlparent-13.0.10
- yangtools-11.0.5
- mdsal-12.0.4

Change-Id: Ia6f7420c5751436ec97d0a45187d79dadf9c3d94
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoClean up ClientBackedDataStoreTest 54/109454/2
Robert Varga [Fri, 29 Dec 2023 00:46:03 +0000 (01:46 +0100)]
Clean up ClientBackedDataStoreTest

Use local variable type inference to simplify code a bit.

Change-Id: I5d6c116f40fb84250b3f775e92b98de558dde14d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoRemove setupDistributedDataStoreWithoutConfig() 53/109453/2
Robert Varga [Fri, 29 Dec 2023 00:40:16 +0000 (01:40 +0100)]
Remove setupDistributedDataStoreWithoutConfig()

These legacy methods have been deprecated since previous major version,
remove them.

JIRA: CONTROLLER-2054
Change-Id: I13077de6ca505af6bf8627d7094e49a719636e32
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse constructor injection in OSGiDistributedDataStore 50/109450/1
Robert Varga [Thu, 28 Dec 2023 21:27:36 +0000 (22:27 +0100)]
Use constructor injection in OSGiDistributedDataStore

Upgraded SpotBugs does not like unitialized fields. Use constructor
injection to properly set them up.

Change-Id: I8d5226a8b0b6b2929eba3d4d9a73ac8e1c72613a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse VarHandles.fullFence() instead of an 'updated' field 49/109449/1
Robert Varga [Thu, 28 Dec 2023 21:10:15 +0000 (22:10 +0100)]
Use VarHandles.fullFence() instead of an 'updated' field

Upgraded SpotBugs does not like an otherwise-unused field. Preempt
failures by using VarHandles.fullFence() instead.

Also modernize ActorUtils by using instanceof patterns and local
variable type inference.

Change-Id: Iec9b717eaf821657f3ced659e0c6e86f360b21c5
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse constructor injection in OSGiActorSystemProvider 47/109447/1
Robert Varga [Thu, 28 Dec 2023 20:57:03 +0000 (21:57 +0100)]
Use constructor injection in OSGiActorSystemProvider

Upgraded SpotBugs does not like us not having initialized fields, use
contructor injection to side-step these warnings.

Change-Id: I3eef23b3cea88c97ccd8cb8794ec0587f07ccc77
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoDo not allow global timer to be stopped 46/109446/1
Robert Varga [Thu, 28 Dec 2023 20:34:11 +0000 (21:34 +0100)]
Do not allow global timer to be stopped

We have a globally-shared instance, it should never be stopped via
Timer.stop(). Log a warning whenever that is atttempted.

Change-Id: Id29f3799024b826d2278bf95f75cc661f85ab8e8
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse constructor injection for OSGiGlobalTimer 45/109445/1
Robert Varga [Thu, 28 Dec 2023 20:32:15 +0000 (21:32 +0100)]
Use constructor injection for OSGiGlobalTimer

Upgraded SpotBugs is warning about field initialization, side-step it by
using constructor injection.

Change-Id: I1697459db8d72c956649f3c61f3d090322c3e9fb
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
10 months agoUse constructor injection in OSGiRemoteOpsProvider 44/109444/1
Robert Varga [Thu, 28 Dec 2023 20:18:13 +0000 (21:18 +0100)]
Use constructor injection in OSGiRemoteOpsProvider

We have a simple component here, use constructor injection to preempty
upgraded SpotBugs issuing errors on it.

Change-Id: Id65f63b374497aabccb98ebe06b52195f76f8099
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
11 months agoEliminate SE_BAD_FIELD suppressions 56/109056/1
Robert Varga [Fri, 24 Nov 2023 15:10:33 +0000 (16:10 +0100)]
Eliminate SE_BAD_FIELD suppressions

We are implementing Serializable Proxy pattern, which should really be
enforced via throwing appropriate exceptions from
readObject()/writeObject() et al.

This retrofits the mininal set to keep SpotBugs happy, eliminating the
associated suppressions.

Change-Id: I8264114b1f0ed74123f0163d62d953dc45a8a9d1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
12 months agoBump versions to 8.0.4-SNAPSHOT 68/108768/1
Robert Varga [Tue, 31 Oct 2023 10:24:46 +0000 (11:24 +0100)]
Bump versions to 8.0.4-SNAPSHOT

This starts the next development iteration.

Change-Id: I69bcc13470a9ac9ae85c9f4fa7f585527d4c58fa
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
12 months agoRelease controller v8.0.3
jenkins-releng [Tue, 31 Oct 2023 08:38:10 +0000 (08:38 +0000)]
Release controller

12 months agoBump upstreams 63/108763/1
Robert Varga [Mon, 30 Oct 2023 22:40:53 +0000 (23:40 +0100)]
Bump upstreams

Adopt:
- odlparent-13.0.7
- yangtools-11.0.4
- mdsal-12.0.3

Change-Id: Ia9d419001f6803a21e191529ffe405b9219d6815
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
12 months agoDo not use RpcService in ntfbenchmark 05/108005/3
Oleksandr Zharov [Thu, 28 Sep 2023 11:30:48 +0000 (13:30 +0200)]
Do not use RpcService in ntfbenchmark

Migrated usage of RpcService to Rpc<?,?> for ntfbenchmark.

JIRA: CONTROLLER-2085
Change-Id: I04c7b10e47e75a53667fcac9778d23cd74dc4c25
Signed-off-by: Oleksandr Zharov <oleksandr.zharov@pantheon.tech>
12 months agoDo not use RpcService in dsbenchmark 04/108004/3
Oleksandr Zharov [Thu, 28 Sep 2023 11:23:52 +0000 (13:23 +0200)]
Do not use RpcService in dsbenchmark

Migrated usage of RpcService to Rpc<?,?> for dsbenchmark.

JIRA: CONTROLLER-2085
Change-Id: If0b4e4f14e94a583f518cdd5281ff779076aaabe
Signed-off-by: Oleksandr Zharov <oleksandr.zharov@pantheon.tech>
12 months agoRefactor RaftActorTest to avoid test failures 97/106497/8
Šimon Ukuš [Thu, 15 Jun 2023 11:47:28 +0000 (13:47 +0200)]
Refactor RaftActorTest to avoid test failures

The "doReturn(value).when(mockObj).coolMethod(same(arg))" way of mocking
the return values for "coolMethod()" calls resulted in
UnfinishedStubbingException, even though there seems to be no reason
for such error. This change introduces "the other" way of such mocking:
"when(mockObj.coolMethod(same(arg)).thenReturn()".

JIRA: CONTROLLER-2080
Change-Id: I58b9c08780c27b43ad5eff4e21c921b9260fc236
Signed-off-by: Šimon Ukuš <simon.ukus@pantheon.tech>
Signed-off-by: Samuel Schneider <samuel.schneider@pantheon.tech>
12 months agoMake snapshot offset long to prevent overflow 44/107444/12
tibor.kral [Tue, 3 Oct 2023 08:53:08 +0000 (10:53 +0200)]
Make snapshot offset long to prevent overflow

The current implementation uses integer which can
easily overflow if the Snapshot grows over 2.14GB

JIRA: CONTROLLER-2086
Change-Id: Ibbe3d3e1667cf59137e057b31141033a826142e4
Signed-off-by: tibor.kral <tibor.kral@pantheon.tech>
Signed-off-by: Samuel Schneider <samuel.schneider@pantheon.tech>
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoClean up SerializationUtilsTest 73/108073/1
Robert Varga [Fri, 29 Sep 2023 20:32:27 +0000 (22:32 +0200)]
Clean up SerializationUtilsTest

Migrate to using xmlunit-core and modernize the logic.

Change-Id: I8f116f18abcca8e20d104bd71e1b14e59f1778fd
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoBump versions to 8.0.3-SNAPSHOT 06/107906/1
Robert Varga [Mon, 18 Sep 2023 14:49:58 +0000 (16:49 +0200)]
Bump versions to 8.0.3-SNAPSHOT

This starts the next development iteration.

Change-Id: Id03b4dbd4f469429f1f81a3f301a094e20d18e67
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoRelease controller v8.0.2
jenkins-releng [Mon, 18 Sep 2023 08:42:52 +0000 (08:42 +0000)]
Release controller

13 months agoBump upstreams 97/107897/1
Robert Varga [Sun, 17 Sep 2023 11:52:12 +0000 (13:52 +0200)]
Bump upstreams

Adopt:
- yangtools-11.0.2
- mdsal-12.0.2

Change-Id: I78b30c5ce094c5534cba80ff5e992a85e247eea1
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
13 months agoBump Scala to 2.13.12 88/107788/1
Robert Varga [Mon, 11 Sep 2023 12:39:50 +0000 (14:39 +0200)]
Bump Scala to 2.13.12

https://github.com/scala/scala/releases/tag/v2.13.12

Change-Id: Ic406869380c4b639508d05ef0e40ca9c2a09cb75
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoBump versions to 8.0.2-SNAPSHOT 06/107606/1
Robert Varga [Thu, 31 Aug 2023 07:19:23 +0000 (09:19 +0200)]
Bump versions to 8.0.2-SNAPSHOT

This starts the next development iteration.

Change-Id: If8424903429c1ced29283493841b6c6d751cdd98
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoRelease controller v8.0.1
jenkins-releng [Thu, 31 Aug 2023 06:12:44 +0000 (06:12 +0000)]
Release controller

14 months agoBump upstreams 91/107591/4
Robert Varga [Wed, 30 Aug 2023 14:39:52 +0000 (16:39 +0200)]
Bump upstreams

Adopt:
- odlparent-13.0.4
- yangtools-11.0.1
- mdsal-12.0.1

Change-Id: Iff02463539ad8888748ea969beeff3a7add10b16
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoRemove CarEntityOwnershipListener 95/107595/1
Robert Varga [Wed, 30 Aug 2023 15:04:11 +0000 (17:04 +0200)]
Remove CarEntityOwnershipListener

This is a superfluous class, replace it with a simple lambda.

Change-Id: I5ce16ec87b93d95c937a77a9ae1b57daa32449d6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix sal-remoterpc-connector checkstyle 94/107594/1
Robert Varga [Wed, 30 Aug 2023 15:01:38 +0000 (17:01 +0200)]
Fix sal-remoterpc-connector checkstyle

Upgraded checkstyle is flagging a few nested classes as potentially
final, fix that up.

Change-Id: Ie3835769d50e3a692644fc0dbed480e6c4d5f2de
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix sal-distributed-datastore checkstyle 93/107593/1
Robert Varga [Wed, 30 Aug 2023 15:01:08 +0000 (17:01 +0200)]
Fix sal-distributed-datastore checkstyle

Upgraded checkstyle is flagging a few nested classes as potentially
final, fix that up.

Change-Id: I8f5370fb700a76f6f71ad186d78cbb50e595a8a2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoClean up SnapshotManager nested classes 92/107592/1
Robert Varga [Wed, 30 Aug 2023 14:54:21 +0000 (16:54 +0200)]
Clean up SnapshotManager nested classes

Upgraded checkstyle is detecting a number of these as 'should be final'.
Fix those findings.

Change-Id: I171c046616a0b0c30f5cd46de0d3486e9943e757
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoFix FlexibleThreadPoolWrapper checkstyle 90/107590/1
Robert Varga [Wed, 30 Aug 2023 14:50:22 +0000 (16:50 +0200)]
Fix FlexibleThreadPoolWrapper checkstyle

Nested static classes are detected as checkstyle violations if they are
not final. Fix that.

Change-Id: Ifa5878890cabe845ecf8d98d46f2fc8015a78770
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
14 months agoMake MemoryOutputStream final 89/107589/1
Robert Varga [Wed, 30 Aug 2023 14:48:38 +0000 (16:48 +0200)]
Make MemoryOutputStream final

This is a checkstyle violation with upgraded checkstyle. Fix that.

Change-Id: I370b50baa146a710632e501f1ce7acad913166c2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoFix links to prevent redirects 25/107125/1
Robert Varga [Thu, 27 Jul 2023 17:39:05 +0000 (19:39 +0200)]
Fix links to prevent redirects

IETF has retired tools, use rfc-editor/datatracker instead.

Change-Id: I1e033045b7e9dd61e02831dd4e2ebf793459fc93
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoRemove Config Subsystem documentation 23/107123/3
Robert Varga [Thu, 27 Jul 2023 17:05:12 +0000 (19:05 +0200)]
Remove Config Subsystem documentation

The configuration subsystem is long-gone. Remove its documentation from
developer guide.

Change-Id: I0da59ec514f9f9208d099f05702c95d9c1e83eb9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoFix documentation links 24/107124/1
Robert Varga [Thu, 27 Jul 2023 17:29:53 +0000 (19:29 +0200)]
Fix documentation links

The links are pointing to wiki resources which no longer exist. Point to
wiki-archive instead.

Change-Id: Ie633ed1a010a382d47084c370decf1e84a2a4ee6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
15 months agoUse Futures.submit() 11/106811/1
Robert Varga [Tue, 4 Jul 2023 19:51:57 +0000 (21:51 +0200)]
Use Futures.submit()

Do not wrap the ExecutorService and just use Futures.submit() to arrive
at a ListenableFuture with any executor.

Change-Id: Id43ba68f65aa7a358159024364515f8029b95d5f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump versions to 8.0.1-SNAPSHOT 79/106779/1
Robert Varga [Sun, 2 Jul 2023 11:23:54 +0000 (13:23 +0200)]
Bump versions to 8.0.1-SNAPSHOT

This starts the next development iteration.

Change-Id: I04240b9680f53eb675e3d1a553aec893cc8de1e5
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoRelease controller v8.0.0
jenkins-releng [Sun, 2 Jul 2023 10:04:49 +0000 (10:04 +0000)]
Release controller

16 months agoModernize DataTreeCandidateInputOutput 76/106776/3
Robert Varga [Sat, 1 Jul 2023 17:45:46 +0000 (19:45 +0200)]
Modernize DataTreeCandidateInputOutput

Use local variable type inference and use records.

Change-Id: Iac4a7325d922cde24ed9180c2db4dcea09c3b8f4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoRemove support for pre-Fluorine versions 11/103511/10
Robert Varga [Fri, 2 Dec 2022 07:47:06 +0000 (08:47 +0100)]
Remove support for pre-Fluorine versions

We are carrying support for talking RAFT all the way to the initial
version. This is not necessary and a bit inefficient. This patch removes
support for talking to anything older than Fluorine GA.

JIRA: CONTROLLER-2082
Change-Id: Ib9b345aed478004f37f334abae2e3a2879e96512
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoRemove legacy RaftRPC proxies 77/105177/7
Robert Varga [Mon, 3 Apr 2023 14:34:22 +0000 (16:34 +0200)]
Remove legacy RaftRPC proxies

These proxies have not been used since version 7.0.0, remove them.

JIRA: CONTROLLER-2081
Change-Id: I6a2ff617c8e356b0ab3e05ffc25ba432fb6096a9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoRemove FollowerIdentifier.Proxy 76/105176/8
Robert Varga [Mon, 3 Apr 2023 14:33:56 +0000 (16:33 +0200)]
Remove FollowerIdentifier.Proxy

This proxy has been deprecated, remove it.

JIRA: CONTROLLER-2081
Change-Id: I1a80305a87c692ff1c39f02a7113d4c29847dc22
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump mdsal to release 65/106765/1
Robert Varga [Fri, 30 Jun 2023 07:12:06 +0000 (09:12 +0200)]
Bump mdsal to release

Use proper mdsal-12.0.0 release.

Change-Id: I0b377692c5ea48ccbdd45ecc64d6f0542999dbb4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoFix cds-access-client dependencies 01/106701/1
Robert Varga [Mon, 26 Jun 2023 16:36:37 +0000 (18:36 +0200)]
Fix cds-access-client dependencies

Add jdt.annotations to dependencies, as they are no longer declared by
default.

Change-Id: I962236670053f6d85c7a451a2601cc93ff2f6bc4
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoFix sal-akka-raft dependencies 00/106700/1
Robert Varga [Mon, 26 Jun 2023 16:36:05 +0000 (18:36 +0200)]
Fix sal-akka-raft dependencies

Add jdt.annotations to dependencies, as they are no longer declared by
default.

Change-Id: I6cb95b30b8b38550061886f3a4aa4fcd158d35b2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up sal-remoterpc-connector dependencies 99/106699/2
Robert Varga [Mon, 26 Jun 2023 16:28:19 +0000 (18:28 +0200)]
Clean up sal-remoterpc-connector dependencies

We have quite a few warnings, reign them in.

Change-Id: I8b35ee98a7dc3f5e00e5ff08a61339df11c3be6f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up javadoc links 95/106695/1
Robert Varga [Mon, 26 Jun 2023 13:39:51 +0000 (15:39 +0200)]
Clean up javadoc links

Use HTTPS and modernize pointers.

Change-Id: I07352116ebe7b2f30d8db6c230ae14ce1c7593d6
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoFix sal-distributed-datastore dependencies 94/106694/1
Robert Varga [Mon, 26 Jun 2023 13:22:50 +0000 (15:22 +0200)]
Fix sal-distributed-datastore dependencies

We need mdsal-binding-dom-codec as a testing dependency.

Change-Id: I7ba1a864f1b3bdcef5caf911fc2c2f84fc4e3f63
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump upstreams 74/106674/1
Robert Varga [Mon, 26 Jun 2023 11:45:34 +0000 (13:45 +0200)]
Bump upstreams

Adopt:
- odlparent-13.0.3
- yangtools-11.0.0

Change-Id: I8103c699e8217a5ab4e2393813009754295dbc2a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoAdjust to yang.binding.{Identifier,Identifiable} rename 09/106609/1
Robert Varga [Wed, 21 Jun 2023 18:42:39 +0000 (20:42 +0200)]
Adjust to yang.binding.{Identifier,Identifiable} rename

We hare renamed classes here, adjust to those changes.

Change-Id: I5efe2eeeb2878dfac864bc6ebc3e08c98ace253a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoAdjust for DataTreeCandidateNode API change 08/106608/1
Robert Varga [Wed, 21 Jun 2023 18:57:38 +0000 (20:57 +0200)]
Adjust for DataTreeCandidateNode API change

The return types have changed, adjust to that.

Change-Id: I5c51659e9c0d30ff90cbfff7772d348af301f4f9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump akka to 2.6.21 92/106592/1
Robert Varga [Wed, 21 Jun 2023 12:47:27 +0000 (14:47 +0200)]
Bump akka to 2.6.21

https://github.com/akka/akka/releases/tag/v2.6.21

Change-Id: I79d5d143ac6e8e35661568c439fa07acdf34f64b
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up sal-clustering-commons dependencies 58/106558/1
Robert Varga [Tue, 20 Jun 2023 16:52:22 +0000 (18:52 +0200)]
Clean up sal-clustering-commons dependencies

We have a ton of warnings, clean them up as much as possible.

Change-Id: I02f5a3049f6c97c4236847c395c99b6fd2380a88
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up sal-akka-segmented-journal dependencies 57/106557/1
Robert Varga [Tue, 20 Jun 2023 16:43:03 +0000 (18:43 +0200)]
Clean up sal-akka-segmented-journal dependencies

We have quite a few reports here, clean them up to a reasonable extent.

Change-Id: I81e063f349b942d311d96c384a37ba8b812ffd46
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up cds-access-api dependencies 56/106556/1
Robert Varga [Tue, 20 Jun 2023 16:39:43 +0000 (18:39 +0200)]
Clean up cds-access-api dependencies

We have some missing dependency declarations, fill them out.

Change-Id: Ie79414dd25a6e83d81b097c0909d43abd5ee889c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoClean up dependencies 52/106552/1
Robert Varga [Tue, 20 Jun 2023 11:49:31 +0000 (13:49 +0200)]
Clean up dependencies

We have a ton of warnings about used/undeclared dependencies. Clean
these up.

Change-Id: I7a434a150ea62f7fc1ff93b34d48a98e24e79274
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump upstreams 06/106506/10
Robert Varga [Sun, 18 Jun 2023 11:04:24 +0000 (13:04 +0200)]
Bump upstreams

Adopt:
- odlparent-13.0.1
- yangtools-11.0.0-SNAPSHOT
- mdsal-12-0.0-SNAPSHOT

Since the format of NormalizedNode tree is updated to not include
AugmentationNode (and AugmentationIdentifier), we must force an
incompatible update, as we do not have enough information to produce
compatible payload.

Change-Id: Ibf444540ed052b49651ba66ca7b93c806a6c8a97
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoSprinkle java.io.Serial 28/106528/1
Robert Varga [Sun, 18 Jun 2023 20:46:51 +0000 (22:46 +0200)]
Sprinkle java.io.Serial

Add annotations to make sure the API is covered.

Change-Id: I5fb74fcc6b37386a029e69cd79d6e1978601637a
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump Scala to 2.13.11 03/105903/3
Robert Varga [Thu, 8 Jun 2023 06:50:46 +0000 (08:50 +0200)]
Bump Scala to 2.13.11

https://github.com/scala/scala/releases/tag/v2.13.11

Change-Id: I9bc86788da00c1d46eadb298db1c55fe19bbca5f
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
16 months agoBump upstreams 12/106412/1
Robert Varga [Thu, 8 Jun 2023 09:04:34 +0000 (11:04 +0200)]
Bump upstreams

Adopt:
- yangtools-10.0.8
- mdsal-11.0.11

Change-Id: I3ac1bd9d896b74045605dffd84a9acda4521aeb9
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
17 months agoBump upstreams 89/106189/2
Robert Varga [Sun, 28 May 2023 12:30:45 +0000 (14:30 +0200)]
Bump upstreams

Adopt:
- odlparent-12.0.6
- yangtools-10.0.7
- mdsal-11.0.10

Change-Id: I657abce9fc4bfdbc16da78b5562d4e7f2cdbb42c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
17 months agoRemove EmptyExternalizableProxy 72/105172/8
Robert Varga [Mon, 3 Apr 2023 14:19:26 +0000 (16:19 +0200)]
Remove EmptyExternalizableProxy

EmptyExternalizableProxy is a rather inefficient way of doing things,
remove it along with its (unused) users.

JIRA: CONTROLLER-2079
Change-Id: I87179e1e8b53547711b4d0c8ceb4607f341c997d
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>