Skip to content

Commit

Permalink
Merge branch 'dev' into deniallugo-refactor-eth-watcher
Browse files Browse the repository at this point in the history
  • Loading branch information
Deniallugo committed Jan 26, 2022
2 parents ae70942 + 5d02d65 commit a9d8555
Show file tree
Hide file tree
Showing 10 changed files with 428 additions and 175 deletions.
15 changes: 15 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ members = [
"core/bin/parse_pub_data",
"core/bin/block_revert",
"core/bin/remove_proofs",

"core/bin/remove_outstanding_tx_filters",
# Server micro-services
"core/bin/zksync_api",
"core/bin/zksync_core",
Expand Down
26 changes: 26 additions & 0 deletions core/bin/remove_outstanding_tx_filters/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[package]
name = "remove_outstanding_tx_filters"
version = "0.1.0"
edition = "2021"
authors = ["The Matter Labs Team <[email protected]>"]
homepage = "https://zksync.io/"
repository = "https://github.com/matter-labs/zksync"
license = "Apache-2.0"
keywords = ["blockchain", "zksync"]
categories = ["cryptography"]
publish = false # We don't want to publish our binaries.

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

# TODO remove it ZKS-931
[dependencies]
zksync_types = { path = "../../lib/types", version = "1.0" }
zksync_storage = { path = "../../lib/storage", version = "1.0" }
zksync_eth_client = { path = "../../lib/eth_client", version = "1.0" }
zksync_config = { path = "../../lib/config", version = "1.0" }

tokio = { version = "1", features = ["full"] }
ethabi = "14.0.0"
anyhow = "1.0"
web3 = "0.16.0"
structopt = "0.3.20"
12 changes: 12 additions & 0 deletions core/bin/remove_outstanding_tx_filters/src/main.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
use zksync_storage::StorageProcessor;

#[tokio::main]
async fn main() -> anyhow::Result<()> {
let mut storage = StorageProcessor::establish_connection().await?;
storage
.chain()
.operations_schema()
.remove_outstanding_tx_filters()
.await?;
Ok(())
}
2 changes: 1 addition & 1 deletion core/bin/zksync_core/src/mempool/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,7 @@ impl MempoolTransactionsHandler {
resp.send(tx_add_result).unwrap_or_default();
}
MempoolTransactionRequest::NewPriorityOps(ops, confirmed, resp) => {
let tx_add_result = self.add_priority_op(ops, confirmed).await;
let tx_add_result = self.add_priority_ops(ops, confirmed).await;
resp.send(tx_add_result).unwrap_or_default();
}
}
Expand Down
2 changes: 1 addition & 1 deletion core/lib/config/src/configs/database.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ impl DBConfig {
}

pub fn rejected_transactions_cleaner_interval(&self) -> time::Duration {
time::Duration::from_secs(self.rejected_transactions_cleaner_interval * Self::SECS_PER_HOUR)
time::Duration::from_secs(self.rejected_transactions_cleaner_interval)
}
}

Expand Down
Loading

0 comments on commit a9d8555

Please sign in to comment.