Skip to content

Commit

Permalink
chore: apply suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
WenyXu committed Sep 16, 2023
1 parent 7c373bb commit ef3e27e
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/datanode/src/datanode.rs
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ impl DatanodeBuilder {

// build and initialize region server
let log_store = Self::build_log_store(&self.opts).await?;
let (tx, region_event_receiver) = match mode {
let (region_event_listener, region_event_receiver) = match mode {
Mode::Distributed => {
let (tx, rx) = new_region_server_event_channel();
(Box::new(tx) as RegionServerEventListenerRef, Some(rx))
Expand All @@ -203,8 +203,13 @@ impl DatanodeBuilder {
),
};

let region_server =
Self::new_region_server(&self.opts, self.plugins.clone(), log_store, tx).await?;
let region_server = Self::new_region_server(
&self.opts,
self.plugins.clone(),
log_store,
region_event_listener,
)
.await?;
self.initialize_region_server(&region_server, kv_backend, matches!(mode, Mode::Standalone))
.await?;

Expand Down

0 comments on commit ef3e27e

Please sign in to comment.