Skip to content

deleted

68fc941
Select commit
Loading
Failed to load commit list.
Open

feat: Raft-based High Availability using Apache Ratis #3731

deleted
68fc941
Select commit
Loading
Failed to load commit list.
Codacy Production / Codacy Static Code Analysis required action Apr 16, 2026 in 0s

32 new issues (0 max.) of at least severity.

Codacy Here is an overview of what got changed by this pull request:

Issues
======
- Added 32
           

Complexity increasing per file
==============================
- network/src/main/java/com/arcadedb/network/binary/QuorumNotReachedException.java  1
- engine/src/main/java/com/arcadedb/engine/TransactionManager.java  2
- server/src/main/java/com/arcadedb/server/ArcadeDBServer.java  6
- server/src/main/java/com/arcadedb/server/http/handler/DatabaseAbstractHandler.java  12
- engine/src/main/java/com/arcadedb/GlobalConfiguration.java  3
- network/src/main/java/com/arcadedb/remote/RemoteDatabase.java  10
- server/src/main/java/com/arcadedb/server/http/handler/PostServerCommandHandler.java  32
- server/src/main/java/com/arcadedb/server/http/handler/AbstractServerHttpHandler.java  18
- network/src/main/java/com/arcadedb/remote/RemoteHttpComponent.java  12
- server/src/main/java/com/arcadedb/server/plugin/PluginManager.java  6
- load-tests/src/test/java/com/arcadedb/test/support/ContainersTestTemplate.java  45
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java  105
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftLogEntryCodec.java  44
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java  93
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftLogEntryType.java  5
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAServer.java  138
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/SnapshotManager.java  12
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java  62
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/ClusterMonitor.java  12
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/GetClusterHandler.java  8
- ha-raft/src/test/java/com/arcadedb/server/ha/raft/RaftHAInsertBenchmark.java  57
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/Quorum.java  3
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftGroupCommitter.java  40
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/SnapshotHttpHandler.java  49
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/HALog.java  9
- server/src/main/java/com/arcadedb/server/HAReplicatedDatabase.java  5
- server/src/main/java/com/arcadedb/server/network/DefaultServerSocketFactory.java  1
- server/src/main/java/com/arcadedb/server/HAServerPlugin.java  13
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostStepDownHandler.java  3
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostTransferLeaderHandler.java  6
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/DeletePeerHandler.java  5
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostLeaveHandler.java  3
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostAddPeerHandler.java  7
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostVerifyDatabaseHandler.java  21
- server/src/main/java/com/arcadedb/server/http/handler/LeaderProxy.java  27
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java  11
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/ReplicationException.java  2
- ha-raft/src/test/java/com/arcadedb/server/ha/raft/RaftClusterStarter.java  17
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/KubernetesAutoJoin.java  21
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftPeerAddressResolver.java  25
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/SnapshotInstaller.java  64
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/MajorityCommittedAllFailedException.java  2
- engine/src/main/java/com/arcadedb/exception/WALVersionGapException.java  1
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterManager.java  42
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftPropertiesBuilder.java  2
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/ClusterTokenProvider.java  28
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterStatusExporter.java  36
- ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftTransactionBroker.java  8
- ha-raft/src/test/java/com/arcadedb/server/ha/raft/ClusterDatabaseChecker.java  1
         

See the complete overview on Codacy

Annotations

Check notice on line 46 in engine/src/main/java/com/arcadedb/database/Database.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

engine/src/main/java/com/arcadedb/database/Database.java#L46

The enum name 'READ_CONSISTENCY' doesn't match '[A-Z][a-zA-Z0-9]*'

Check warning on line 278 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L278

An instanceof check is being performed on the caught exception.  Create a separate catch clause for this exception type.

Check warning on line 376 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L376

Avoid throwing raw exception types.

Check warning on line 399 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L399

Avoid throwing raw exception types.

Check warning on line 432 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L432

Avoid unused method parameters such as 'entryIndex'.

Check warning on line 489 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L489

Avoid unused method parameters such as 'entryIndex'.

Check warning on line 525 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L525

Avoid throwing raw exception types.

Check warning on line 600 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ArcadeStateMachine.java#L600

Avoid throwing raw exception types.

Check warning on line 163 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/ClusterTokenProvider.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/ClusterTokenProvider.java#L163

Avoid throwing raw exception types.

Check notice on line 47 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java#L47

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check notice on line 48 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java#L48

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check notice on line 49 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/HealthMonitor.java#L49

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check warning on line 84 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostVerifyDatabaseHandler.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/PostVerifyDatabaseHandler.java#L84

Avoid throwing raw exception types.

Check warning on line 41 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterStatusExporter.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterStatusExporter.java#L41

Avoid unused private fields such as 'LAG_MONITOR_INITIAL_DELAY_SECS'.

Check warning on line 42 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterStatusExporter.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftClusterStatusExporter.java#L42

Avoid unused private fields such as 'LAG_MONITOR_INTERVAL_SECS'.

Check warning on line 81 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java#L81

Avoid throwing raw exception types.

Check warning on line 188 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java#L188

Avoid throwing raw exception types.

Check notice on line 215 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java#L215

Unnecessary use of fully qualified name 'java.io.IOException' due to existing import 'java.io.IOException'

Check warning on line 216 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java#L216

Avoid throwing raw exception types.

Check warning on line 269 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftHAPlugin.java#L269

Avoid throwing raw exception types.

Check notice on line 158 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java#L158

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check notice on line 159 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java#L159

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check notice on line 160 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java#L160

Fields should be declared at the top of the class, before any method declarations, constructors, initializers or inner classes.

Check warning on line 304 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java#L304

An instanceof check is being performed on the caught exception.  Create a separate catch clause for this exception type.

Check warning on line 813 in ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java

See this annotation in the file changed.

@codacy-production codacy-production / Codacy Static Code Analysis

ha-raft/src/main/java/com/arcadedb/server/ha/raft/RaftReplicatedDatabase.java#L813

Avoid long parameter lists.