Skip to content

Commit

Permalink
Update database_args.rs to enable nfs support with flag
Browse files Browse the repository at this point in the history
the purpose of this is to further extend paradigmxyz#6755 and allow for `--db.exclusive=true` to be used to support nfs volumes
  • Loading branch information
argakiig committed Mar 26, 2024
1 parent 4d798c7 commit 48caf1c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions crates/node-core/src/args/database_args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,17 @@ pub struct DatabaseArgs {
/// Database logging level. Levels higher than "notice" require a debug build.
#[arg(long = "db.log-level", value_enum)]
pub log_level: Option<LogLevel>,
/// Open environment in exclusive/monopolistic mode. Enabling allows nfs volumes
#[arg(long = "db.exclusive", exclusive = false)]
pub exclusive: Option<bool>
}

impl DatabaseArgs {
/// Returns default database arguments with configured log level and client version.
pub fn database_args(&self) -> reth_db::mdbx::DatabaseArguments {
reth_db::mdbx::DatabaseArguments::new(default_client_version())
.with_log_level(self.log_level)
.with_exclusive(self.exclusive)
}
}

Expand Down

0 comments on commit 48caf1c

Please sign in to comment.