From b24ac05920097fd7047f47094deb319bfe7e4906 Mon Sep 17 00:00:00 2001 From: huangsimin Date: Thu, 21 Jul 2022 15:48:59 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=20raft=E5=A4=84=E7=90=86?= =?UTF-8?q?=E7=9A=84=E6=B3=A8=E8=A7=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 13 +-- .../dataflow/controller/PacketsProcessor.java | 59 ++++++++++++++ .../dataflow/grpc/CollectPackets.java | 2 +- .../master/{Header.java => Master.java} | 2 +- .../dataflow/statemachine/StateMachine.java | 23 +----- .../statemachine/StateServerFactory.java | 25 ++++-- .../statemachine/rpc/RequestCondition.java | 21 ----- .../statemachine/rpc/RequestState.java | 35 -------- .../rpc/SyncConditionProcessor.java | 18 ++++- .../statemachine/rpc/SyncStateProcessor.java | 26 +++++- .../rpc/annotations/ProcessorRaft.java | 24 ++++++ .../statemachine/state/StateFactory.java | 80 +++++++++++++------ src/main/resources/logback.xml | 4 +- 13 files changed, 212 insertions(+), 120 deletions(-) create mode 100644 src/main/java/com/yuandian/dataflow/controller/PacketsProcessor.java rename src/main/java/com/yuandian/dataflow/master/{Header.java => Master.java} (99%) delete mode 100644 src/main/java/com/yuandian/dataflow/statemachine/rpc/RequestCondition.java delete mode 100644 src/main/java/com/yuandian/dataflow/statemachine/rpc/RequestState.java create mode 100644 src/main/java/com/yuandian/dataflow/statemachine/rpc/annotations/ProcessorRaft.java diff --git a/pom.xml b/pom.xml index c0e9190..6aa74f6 100644 --- a/pom.xml +++ b/pom.xml @@ -89,8 +89,13 @@ ${mongo.driver.version} - - + + + org.reflections + reflections + 0.10.2 + +