From 2ca643ea07ef95eb584d334d0892db1b45aa0687 Mon Sep 17 00:00:00 2001 From: larry-aptos <112209412+larry-aptos@users.noreply.github.com> Date: Thu, 19 Sep 2024 00:11:30 -0700 Subject: [PATCH] update the localnet to use the latest processors. (#14682) --- Cargo.lock | 288 ++++++++++++++---- Cargo.toml | 4 +- crates/aptos-metrics-core/src/const_metric.rs | 6 +- crates/aptos/Cargo.toml | 4 +- .../node/local_testnet/hasura_metadata.json | 114 ++++--- .../src/node/local_testnet/processors.rs | 12 + 6 files changed, 328 insertions(+), 100 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 413ce73564963..38453e24301a5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -244,9 +244,9 @@ checksum = "34fde25430d87a9388dadbe6e34d7f72a462c8b43ac8d309b42b0a8505d7e2a5" [[package]] name = "anyhow" -version = "1.0.79" +version = "1.0.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca" +checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6" dependencies = [ "backtrace", ] @@ -919,7 +919,7 @@ dependencies = [ "maplit", "mini-moka", "mirai-annotations", - "mockall", + "mockall 0.11.4", "move-core-types", "num-derive", "num-traits", @@ -1099,7 +1099,7 @@ dependencies = [ "futures", "itertools 0.13.0", "maplit", - "mockall", + "mockall 0.11.4", "ordered-float 3.9.2", "rand 0.8.5", "serde", @@ -2281,6 +2281,38 @@ dependencies = [ "url", ] +[[package]] +name = "aptos-indexer-processor-sdk" +version = "0.1.0" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d#9ecd252ccff53023664562001dd04c2886488c0d" +dependencies = [ + "anyhow", + "aptos-indexer-transaction-stream", + "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=5c48aee129b5a141be2792ffa3d9bd0a1a61c9cb)", + "async-trait", + "bcs 0.1.4", + "bigdecimal", + "chrono", + "derive_builder", + "futures", + "hex", + "instrumented-channel", + "kanal", + "mockall 0.12.1", + "num_cpus", + "once_cell", + "petgraph 0.6.5", + "prometheus", + "prometheus-client", + "serde", + "serde_json", + "thiserror", + "tiny-keccak", + "tokio", + "tracing", + "url", +] + [[package]] name = "aptos-indexer-test-transactions" version = "1.0.0" @@ -2309,6 +2341,27 @@ dependencies = [ "url", ] +[[package]] +name = "aptos-indexer-transaction-stream" +version = "0.1.0" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d#9ecd252ccff53023664562001dd04c2886488c0d" +dependencies = [ + "anyhow", + "aptos-moving-average 0.1.0 (git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d)", + "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=5c48aee129b5a141be2792ffa3d9bd0a1a61c9cb)", + "chrono", + "futures-util", + "once_cell", + "prometheus", + "prost 0.12.3", + "sample", + "serde", + "tokio", + "tonic 0.11.0", + "tracing", + "url", +] + [[package]] name = "aptos-infallible" version = "0.1.0" @@ -2815,7 +2868,15 @@ dependencies = [ [[package]] name = "aptos-moving-average" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=fa1ce4947f4c2be57529f1c9732529e05a06cb7f#fa1ce4947f4c2be57529f1c9732529e05a06cb7f" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d#9ecd252ccff53023664562001dd04c2886488c0d" +dependencies = [ + "chrono", +] + +[[package]] +name = "aptos-moving-average" +version = "0.1.0" +source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=e294b558b33619bba92e205cb74c581488bcb2a3#e294b558b33619bba92e205cb74c581488bcb2a3" dependencies = [ "chrono", ] @@ -3263,7 +3324,7 @@ dependencies = [ "claims", "futures", "maplit", - "mockall", + "mockall 0.11.4", "once_cell", "rand 0.7.3", "serde", @@ -3297,7 +3358,7 @@ dependencies = [ [[package]] name = "aptos-profiler" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-core.git?rev=4541add3fd29826ec57f22658ca286d2d6134b93#4541add3fd29826ec57f22658ca286d2d6134b93" +source = "git+https://github.com/aptos-labs/aptos-core.git?rev=202bdccff2b2d333a385ae86a4fcf23e89da9f62#202bdccff2b2d333a385ae86a4fcf23e89da9f62" dependencies = [ "anyhow", "backtrace", @@ -3762,7 +3823,7 @@ dependencies = [ "bcs 0.1.4", "claims", "futures", - "mockall", + "mockall 0.11.4", "move-core-types", "ntest", "once_cell", @@ -3851,7 +3912,7 @@ dependencies = [ "futures", "maplit", "mini-moka", - "mockall", + "mockall 0.11.4", "once_cell", "rand 0.7.3", "serde", @@ -3899,10 +3960,10 @@ dependencies = [ [[package]] name = "aptos-system-utils" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-core.git?rev=4541add3fd29826ec57f22658ca286d2d6134b93#4541add3fd29826ec57f22658ca286d2d6134b93" +source = "git+https://github.com/aptos-labs/aptos-core.git?rev=202bdccff2b2d333a385ae86a4fcf23e89da9f62#202bdccff2b2d333a385ae86a4fcf23e89da9f62" dependencies = [ "anyhow", - "aptos-profiler 0.1.0 (git+https://github.com/aptos-labs/aptos-core.git?rev=4541add3fd29826ec57f22658ca286d2d6134b93)", + "aptos-profiler 0.1.0 (git+https://github.com/aptos-labs/aptos-core.git?rev=202bdccff2b2d333a385ae86a4fcf23e89da9f62)", "async-mutex", "http 0.2.11", "hyper 0.14.28", @@ -5052,9 +5113,9 @@ checksum = "fbb36e985947064623dbd357f727af08ffd077f93d696782f3c56365fa2e2799" [[package]] name = "async-trait" -version = "0.1.77" +version = "0.1.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" +checksum = "a27b8a3a6e1a44fa4c8baf1f653e4172e81486d4941f2237e20dc2d0cf4ddff1" dependencies = [ "proc-macro2", "quote", @@ -5723,7 +5784,7 @@ dependencies = [ "move-binary-format", "move-bytecode-verifier", "move-core-types", - "petgraph 0.5.1", + "petgraph 0.6.5", "proptest", ] @@ -6606,7 +6667,7 @@ dependencies = [ "bitflags 1.3.2", "crossterm_winapi", "libc", - "mio", + "mio 0.8.11", "parking_lot 0.12.1", "signal-hook", "signal-hook-mio", @@ -6622,7 +6683,7 @@ dependencies = [ "bitflags 1.3.2", "crossterm_winapi", "libc", - "mio", + "mio 0.8.11", "parking_lot 0.12.1", "signal-hook", "signal-hook-mio", @@ -6983,6 +7044,17 @@ dependencies = [ "uuid", ] +[[package]] +name = "delegate" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e018fccbeeb50ff26562ece792ed06659b9c2dae79ece77c4456bb10d9bf79b" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "der" version = "0.5.1" @@ -7098,7 +7170,7 @@ dependencies = [ "guppy", "guppy-workspace-hack", "once_cell", - "petgraph 0.6.4", + "petgraph 0.6.5", "rayon", "serde", "toml 0.5.11", @@ -7302,6 +7374,12 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1435fa1053d8b2fbbe9be7e97eca7f33d37b28409959813daefc1446a14247f1" +[[package]] +name = "dtoa" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcbb2bf8e87535c23f7a8a321e364ce21462d0ff10cb6407820e8e96dfff6653" + [[package]] name = "dunce" version = "1.0.4" @@ -8703,7 +8781,7 @@ dependencies = [ "nested", "once_cell", "pathdiff", - "petgraph 0.6.4", + "petgraph 0.6.5", "rayon", "semver", "serde", @@ -8939,9 +9017,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.3.3" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -9623,6 +9701,19 @@ dependencies = [ "web-sys", ] +[[package]] +name = "instrumented-channel" +version = "0.1.0" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d#9ecd252ccff53023664562001dd04c2886488c0d" +dependencies = [ + "delegate", + "derive_builder", + "kanal", + "once_cell", + "prometheus", + "prometheus-client", +] + [[package]] name = "integer-encoding" version = "3.0.4" @@ -9657,7 +9748,7 @@ version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ - "hermit-abi 0.3.3", + "hermit-abi 0.3.9", "libc", "windows-sys 0.48.0", ] @@ -9683,7 +9774,7 @@ version = "0.4.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0bad00257d07be169d870ab665980b06cdb366d792ad690bf2e76876dc503455" dependencies = [ - "hermit-abi 0.3.3", + "hermit-abi 0.3.9", "rustix 0.38.28", "windows-sys 0.52.0", ] @@ -10022,7 +10113,7 @@ dependencies = [ "is-terminal", "itertools 0.10.5", "lalrpop-util", - "petgraph 0.6.4", + "petgraph 0.6.5", "regex", "regex-syntax 0.6.29", "string_cache", @@ -10568,6 +10659,18 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "mio" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" +dependencies = [ + "hermit-abi 0.3.9", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.52.0", +] + [[package]] name = "mirai-annotations" version = "1.12.0" @@ -10584,8 +10687,23 @@ dependencies = [ "downcast", "fragile", "lazy_static", - "mockall_derive", - "predicates", + "mockall_derive 0.11.4", + "predicates 2.1.5", + "predicates-tree", +] + +[[package]] +name = "mockall" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43766c2b5203b10de348ffe19f7e54564b64f3d6018ff7648d1e2d6d3a0f0a48" +dependencies = [ + "cfg-if", + "downcast", + "fragile", + "lazy_static", + "mockall_derive 0.12.1", + "predicates 3.1.2", "predicates-tree", ] @@ -10601,6 +10719,18 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "mockall_derive" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af7cbce79ec385a1d4f54baa90a76401eb15d9cab93685f62e7e9f942aa00ae2" +dependencies = [ + "cfg-if", + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "module-generation" version = "0.1.0" @@ -10727,7 +10857,7 @@ dependencies = [ "anyhow", "move-binary-format", "move-core-types", - "petgraph 0.5.1", + "petgraph 0.6.5", "serde-reflection", ] @@ -10741,7 +10871,7 @@ dependencies = [ "move-binary-format", "move-borrow-graph", "move-core-types", - "petgraph 0.5.1", + "petgraph 0.6.5", "serde", "typed-arena", ] @@ -10829,7 +10959,7 @@ dependencies = [ "move-symbol-pool", "once_cell", "pathdiff", - "petgraph 0.5.1", + "petgraph 0.6.5", "regex", "sha3 0.9.1", "tempfile", @@ -10874,7 +11004,7 @@ dependencies = [ "move-symbol-pool", "num 0.4.1", "once_cell", - "petgraph 0.5.1", + "petgraph 0.6.5", "strum 0.24.1", "strum_macros 0.24.3", "walkdir", @@ -10934,7 +11064,7 @@ dependencies = [ "move-command-line-common", "move-core-types", "move-ir-types", - "petgraph 0.5.1", + "petgraph 0.6.5", "serde", ] @@ -11134,7 +11264,7 @@ dependencies = [ "move-to-yul", "named-lock", "once_cell", - "petgraph 0.5.1", + "petgraph 0.6.5", "regex", "serde", "serde_yaml 0.8.26", @@ -11266,7 +11396,7 @@ dependencies = [ "move-stackless-bytecode-test-utils", "num 0.4.1", "paste", - "petgraph 0.5.1", + "petgraph 0.6.5", ] [[package]] @@ -11734,9 +11864,9 @@ dependencies = [ [[package]] name = "ntest" -version = "0.9.0" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da8ec6d2b73d45307e926f5af46809768581044384637af6b3f3fe7c3c88f512" +checksum = "fb183f0a1da7a937f672e5ee7b7edb727bf52b8a52d531374ba8ebb9345c0330" dependencies = [ "ntest_test_cases", "ntest_timeout", @@ -11744,9 +11874,9 @@ dependencies = [ [[package]] name = "ntest_test_cases" -version = "0.9.0" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be7d33be719c6f4d09e64e27c1ef4e73485dc4cc1f4d22201f89860a7fe22e22" +checksum = "16d0d3f2a488592e5368ebbe996e7f1d44aa13156efad201f5b4d84e150eaa93" dependencies = [ "proc-macro2", "quote", @@ -11755,11 +11885,11 @@ dependencies = [ [[package]] name = "ntest_timeout" -version = "0.9.0" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "066b468120587a402f0b47d8f80035c921f6a46f8209efd0632a89a16f5188a4" +checksum = "fcc7c92f190c97f79b4a332f5e81dcf68c8420af2045c936c9be0bc9de6f63b5" dependencies = [ - "proc-macro-crate 1.3.1", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", "syn 1.0.109", @@ -11974,7 +12104,7 @@ version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi 0.3.3", + "hermit-abi 0.3.9", "libc", ] @@ -12329,7 +12459,7 @@ dependencies = [ "async-trait", "coset", "log", - "mockall", + "mockall 0.11.4", "p256", "passkey-types", "rand 0.8.5", @@ -12544,9 +12674,9 @@ dependencies = [ [[package]] name = "petgraph" -version = "0.6.4" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1d3afd2628e69da2be385eb6f2fd57c8ac7977ceeff6dc166ff1657b0e386a9" +checksum = "b4c5cc86750666a3ed20bdaf5ca2a0344f9c67674cae0515bec2da16fbaa47db" dependencies = [ "fixedbitset 0.4.2", "indexmap 2.2.5", @@ -13038,6 +13168,16 @@ dependencies = [ "regex", ] +[[package]] +name = "predicates" +version = "3.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e9086cc7640c29a356d1a29fd134380bee9d8f79a17410aa76e7ad295f42c97" +dependencies = [ + "anstyle", + "predicates-core", +] + [[package]] name = "predicates-core" version = "1.0.6" @@ -13212,13 +13352,14 @@ dependencies = [ [[package]] name = "processor" version = "1.0.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=fa1ce4947f4c2be57529f1c9732529e05a06cb7f#fa1ce4947f4c2be57529f1c9732529e05a06cb7f" +source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=e294b558b33619bba92e205cb74c581488bcb2a3#e294b558b33619bba92e205cb74c581488bcb2a3" dependencies = [ "ahash 0.8.11", "allocative", "allocative_derive", "anyhow", - "aptos-moving-average 0.1.0 (git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=fa1ce4947f4c2be57529f1c9732529e05a06cb7f)", + "aptos-indexer-processor-sdk", + "aptos-moving-average 0.1.0 (git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=e294b558b33619bba92e205cb74c581488bcb2a3)", "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=5c48aee129b5a141be2792ffa3d9bd0a1a61c9cb)", "async-trait", "bcs 0.1.4", @@ -13252,12 +13393,13 @@ dependencies = [ "postgres-native-tls", "prometheus", "prost 0.12.3", + "rayon", "regex", "serde", "serde_json", "server-framework", - "sha2 0.9.9", - "sha3 0.9.1", + "sha2 0.10.8", + "sha3 0.10.8", "strum 0.24.1", "tiny-keccak", "tokio", @@ -13300,9 +13442,33 @@ dependencies = [ "lazy_static", "memchr", "parking_lot 0.12.1", + "protobuf", "thiserror", ] +[[package]] +name = "prometheus-client" +version = "0.22.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "504ee9ff529add891127c4827eb481bd69dc0ebc72e9a682e187db4caa60c3ca" +dependencies = [ + "dtoa", + "itoa", + "parking_lot 0.12.1", + "prometheus-client-derive-encode", +] + +[[package]] +name = "prometheus-client-derive-encode" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "prometheus-http-query" version = "0.5.2" @@ -14559,6 +14725,11 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "sample" +version = "0.1.0" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=9ecd252ccff53023664562001dd04c2886488c0d#9ecd252ccff53023664562001dd04c2886488c0d" + [[package]] name = "scale-info" version = "1.0.0" @@ -14985,10 +15156,10 @@ dependencies = [ [[package]] name = "server-framework" version = "1.0.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=fa1ce4947f4c2be57529f1c9732529e05a06cb7f#fa1ce4947f4c2be57529f1c9732529e05a06cb7f" +source = "git+https://github.com/aptos-labs/aptos-indexer-processors.git?rev=e294b558b33619bba92e205cb74c581488bcb2a3#e294b558b33619bba92e205cb74c581488bcb2a3" dependencies = [ "anyhow", - "aptos-system-utils 0.1.0 (git+https://github.com/aptos-labs/aptos-core.git?rev=4541add3fd29826ec57f22658ca286d2d6134b93)", + "aptos-system-utils 0.1.0 (git+https://github.com/aptos-labs/aptos-core.git?rev=202bdccff2b2d333a385ae86a4fcf23e89da9f62)", "async-trait", "backtrace", "clap 4.4.14", @@ -15143,7 +15314,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "29ad2e15f37ec9a6cc544097b78a1ec90001e9f71b81338ca39f430adaca99af" dependencies = [ "libc", - "mio", + "mio 0.8.11", "signal-hook", ] @@ -16125,22 +16296,21 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.35.1" +version = "1.40.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" +checksum = "e2b070231665d27ad9ec9b8df639893f46727666c6767db40317fbe920a5d998" dependencies = [ "backtrace", "bytes", "libc", - "mio", - "num_cpus", + "mio 1.0.2", "parking_lot 0.12.1", "pin-project-lite", "signal-hook-registry", "socket2 0.5.5", "tokio-macros", "tracing", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -16155,9 +16325,9 @@ dependencies = [ [[package]] name = "tokio-macros" -version = "2.2.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" +checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", @@ -17022,9 +17192,9 @@ dependencies = [ [[package]] name = "url" -version = "2.5.0" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", "idna 0.5.0", diff --git a/Cargo.toml b/Cargo.toml index 01669e6418f3f..f58a1e238a281 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -641,7 +641,7 @@ more-asserts = "0.3.0" named-lock = "0.2.0" native-tls = "0.2.10" neptune = { version = "13.0.0", default_features = false } -ntest = "0.9.0" +ntest = "0.9.3" num = "0.4.0" num-bigint = { version = "0.3.2", features = ["rand"] } num_cpus = "1.13.1" @@ -666,7 +666,7 @@ passkey-client = { version = "0.2.0" } passkey-types = { version = "0.2.0" } pbjson = "0.5.1" percent-encoding = "2.1.0" -petgraph = "0.5.1" +petgraph = "0.6.5" pin-project = "1.0.10" plotters = { version = "0.3.5", default-features = false } # We're using git deps until https://github.com/poem-web/poem/pull/829 gets formally released. diff --git a/crates/aptos-metrics-core/src/const_metric.rs b/crates/aptos-metrics-core/src/const_metric.rs index c354b0eed4921..744ff1b7c989c 100644 --- a/crates/aptos-metrics-core/src/const_metric.rs +++ b/crates/aptos-metrics-core/src/const_metric.rs @@ -37,7 +37,7 @@ impl ConstMetric { let mut metric = Metric::default(); metric.set_counter(counter); - metric.set_label(labels); + metric.set_label(labels.into()); Ok(ConstMetric { desc, @@ -63,7 +63,7 @@ impl ConstMetric { let mut metric = Metric::default(); metric.set_gauge(guage); - metric.set_label(labels); + metric.set_label(labels.into()); Ok(ConstMetric { desc, @@ -84,7 +84,7 @@ impl Collector for ConstMetric { met.set_name(self.desc.fq_name.clone()); met.set_help(self.desc.help.clone()); met.set_field_type(self.metric_type); - met.set_metric(vec![self.metric.clone()]); + met.set_metric(vec![self.metric.clone()].into()); vec![met] } diff --git a/crates/aptos/Cargo.toml b/crates/aptos/Cargo.toml index b1270bc827272..dfd5207b34f5d 100644 --- a/crates/aptos/Cargo.toml +++ b/crates/aptos/Cargo.toml @@ -85,7 +85,7 @@ pathsearch = { workspace = true } poem = { workspace = true } # We set default-features to false so we don't onboard the libpq dep. See more here: # https://github.com/aptos-labs/aptos-core/pull/12568 -processor = { git = "https://github.com/aptos-labs/aptos-indexer-processors.git", rev = "fa1ce4947f4c2be57529f1c9732529e05a06cb7f", default-features = false } +processor = { git = "https://github.com/aptos-labs/aptos-indexer-processors.git", rev = "e294b558b33619bba92e205cb74c581488bcb2a3", default-features = false } rand = { workspace = true } regex = { workspace = true } reqwest = { workspace = true } @@ -93,7 +93,7 @@ self_update = { git = "https://github.com/banool/self_update.git", rev = "830615 serde = { workspace = true } serde_json = { workspace = true } serde_yaml = { workspace = true } -server-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processors.git", rev = "fa1ce4947f4c2be57529f1c9732529e05a06cb7f" } +server-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processors.git", rev = "e294b558b33619bba92e205cb74c581488bcb2a3" } tempfile = { workspace = true } thiserror = { workspace = true } tokio = { workspace = true } diff --git a/crates/aptos/src/node/local_testnet/hasura_metadata.json b/crates/aptos/src/node/local_testnet/hasura_metadata.json index 7a4906b33ecd4..d5f1a87a594c9 100644 --- a/crates/aptos/src/node/local_testnet/hasura_metadata.json +++ b/crates/aptos/src/node/local_testnet/hasura_metadata.json @@ -1,5 +1,5 @@ { - "resource_version": 11, + "resource_version": 38, "metadata": { "version": 3, "sources": [ @@ -1225,6 +1225,7 @@ "columns": [ "collection_id", "collection_name", + "collection_properties", "creator_address", "current_supply", "description", @@ -1349,6 +1350,59 @@ } ] }, + { + "table": { + "name": "current_fungible_asset_balances", + "schema": "public" + }, + "object_relationships": [ + { + "name": "metadata", + "using": { + "manual_configuration": { + "column_mapping": { + "asset_type": "asset_type" + }, + "insertion_order": null, + "remote_table": { + "name": "fungible_asset_metadata", + "schema": "public" + } + } + } + } + ], + "select_permissions": [ + { + "role": "anonymous", + "permission": { + "columns": [ + "amount", + "amount_v1", + "amount_v2", + "asset_type", + "asset_type_v1", + "asset_type_v2", + "is_frozen", + "is_primary", + "last_transaction_timestamp", + "last_transaction_timestamp_v1", + "last_transaction_timestamp_v2", + "last_transaction_version", + "last_transaction_version_v1", + "last_transaction_version_v2", + "owner_address", + "storage_id", + "token_standard" + ], + "filter": {}, + "limit": 100, + "allow_aggregations": true + }, + "comment": "" + } + ] + }, { "table": { "name": "current_objects", @@ -1485,6 +1539,21 @@ } } } + }, + { + "name": "current_royalty_v1", + "using": { + "manual_configuration": { + "column_mapping": { + "token_data_id": "token_data_id" + }, + "insertion_order": null, + "remote_table": { + "name": "current_token_royalty_v1", + "schema": "public" + } + } + } } ], "array_relationships": [ @@ -1708,50 +1777,23 @@ }, { "table": { - "name": "current_unified_fungible_asset_balances_to_be_renamed", + "name": "current_token_royalty_v1", "schema": "public" }, - "configuration": { - "column_config": {}, - "custom_column_names": {}, - "custom_name": "current_fungible_asset_balances", - "custom_root_fields": {} - }, - "object_relationships": [ - { - "name": "metadata", - "using": { - "manual_configuration": { - "column_mapping": { - "asset_type": "asset_type" - }, - "insertion_order": null, - "remote_table": { - "name": "fungible_asset_metadata", - "schema": "public" - } - } - } - } - ], "select_permissions": [ { "role": "anonymous", "permission": { "columns": [ - "amount", - "asset_type", - "is_frozen", - "is_primary", "last_transaction_timestamp", "last_transaction_version", - "owner_address", - "storage_id", - "token_standard" + "payee_address", + "royalty_points_denominator", + "royalty_points_numerator", + "token_data_id" ], "filter": {}, - "limit": 100, - "allow_aggregations": true + "limit": 100 }, "comment": "" } @@ -2308,6 +2350,10 @@ "from_env": "INDEXER_V2_POSTGRES_URL" }, "isolation_level": "read-committed", + "pool_settings": { + "connection_lifetime": 600, + "max_connections": 100 + }, "use_prepared_statements": false } } diff --git a/crates/aptos/src/node/local_testnet/processors.rs b/crates/aptos/src/node/local_testnet/processors.rs index efd9baf8c8924..f9654f9c662b8 100644 --- a/crates/aptos/src/node/local_testnet/processors.rs +++ b/crates/aptos/src/node/local_testnet/processors.rs @@ -92,6 +92,18 @@ impl ProcessorManager { ProcessorName::ParquetFungibleAssetProcessor => { bail!("ParquetFungibleAssetProcessor is not supported in the localnet") }, + ProcessorName::ParquetTransactionMetadataProcessor => { + bail!("ParquetTransactionMetadataProcessor is not supported in the localnet") + }, + ProcessorName::ParquetAnsProcessor => { + bail!("ParquetAnsProcessor is not supported in the localnet") + }, + ProcessorName::ParquetEventsProcessor => { + bail!("ParquetEventsProcessor is not supported in the localnet") + }, + ProcessorName::ParquetTokenV2Processor => { + bail!("ParquetTokenV2Processor is not supported in the localnet") + }, ProcessorName::StakeProcessor => { ProcessorConfig::StakeProcessor(StakeProcessorConfig { query_retries: Default::default(),