diff --git a/rust/Cargo.lock b/rust/Cargo.lock index 3ea8d1311..76ef4edaa 100644 --- a/rust/Cargo.lock +++ b/rust/Cargo.lock @@ -141,7 +141,7 @@ checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6" [[package]] name = "aptos-indexer-processor-sdk" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "ahash", "anyhow", @@ -174,7 +174,7 @@ dependencies = [ [[package]] name = "aptos-indexer-processor-sdk-server-framework" version = "1.0.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "anyhow", "aptos-indexer-processor-sdk", @@ -198,16 +198,16 @@ dependencies = [ [[package]] name = "aptos-indexer-test-transactions" version = "1.0.0" -source = "git+https://github.com/aptos-labs/aptos-core.git?rev=c583502c69529fddbbf7e47bf920f1dc60e71b72#c583502c69529fddbbf7e47bf920f1dc60e71b72" +source = "git+https://github.com/aptos-labs/aptos-core.git?rev=87acec023264cdd756e5eae073ddf302fda0917a#87acec023264cdd756e5eae073ddf302fda0917a" dependencies = [ - "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=c583502c69529fddbbf7e47bf920f1dc60e71b72)", + "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=87acec023264cdd756e5eae073ddf302fda0917a)", "serde_json", ] [[package]] name = "aptos-indexer-testing-framework" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "anyhow", "aptos-indexer-processor-sdk", @@ -234,10 +234,10 @@ dependencies = [ [[package]] name = "aptos-indexer-transaction-stream" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "anyhow", - "aptos-moving-average 0.1.0 (git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1)", + "aptos-moving-average 0.1.0 (git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894)", "aptos-protos 1.3.1 (git+https://github.com/aptos-labs/aptos-core.git?rev=5c48aee129b5a141be2792ffa3d9bd0a1a61c9cb)", "chrono", "futures-util", @@ -262,7 +262,7 @@ dependencies = [ [[package]] name = "aptos-moving-average" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "chrono", ] @@ -308,7 +308,7 @@ dependencies = [ [[package]] name = "aptos-protos" version = "1.3.1" -source = "git+https://github.com/aptos-labs/aptos-core.git?rev=c583502c69529fddbbf7e47bf920f1dc60e71b72#c583502c69529fddbbf7e47bf920f1dc60e71b72" +source = "git+https://github.com/aptos-labs/aptos-core.git?rev=87acec023264cdd756e5eae073ddf302fda0917a#87acec023264cdd756e5eae073ddf302fda0917a" dependencies = [ "futures-core", "pbjson", @@ -2246,7 +2246,7 @@ dependencies = [ [[package]] name = "instrumented-channel" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "delegate", "derive_builder", @@ -4129,7 +4129,7 @@ checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "sample" version = "0.1.0" -source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=a12b31492285c70d5afbdd42aa10fe76e1fb79e1#a12b31492285c70d5afbdd42aa10fe76e1fb79e1" +source = "git+https://github.com/aptos-labs/aptos-indexer-processor-sdk.git?rev=1f989c65abbd5cf00a0631a30755ef05818e1894#1f989c65abbd5cf00a0631a30755ef05818e1894" dependencies = [ "tracing", ] diff --git a/rust/Cargo.toml b/rust/Cargo.toml index 7d1137756..0f5d87060 100644 --- a/rust/Cargo.toml +++ b/rust/Cargo.toml @@ -30,12 +30,12 @@ testing-transactions = { path = "testing-transactions" } ahash = { version = "0.8.7", features = ["serde"] } anyhow = "1.0.86" -aptos-indexer-processor-sdk = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "a12b31492285c70d5afbdd42aa10fe76e1fb79e1" } -aptos-indexer-processor-sdk-server-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "a12b31492285c70d5afbdd42aa10fe76e1fb79e1" } +aptos-indexer-processor-sdk = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "1f989c65abbd5cf00a0631a30755ef05818e1894" } +aptos-indexer-processor-sdk-server-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "1f989c65abbd5cf00a0631a30755ef05818e1894" } aptos-protos = { git = "https://github.com/aptos-labs/aptos-core.git", rev = "5c48aee129b5a141be2792ffa3d9bd0a1a61c9cb" } aptos-system-utils = { git = "https://github.com/aptos-labs/aptos-core.git", rev = "202bdccff2b2d333a385ae86a4fcf23e89da9f62" } -aptos-indexer-test-transactions = { git = "https://github.com/aptos-labs/aptos-core.git", rev = "c583502c69529fddbbf7e47bf920f1dc60e71b72" } -aptos-indexer-testing-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "a12b31492285c70d5afbdd42aa10fe76e1fb79e1" } +aptos-indexer-test-transactions = { git = "https://github.com/aptos-labs/aptos-core.git", rev = "87acec023264cdd756e5eae073ddf302fda0917a" } +aptos-indexer-testing-framework = { git = "https://github.com/aptos-labs/aptos-indexer-processor-sdk.git", rev = "1f989c65abbd5cf00a0631a30755ef05818e1894" } async-trait = "0.1.53" backtrace = "0.3.58" diff --git a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/events_processor/308783012/events.json b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/events_processor/308783012/events.json index 92b3e7efa..0d0606808 100644 --- a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/events_processor/308783012/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/events_processor/308783012/events.json @@ -10,9 +10,8 @@ "index": "3723914", "token": "0x6fd8ee875fb55e03b1f9643d3f229f0b077a71cfe7ffc8ba7e09ff4392950e5c" }, - "inserted_at": "2024-10-15T04:55:32.404918", - "event_index": 0, - "indexed_type": "0x4::collection::MintEvent" + "indexed_type": "0x4::collection::MintEvent", + "event_index": 0 }, { "sequence_number": 0, @@ -26,9 +25,8 @@ "from": "0x7efbc33cf69ad534412eab0ccd0f5fbec7793bdebf08a3620afe8e5f89ef13a0", "object": "0x6fd8ee875fb55e03b1f9643d3f229f0b077a71cfe7ffc8ba7e09ff4392950e5c" }, - "inserted_at": "2024-10-15T04:55:32.404918", - "event_index": 1, - "indexed_type": "0x1::object::TransferEvent" + "indexed_type": "0x1::object::TransferEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -44,8 +42,7 @@ "total_charge_gas_units": "520", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T04:55:32.404918", - "event_index": 2, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 2 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/fungible_asset_processor/308783012/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/fungible_asset_processor/308783012/fungible_asset_activities.json index 909daae70..db2769f93 100644 --- a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/fungible_asset_processor/308783012/fungible_asset_activities.json +++ b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/fungible_asset_processor/308783012/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 106350614, "token_standard": "v1", "transaction_timestamp": "2023-10-24T09:08:03", - "inserted_at": "2024-10-15T04:55:33.359030", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/token_v2_processor/308783012/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/token_v2_processor/308783012/token_activities_v2.json index 503c6d4ed..0fdaa5eeb 100644 --- a/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/token_v2_processor/308783012/token_activities_v2.json +++ b/rust/integration-tests/expected_db_output_files/imported_mainnet_txns/token_v2_processor/308783012/token_activities_v2.json @@ -14,8 +14,7 @@ "entry_function_id_str": "0x8d2d7bcde13b2513617df3f98cdd5d0e4b9f714c6308b9204fe18ad900d92609::mint::resource_mint_token_memo", "token_standard": "v2", "is_fungible_v2": null, - "transaction_timestamp": "2023-10-24T09:08:03.606880", - "inserted_at": "2024-10-15T04:55:34.472476" + "transaction_timestamp": "2023-10-24T09:08:03.606880" }, { "transaction_version": 308783012, @@ -32,7 +31,6 @@ "entry_function_id_str": "0x8d2d7bcde13b2513617df3f98cdd5d0e4b9f714c6308b9204fe18ad900d92609::mint::resource_mint_token_memo", "token_standard": "v2", "is_fungible_v2": null, - "transaction_timestamp": "2023-10-24T09:08:03.606880", - "inserted_at": "2024-10-15T04:55:34.472476" + "transaction_timestamp": "2023-10-24T09:08:03.606880" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1/events.json index c05d5d4d7..338e7e633 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1/events.json @@ -19,9 +19,8 @@ ], "previous_block_votes_bitvec": "0x00" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 0, - "indexed_type": "0x1::block::NewBlockEvent" + "indexed_type": "0x1::block::NewBlockEvent", + "event_index": 0 }, { "sequence_number": 0, @@ -34,9 +33,8 @@ "pool_address": "0xb7c7d12080209e9dc14498c80200706e760363fb31782247e82cf57d1d6e5d6c", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 1, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -49,9 +47,8 @@ "pool_address": "0xdffe3c93b756bf6fec59b052d6fe71b40c3f9b7899d69ab06ba385b1c6728d16", "rewards_amount": "4566200000" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 2, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 2 }, { "sequence_number": 0, @@ -64,9 +61,8 @@ "pool_address": "0x828ca971e35c8b9a807439e5a328fdc9a5ed0efbfb12f40bc451d17f6998be3f", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 3, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 3 }, { "sequence_number": 0, @@ -79,9 +75,8 @@ "pool_address": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 4, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 4 }, { "sequence_number": 1, @@ -93,8 +88,7 @@ "data": { "epoch": "2" }, - "inserted_at": "2024-10-15T05:15:50.241072", - "event_index": 5, - "indexed_type": "0x1::reconfiguration::NewEpochEvent" + "indexed_type": "0x1::reconfiguration::NewEpochEvent", + "event_index": 5 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json index c4ec7b54a..a10bb69f9 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json @@ -9,9 +9,8 @@ "data": { "amount": "300000" }, - "inserted_at": "2024-10-15T05:15:48.641863", - "event_index": 0, - "indexed_type": "0x1::coin::WithdrawEvent" + "indexed_type": "0x1::coin::WithdrawEvent", + "event_index": 0 }, { "sequence_number": 707, @@ -23,9 +22,8 @@ "data": { "amount": "300000" }, - "inserted_at": "2024-10-15T05:15:48.641863", - "event_index": 1, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -38,9 +36,8 @@ "store": "0x8f4f0991e18bd9620a4b3756dbe15afd20135eaaa93e0d0b82e6e2412a8e12b8", "amount": "300000" }, - "inserted_at": "2024-10-15T05:15:48.641863", - "event_index": 2, - "indexed_type": "0x1::fungible_asset::Deposit" + "indexed_type": "0x1::fungible_asset::Deposit", + "event_index": 2 }, { "sequence_number": 0, @@ -57,9 +54,8 @@ "token": "0x1::aptos_coin::AptosCoin", "amount": "300000" }, - "inserted_at": "2024-10-15T05:15:48.641863", - "event_index": 3, - "indexed_type": "0xfabb471223cefd7064b1f19f6e0e06468d2bd830d8ae832916406dd8297098af::lending_pool::Deposit" + "indexed_type": "0xfabb471223cefd7064b1f19f6e0e06468d2bd830d8ae832916406dd8297098af::lending_pool::Deposit", + "event_index": 3 }, { "sequence_number": 0, @@ -75,8 +71,7 @@ "total_charge_gas_units": "505", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:15:48.641863", - "event_index": 4, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 4 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/2/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/2/events.json new file mode 100644 index 000000000..1c54ddcd9 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/2/events.json @@ -0,0 +1,22 @@ +[ + { + "sequence_number": 2, + "creation_number": 3, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000001", + "transaction_version": 2, + "transaction_block_height": 2, + "type_": "0x1::block::NewBlockEvent", + "data": { + "hash": "0x7155ede2ab87b66e7beba3210b43367eb90daff8891d44ed05eed20a71b9b55a", + "epoch": "2", + "round": "1", + "height": "2", + "proposer": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", + "time_microseconds": "1662686657332551", + "failed_proposer_indices": [], + "previous_block_votes_bitvec": "0x00" + }, + "indexed_type": "0x1::block::NewBlockEvent", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json index 8da11495c..b3c4de024 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json @@ -13,9 +13,8 @@ "account_address": "0x589dabf3b43ef5c331ea3c0f9b6b005860c1f0ef94a5948d133e051b20c22862" } }, - "inserted_at": "2024-10-15T05:15:49.422609", - "event_index": 0, - "indexed_type": "0x1::account::CoinRegisterEvent" + "indexed_type": "0x1::account::CoinRegisterEvent", + "event_index": 0 }, { "sequence_number": 0, @@ -27,8 +26,7 @@ "data": { "amount": "1000000000000000000" }, - "inserted_at": "2024-10-15T05:15:49.422609", - "event_index": 1, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 1 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/3/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/3/events.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/3/events.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json index 078706570..d1a0d7d76 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json @@ -10,9 +10,8 @@ "pool_address": "0xa4113560d0b18ba38797f2a899c4b27e0c5b0476be5d8f6be68fba8b1861ed0", "rewards_amount": "789371656" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 0, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 0 }, { "sequence_number": 4252, @@ -25,9 +24,8 @@ "pool_address": "0x286e8af6717ef6b1e361aae8ab28dd6664bf562c2805dd9a53432246ec66566e", "rewards_amount": "19174256316" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 1, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 1 }, { "sequence_number": 9823, @@ -40,9 +38,8 @@ "pool_address": "0x116176e2af223a8b7f8db80dc52f7a423b4d7f8c0553a1747e92ef58849aff4f", "rewards_amount": "19178730843" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 2, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 2 }, { "sequence_number": 3697, @@ -55,9 +52,8 @@ "pool_address": "0xba08cec00a8cfa1deff6c9212dda8d198c8fa6ee1992f3ada76d645f99e3402b", "rewards_amount": "818123890" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 3, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 3 }, { "sequence_number": 9813, @@ -70,9 +66,8 @@ "pool_address": "0x12000330d7cd8a748f46c25e6ce5d236a27e13d0b510d4516ac84ecc5fddd002", "rewards_amount": "19178287161" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 4, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 4 }, { "sequence_number": 14143, @@ -85,9 +80,8 @@ "pool_address": "0x5176f2252762e527e3598c22f1bdb3a1ac0ff0db2d7518cabbc99305330a864a", "rewards_amount": "963055869" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 5, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 5 }, { "sequence_number": 9812, @@ -100,9 +94,8 @@ "pool_address": "0xf0a156ed79ab6ccb5a643af48716263b565fd985ba36560966b4a91bdc8521f4", "rewards_amount": "19177688699" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 6, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 6 }, { "sequence_number": 7807, @@ -115,9 +108,8 @@ "pool_address": "0xa562415be88d9f08ba98fa3f6af9be0e36580c0f8fff5100a50b519e8f4a15c9", "rewards_amount": "841058926" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 7, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 7 }, { "sequence_number": 9823, @@ -130,9 +122,8 @@ "pool_address": "0x676f640c90cb6c45f21be50974531d440309aa4ddad919ae0429039789a3d8a9", "rewards_amount": "19178518163" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 8, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 8 }, { "sequence_number": 9829, @@ -145,9 +136,8 @@ "pool_address": "0x3c04549114877c55f45649aba48ac0a4ff086ab7bdce3b8cc8d3d9947bc0d99", "rewards_amount": "19185171265" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 9, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 9 }, { "sequence_number": 4252, @@ -160,9 +150,8 @@ "pool_address": "0x6d00a8a82bd0b6d187f9a328118ad61b5c80237362e8f5dd2454f2d3a1b03890", "rewards_amount": "19174925092" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 10, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 10 }, { "sequence_number": 8256, @@ -175,9 +164,8 @@ "pool_address": "0x7a2ddb6af66beb0d9987c6c9010cb9053454f067e16775a8ecf19961195c3d28", "rewards_amount": "18813123628" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 11, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 11 }, { "sequence_number": 8641, @@ -190,9 +178,8 @@ "pool_address": "0xeecd6e9fb71f3a67db6321e93deecf7a9d7c3f4fac6cd170deb3e8b183281943", "rewards_amount": "828031401" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 12, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 12 }, { "sequence_number": 1882, @@ -205,9 +192,8 @@ "pool_address": "0xfd47a2fb988c959839ea2fe4d7169b48536a42bf5e4933790701a08252ba2039", "rewards_amount": "798768182" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 13, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 13 }, { "sequence_number": 2197, @@ -220,9 +206,8 @@ "pool_address": "0x479ca442491cfd636f84fa8e56fa420c8038587e459e886d16a0b9d3993b16ba", "rewards_amount": "18896078163" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 14, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 14 }, { "sequence_number": 2199, @@ -235,9 +220,8 @@ "pool_address": "0x95a0e6b1105ba7ef9382e585d32e9dbf1a73833975af77d9b6924aa33468df07", "rewards_amount": "18894077814" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 15, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 15 }, { "sequence_number": 225, @@ -250,9 +234,8 @@ "pool_address": "0xb59c2db675c086d0c07b0f5d5ebd95ea9ead4429d836284fc4a576c4eed5799c", "rewards_amount": "787639333" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 16, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 16 }, { "sequence_number": 405, @@ -265,9 +248,8 @@ "pool_address": "0x50e52098d22c91f4c6a0065d03b2602cc2643089b218096e3cfe5f1bd98d80e6", "rewards_amount": "789473752" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 17, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 17 }, { "sequence_number": 330, @@ -280,9 +262,8 @@ "pool_address": "0xa5ed5d5e8c892165b18c2062596e8d1139fbb2cc451d430f787cd707122ce023", "rewards_amount": "787913628" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 18, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 18 }, { "sequence_number": 16643, @@ -294,8 +275,7 @@ "data": { "epoch": "16644" }, - "inserted_at": "2024-10-15T05:15:49.855843", - "event_index": 19, - "indexed_type": "0x1::reconfiguration::NewEpochEvent" + "indexed_type": "0x1::reconfiguration::NewEpochEvent", + "event_index": 19 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json index a06eeb473..ed5feab5f 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json @@ -13,9 +13,8 @@ "account_address": "0x1" } }, - "inserted_at": "2024-10-15T05:15:48.257818", - "event_index": 0, - "indexed_type": "0x1::account::CoinRegisterEvent" + "indexed_type": "0x1::account::CoinRegisterEvent", + "event_index": 0 }, { "sequence_number": 21684, @@ -27,9 +26,8 @@ "data": { "amount": "10" }, - "inserted_at": "2024-10-15T05:15:48.257818", - "event_index": 1, - "indexed_type": "0x1::coin::WithdrawEvent" + "indexed_type": "0x1::coin::WithdrawEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -41,9 +39,8 @@ "data": { "amount": "10" }, - "inserted_at": "2024-10-15T05:15:48.257818", - "event_index": 2, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 2 }, { "sequence_number": 0, @@ -59,8 +56,7 @@ "total_charge_gas_units": "999", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:15:48.257818", - "event_index": 3, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 3 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json index 69192b908..dd105cc73 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json @@ -10,9 +10,8 @@ "store": "0x8bd5745daa2d6e5817819c6bf37600196e55cfba8c5bcdfdf55684bf4accbb9c", "amount": "100000000" }, - "inserted_at": "2024-10-15T05:15:49.043035", - "event_index": 0, - "indexed_type": "0x1::fungible_asset::Withdraw" + "indexed_type": "0x1::fungible_asset::Withdraw", + "event_index": 0 }, { "sequence_number": 0, @@ -25,9 +24,8 @@ "store": "0xfe90bdd996728b93e09f5d59fd91d6d44be85ab7acea5d1ed535b4c13b2c32c0", "amount": "100000000" }, - "inserted_at": "2024-10-15T05:15:49.043035", - "event_index": 1, - "indexed_type": "0x1::fungible_asset::Deposit" + "indexed_type": "0x1::fungible_asset::Deposit", + "event_index": 1 }, { "sequence_number": 0, @@ -43,8 +41,7 @@ "total_charge_gas_units": "12", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:15:49.043035", - "event_index": 2, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 2 } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json index 7eb6cd8ca..deda77d29 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:15:49.044565", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:15:49.044565", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:15:49.044565", "storage_refund_amount": "0" }, { @@ -72,7 +69,6 @@ "block_height": 295534162, "token_standard": "v2", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:15:49.044565", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json index da4019a2d..436b43072 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 20040326, "token_standard": "v1", "transaction_timestamp": "2022-10-13T01:46:57", - "inserted_at": "2024-10-15T04:55:33.625216", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 20040326, "token_standard": "v1", "transaction_timestamp": "2022-10-13T01:46:57", - "inserted_at": "2024-10-15T04:55:33.625216", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json index 69a01ac2c..5e99ebdf9 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:15:48.265877", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:15:48.265877", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:15:48.265877", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json index 519c0f453..bc3197a95 100644 --- a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 356437526, "token_standard": "v1", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:15:49.908952", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 356437526, "token_standard": "v2", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:15:49.908952", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 356437526, "token_standard": "v2", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:15:49.908952", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/2/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/2/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/2/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/3/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/3/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/imported_testnet_txns/token_v2_processor/3/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/21/events.json b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/21/events.json new file mode 100644 index 000000000..50ec7f28d --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/21/events.json @@ -0,0 +1,19 @@ +[ + { + "sequence_number": 0, + "creation_number": 0, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000000", + "transaction_version": 21, + "transaction_block_height": 10, + "type_": "0x1::transaction_fee::FeeStatement", + "data": { + "io_gas_units": "1", + "storage_fee_octas": "0", + "execution_gas_units": "3", + "total_charge_gas_units": "3", + "storage_fee_refund_octas": "0" + }, + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/41/events.json b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/41/events.json new file mode 100644 index 000000000..bb36bb801 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/41/events.json @@ -0,0 +1,19 @@ +[ + { + "sequence_number": 0, + "creation_number": 0, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000000", + "transaction_version": 41, + "transaction_block_height": 19, + "type_": "0x1::transaction_fee::FeeStatement", + "data": { + "io_gas_units": "1", + "storage_fee_octas": "0", + "execution_gas_units": "3", + "total_charge_gas_units": "3", + "storage_fee_refund_octas": "0" + }, + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/63/events.json b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/63/events.json new file mode 100644 index 000000000..5ce982ab2 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/63/events.json @@ -0,0 +1,19 @@ +[ + { + "sequence_number": 0, + "creation_number": 0, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000000", + "transaction_version": 63, + "transaction_block_height": 29, + "type_": "0x1::transaction_fee::FeeStatement", + "data": { + "io_gas_units": "1", + "storage_fee_octas": "0", + "execution_gas_units": "3", + "total_charge_gas_units": "3", + "storage_fee_refund_octas": "0" + }, + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/83/events.json b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/83/events.json new file mode 100644 index 000000000..7840e99b9 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/events_processor/83/events.json @@ -0,0 +1,19 @@ +[ + { + "sequence_number": 0, + "creation_number": 0, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000000", + "transaction_version": 83, + "transaction_block_height": 38, + "type_": "0x1::transaction_fee::FeeStatement", + "data": { + "io_gas_units": "1", + "storage_fee_octas": "0", + "execution_gas_units": "3", + "total_charge_gas_units": "3", + "storage_fee_refund_octas": "0" + }, + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/coin_supply.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/coin_supply.json new file mode 100644 index 000000000..f91249423 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/coin_supply.json @@ -0,0 +1,10 @@ +[ + { + "transaction_version": 21, + "coin_type_hash": "91ceb1308a98389691e05158b07ed5f079ab78461a6bb8d5a4054b1bb5cb8bb6", + "coin_type": "0x1::aptos_coin::AptosCoin", + "supply": "18446744073709451425", + "transaction_timestamp": "2024-10-16T05:36:37", + "transaction_epoch": 2 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/current_fungible_asset_balances.json new file mode 100644 index 000000000..ea60034bd --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/current_fungible_asset_balances.json @@ -0,0 +1,13 @@ +[ + { + "storage_id": "0x9cfa839238cb942fbc487ff341fcdccabacd01e29864f594587900aa3a9d88b2", + "owner_address": "0x765d8c8d4d5859f43a56e2756fbf5f3d2483dbaa14f3fb62872df820d6e64eff", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "99999700", + "last_transaction_timestamp": "2024-10-16T05:36:37", + "last_transaction_version": 21, + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_activities.json new file mode 100644 index 000000000..23ea8b1bf --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_activities.json @@ -0,0 +1,20 @@ +[ + { + "transaction_version": 21, + "event_index": -1, + "owner_address": "0x765d8c8d4d5859f43a56e2756fbf5f3d2483dbaa14f3fb62872df820d6e64eff", + "storage_id": "0x9cfa839238cb942fbc487ff341fcdccabacd01e29864f594587900aa3a9d88b2", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_frozen": null, + "amount": "300", + "type_": "0x1::aptos_coin::GasFeeEvent", + "is_gas_fee": true, + "gas_fee_payer_address": null, + "is_transaction_success": true, + "entry_function_id_str": null, + "block_height": 10, + "token_standard": "v1", + "transaction_timestamp": "2024-10-16T05:36:37", + "storage_refund_amount": "0" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_balances.json new file mode 100644 index 000000000..8b5b1e374 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_balances.json @@ -0,0 +1,14 @@ +[ + { + "transaction_version": 21, + "write_set_change_index": 0, + "storage_id": "0x9cfa839238cb942fbc487ff341fcdccabacd01e29864f594587900aa3a9d88b2", + "owner_address": "0x765d8c8d4d5859f43a56e2756fbf5f3d2483dbaa14f3fb62872df820d6e64eff", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "99999700", + "transaction_timestamp": "2024-10-16T05:36:37", + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/21/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/coin_supply.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/coin_supply.json new file mode 100644 index 000000000..5c2514ef6 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/coin_supply.json @@ -0,0 +1,10 @@ +[ + { + "transaction_version": 41, + "coin_type_hash": "91ceb1308a98389691e05158b07ed5f079ab78461a6bb8d5a4054b1bb5cb8bb6", + "coin_type": "0x1::aptos_coin::AptosCoin", + "supply": "18446744073709351225", + "transaction_timestamp": "2024-10-16T05:36:43", + "transaction_epoch": 2 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/current_fungible_asset_balances.json new file mode 100644 index 000000000..2e8510b1b --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/current_fungible_asset_balances.json @@ -0,0 +1,13 @@ +[ + { + "storage_id": "0xee7ccdc3a833754267c71df9534640b532352f734e07509cbe48561d23d05831", + "owner_address": "0x8f0de18409d6fca18c72fac4062fc0f9baa6404296fed93a3ad0250fb671f8b3", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "99999700", + "last_transaction_timestamp": "2024-10-16T05:36:43", + "last_transaction_version": 41, + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_activities.json new file mode 100644 index 000000000..e96f6b15f --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_activities.json @@ -0,0 +1,20 @@ +[ + { + "transaction_version": 41, + "event_index": -1, + "owner_address": "0x8f0de18409d6fca18c72fac4062fc0f9baa6404296fed93a3ad0250fb671f8b3", + "storage_id": "0xee7ccdc3a833754267c71df9534640b532352f734e07509cbe48561d23d05831", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_frozen": null, + "amount": "300", + "type_": "0x1::aptos_coin::GasFeeEvent", + "is_gas_fee": true, + "gas_fee_payer_address": null, + "is_transaction_success": true, + "entry_function_id_str": null, + "block_height": 19, + "token_standard": "v1", + "transaction_timestamp": "2024-10-16T05:36:43", + "storage_refund_amount": "0" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_balances.json new file mode 100644 index 000000000..ee097a2c1 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_balances.json @@ -0,0 +1,14 @@ +[ + { + "transaction_version": 41, + "write_set_change_index": 0, + "storage_id": "0xee7ccdc3a833754267c71df9534640b532352f734e07509cbe48561d23d05831", + "owner_address": "0x8f0de18409d6fca18c72fac4062fc0f9baa6404296fed93a3ad0250fb671f8b3", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "99999700", + "transaction_timestamp": "2024-10-16T05:36:43", + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/41/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/coin_supply.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/coin_supply.json new file mode 100644 index 000000000..1087a8803 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/coin_supply.json @@ -0,0 +1,10 @@ +[ + { + "transaction_version": 63, + "coin_type_hash": "91ceb1308a98389691e05158b07ed5f079ab78461a6bb8d5a4054b1bb5cb8bb6", + "coin_type": "0x1::aptos_coin::AptosCoin", + "supply": "18446744073809350825", + "transaction_timestamp": "2024-10-16T05:36:50", + "transaction_epoch": 2 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/current_fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/current_fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_activities.json new file mode 100644 index 000000000..e11e3c1bc --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_activities.json @@ -0,0 +1,20 @@ +[ + { + "transaction_version": 63, + "event_index": -1, + "owner_address": "0xa531b7fdd7917f73ca216d89a8d9ce0cf7e7cfb9086ca6f6cbf9521532748d16", + "storage_id": "0xba2fa98d311f0adb1d6608dfbc6d66b6e583c0b8f6bbadea7d241f7e1b0b1080", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_frozen": null, + "amount": "300", + "type_": "0x1::aptos_coin::GasFeeEvent", + "is_gas_fee": true, + "gas_fee_payer_address": null, + "is_transaction_success": true, + "entry_function_id_str": null, + "block_height": 29, + "token_standard": "v1", + "transaction_timestamp": "2024-10-16T05:36:50", + "storage_refund_amount": "0" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_balances.json new file mode 100644 index 000000000..5bbcafed2 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_balances.json @@ -0,0 +1,14 @@ +[ + { + "transaction_version": 63, + "write_set_change_index": 0, + "storage_id": "0xba2fa98d311f0adb1d6608dfbc6d66b6e583c0b8f6bbadea7d241f7e1b0b1080", + "owner_address": "0xa531b7fdd7917f73ca216d89a8d9ce0cf7e7cfb9086ca6f6cbf9521532748d16", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "99999700", + "transaction_timestamp": "2024-10-16T05:36:50", + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/63/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/coin_supply.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/coin_supply.json new file mode 100644 index 000000000..f9d30ef1a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/coin_supply.json @@ -0,0 +1,10 @@ +[ + { + "transaction_version": 83, + "coin_type_hash": "91ceb1308a98389691e05158b07ed5f079ab78461a6bb8d5a4054b1bb5cb8bb6", + "coin_type": "0x1::aptos_coin::AptosCoin", + "supply": "18446744073909449225", + "transaction_timestamp": "2024-10-16T05:36:56", + "transaction_epoch": 2 + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/current_fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/current_fungible_asset_balances.json new file mode 100644 index 000000000..e6c79af53 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/current_fungible_asset_balances.json @@ -0,0 +1,13 @@ +[ + { + "storage_id": "0xba2fa98d311f0adb1d6608dfbc6d66b6e583c0b8f6bbadea7d241f7e1b0b1080", + "owner_address": "0xa531b7fdd7917f73ca216d89a8d9ce0cf7e7cfb9086ca6f6cbf9521532748d16", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "199999400", + "last_transaction_timestamp": "2024-10-16T05:36:56", + "last_transaction_version": 83, + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_activities.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_activities.json new file mode 100644 index 000000000..c958d2ba2 --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_activities.json @@ -0,0 +1,20 @@ +[ + { + "transaction_version": 83, + "event_index": -1, + "owner_address": "0xa531b7fdd7917f73ca216d89a8d9ce0cf7e7cfb9086ca6f6cbf9521532748d16", + "storage_id": "0xba2fa98d311f0adb1d6608dfbc6d66b6e583c0b8f6bbadea7d241f7e1b0b1080", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_frozen": null, + "amount": "300", + "type_": "0x1::aptos_coin::GasFeeEvent", + "is_gas_fee": true, + "gas_fee_payer_address": null, + "is_transaction_success": true, + "entry_function_id_str": null, + "block_height": 38, + "token_standard": "v1", + "transaction_timestamp": "2024-10-16T05:36:56", + "storage_refund_amount": "0" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_balances.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_balances.json new file mode 100644 index 000000000..affa613df --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_balances.json @@ -0,0 +1,14 @@ +[ + { + "transaction_version": 83, + "write_set_change_index": 0, + "storage_id": "0xba2fa98d311f0adb1d6608dfbc6d66b6e583c0b8f6bbadea7d241f7e1b0b1080", + "owner_address": "0xa531b7fdd7917f73ca216d89a8d9ce0cf7e7cfb9086ca6f6cbf9521532748d16", + "asset_type": "0x1::aptos_coin::AptosCoin", + "is_primary": true, + "is_frozen": false, + "amount": "199999400", + "transaction_timestamp": "2024-10-16T05:36:56", + "token_standard": "v1" + } +] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_metadata.json b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/fungible_asset_processor/83/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/21/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/21/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/21/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/41/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/41/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/41/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/63/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/63/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/63/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/83/token_activities_v2.json b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/83/token_activities_v2.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/expected_db_output_files/scripted_txns/token_v2_processor/83/token_activities_v2.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1/events.json index f3c7c9d2a..338e7e633 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1/events.json @@ -19,9 +19,8 @@ ], "previous_block_votes_bitvec": "0x00" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 0, - "indexed_type": "0x1::block::NewBlockEvent" + "indexed_type": "0x1::block::NewBlockEvent", + "event_index": 0 }, { "sequence_number": 0, @@ -34,9 +33,8 @@ "pool_address": "0xb7c7d12080209e9dc14498c80200706e760363fb31782247e82cf57d1d6e5d6c", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 1, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -49,9 +47,8 @@ "pool_address": "0xdffe3c93b756bf6fec59b052d6fe71b40c3f9b7899d69ab06ba385b1c6728d16", "rewards_amount": "4566200000" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 2, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 2 }, { "sequence_number": 0, @@ -64,9 +61,8 @@ "pool_address": "0x828ca971e35c8b9a807439e5a328fdc9a5ed0efbfb12f40bc451d17f6998be3f", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 3, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 3 }, { "sequence_number": 0, @@ -79,9 +75,8 @@ "pool_address": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", "rewards_amount": "0" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 4, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 4 }, { "sequence_number": 1, @@ -93,8 +88,7 @@ "data": { "epoch": "2" }, - "inserted_at": "2024-10-15T05:16:56.906765", - "event_index": 5, - "indexed_type": "0x1::reconfiguration::NewEpochEvent" + "indexed_type": "0x1::reconfiguration::NewEpochEvent", + "event_index": 5 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json index e781112ba..a10bb69f9 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/1255836496/events.json @@ -9,9 +9,8 @@ "data": { "amount": "300000" }, - "inserted_at": "2024-10-15T05:16:54.487402", - "event_index": 0, - "indexed_type": "0x1::coin::WithdrawEvent" + "indexed_type": "0x1::coin::WithdrawEvent", + "event_index": 0 }, { "sequence_number": 707, @@ -23,9 +22,8 @@ "data": { "amount": "300000" }, - "inserted_at": "2024-10-15T05:16:54.487402", - "event_index": 1, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -38,9 +36,8 @@ "store": "0x8f4f0991e18bd9620a4b3756dbe15afd20135eaaa93e0d0b82e6e2412a8e12b8", "amount": "300000" }, - "inserted_at": "2024-10-15T05:16:54.487402", - "event_index": 2, - "indexed_type": "0x1::fungible_asset::Deposit" + "indexed_type": "0x1::fungible_asset::Deposit", + "event_index": 2 }, { "sequence_number": 0, @@ -57,9 +54,8 @@ "token": "0x1::aptos_coin::AptosCoin", "amount": "300000" }, - "inserted_at": "2024-10-15T05:16:54.487402", - "event_index": 3, - "indexed_type": "0xfabb471223cefd7064b1f19f6e0e06468d2bd830d8ae832916406dd8297098af::lending_pool::Deposit" + "indexed_type": "0xfabb471223cefd7064b1f19f6e0e06468d2bd830d8ae832916406dd8297098af::lending_pool::Deposit", + "event_index": 3 }, { "sequence_number": 0, @@ -75,8 +71,7 @@ "total_charge_gas_units": "505", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:16:54.487402", - "event_index": 4, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 4 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/2/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/2/events.json new file mode 100644 index 000000000..1c54ddcd9 --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/2/events.json @@ -0,0 +1,22 @@ +[ + { + "sequence_number": 2, + "creation_number": 3, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000001", + "transaction_version": 2, + "transaction_block_height": 2, + "type_": "0x1::block::NewBlockEvent", + "data": { + "hash": "0x7155ede2ab87b66e7beba3210b43367eb90daff8891d44ed05eed20a71b9b55a", + "epoch": "2", + "round": "1", + "height": "2", + "proposer": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", + "time_microseconds": "1662686657332551", + "failed_proposer_indices": [], + "previous_block_votes_bitvec": "0x00" + }, + "indexed_type": "0x1::block::NewBlockEvent", + "event_index": 0 + } +] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json index c84be8759..b3c4de024 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/278556781/events.json @@ -13,9 +13,8 @@ "account_address": "0x589dabf3b43ef5c331ea3c0f9b6b005860c1f0ef94a5948d133e051b20c22862" } }, - "inserted_at": "2024-10-15T05:16:55.660399", - "event_index": 0, - "indexed_type": "0x1::account::CoinRegisterEvent" + "indexed_type": "0x1::account::CoinRegisterEvent", + "event_index": 0 }, { "sequence_number": 0, @@ -27,8 +26,7 @@ "data": { "amount": "1000000000000000000" }, - "inserted_at": "2024-10-15T05:16:55.660399", - "event_index": 1, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 1 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/3/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/3/events.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/3/events.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json index 31bf8c5cf..d1a0d7d76 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5523474016/events.json @@ -10,9 +10,8 @@ "pool_address": "0xa4113560d0b18ba38797f2a899c4b27e0c5b0476be5d8f6be68fba8b1861ed0", "rewards_amount": "789371656" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 0, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 0 }, { "sequence_number": 4252, @@ -25,9 +24,8 @@ "pool_address": "0x286e8af6717ef6b1e361aae8ab28dd6664bf562c2805dd9a53432246ec66566e", "rewards_amount": "19174256316" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 1, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 1 }, { "sequence_number": 9823, @@ -40,9 +38,8 @@ "pool_address": "0x116176e2af223a8b7f8db80dc52f7a423b4d7f8c0553a1747e92ef58849aff4f", "rewards_amount": "19178730843" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 2, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 2 }, { "sequence_number": 3697, @@ -55,9 +52,8 @@ "pool_address": "0xba08cec00a8cfa1deff6c9212dda8d198c8fa6ee1992f3ada76d645f99e3402b", "rewards_amount": "818123890" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 3, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 3 }, { "sequence_number": 9813, @@ -70,9 +66,8 @@ "pool_address": "0x12000330d7cd8a748f46c25e6ce5d236a27e13d0b510d4516ac84ecc5fddd002", "rewards_amount": "19178287161" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 4, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 4 }, { "sequence_number": 14143, @@ -85,9 +80,8 @@ "pool_address": "0x5176f2252762e527e3598c22f1bdb3a1ac0ff0db2d7518cabbc99305330a864a", "rewards_amount": "963055869" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 5, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 5 }, { "sequence_number": 9812, @@ -100,9 +94,8 @@ "pool_address": "0xf0a156ed79ab6ccb5a643af48716263b565fd985ba36560966b4a91bdc8521f4", "rewards_amount": "19177688699" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 6, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 6 }, { "sequence_number": 7807, @@ -115,9 +108,8 @@ "pool_address": "0xa562415be88d9f08ba98fa3f6af9be0e36580c0f8fff5100a50b519e8f4a15c9", "rewards_amount": "841058926" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 7, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 7 }, { "sequence_number": 9823, @@ -130,9 +122,8 @@ "pool_address": "0x676f640c90cb6c45f21be50974531d440309aa4ddad919ae0429039789a3d8a9", "rewards_amount": "19178518163" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 8, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 8 }, { "sequence_number": 9829, @@ -145,9 +136,8 @@ "pool_address": "0x3c04549114877c55f45649aba48ac0a4ff086ab7bdce3b8cc8d3d9947bc0d99", "rewards_amount": "19185171265" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 9, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 9 }, { "sequence_number": 4252, @@ -160,9 +150,8 @@ "pool_address": "0x6d00a8a82bd0b6d187f9a328118ad61b5c80237362e8f5dd2454f2d3a1b03890", "rewards_amount": "19174925092" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 10, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 10 }, { "sequence_number": 8256, @@ -175,9 +164,8 @@ "pool_address": "0x7a2ddb6af66beb0d9987c6c9010cb9053454f067e16775a8ecf19961195c3d28", "rewards_amount": "18813123628" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 11, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 11 }, { "sequence_number": 8641, @@ -190,9 +178,8 @@ "pool_address": "0xeecd6e9fb71f3a67db6321e93deecf7a9d7c3f4fac6cd170deb3e8b183281943", "rewards_amount": "828031401" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 12, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 12 }, { "sequence_number": 1882, @@ -205,9 +192,8 @@ "pool_address": "0xfd47a2fb988c959839ea2fe4d7169b48536a42bf5e4933790701a08252ba2039", "rewards_amount": "798768182" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 13, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 13 }, { "sequence_number": 2197, @@ -220,9 +206,8 @@ "pool_address": "0x479ca442491cfd636f84fa8e56fa420c8038587e459e886d16a0b9d3993b16ba", "rewards_amount": "18896078163" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 14, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 14 }, { "sequence_number": 2199, @@ -235,9 +220,8 @@ "pool_address": "0x95a0e6b1105ba7ef9382e585d32e9dbf1a73833975af77d9b6924aa33468df07", "rewards_amount": "18894077814" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 15, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 15 }, { "sequence_number": 225, @@ -250,9 +234,8 @@ "pool_address": "0xb59c2db675c086d0c07b0f5d5ebd95ea9ead4429d836284fc4a576c4eed5799c", "rewards_amount": "787639333" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 16, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 16 }, { "sequence_number": 405, @@ -265,9 +248,8 @@ "pool_address": "0x50e52098d22c91f4c6a0065d03b2602cc2643089b218096e3cfe5f1bd98d80e6", "rewards_amount": "789473752" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 17, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 17 }, { "sequence_number": 330, @@ -280,9 +262,8 @@ "pool_address": "0xa5ed5d5e8c892165b18c2062596e8d1139fbb2cc451d430f787cd707122ce023", "rewards_amount": "787913628" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 18, - "indexed_type": "0x1::stake::DistributeRewardsEvent" + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 18 }, { "sequence_number": 16643, @@ -294,8 +275,7 @@ "data": { "epoch": "16644" }, - "inserted_at": "2024-10-15T05:16:56.188639", - "event_index": 19, - "indexed_type": "0x1::reconfiguration::NewEpochEvent" + "indexed_type": "0x1::reconfiguration::NewEpochEvent", + "event_index": 19 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json index b54fcc818..ed5feab5f 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5979639459/events.json @@ -13,9 +13,8 @@ "account_address": "0x1" } }, - "inserted_at": "2024-10-15T05:16:54.022853", - "event_index": 0, - "indexed_type": "0x1::account::CoinRegisterEvent" + "indexed_type": "0x1::account::CoinRegisterEvent", + "event_index": 0 }, { "sequence_number": 21684, @@ -27,9 +26,8 @@ "data": { "amount": "10" }, - "inserted_at": "2024-10-15T05:16:54.022853", - "event_index": 1, - "indexed_type": "0x1::coin::WithdrawEvent" + "indexed_type": "0x1::coin::WithdrawEvent", + "event_index": 1 }, { "sequence_number": 0, @@ -41,9 +39,8 @@ "data": { "amount": "10" }, - "inserted_at": "2024-10-15T05:16:54.022853", - "event_index": 2, - "indexed_type": "0x1::coin::DepositEvent" + "indexed_type": "0x1::coin::DepositEvent", + "event_index": 2 }, { "sequence_number": 0, @@ -59,8 +56,7 @@ "total_charge_gas_units": "999", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:16:54.022853", - "event_index": 3, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 3 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json index 8cb171550..dd105cc73 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/5992795934/events.json @@ -10,9 +10,8 @@ "store": "0x8bd5745daa2d6e5817819c6bf37600196e55cfba8c5bcdfdf55684bf4accbb9c", "amount": "100000000" }, - "inserted_at": "2024-10-15T05:16:55.191117", - "event_index": 0, - "indexed_type": "0x1::fungible_asset::Withdraw" + "indexed_type": "0x1::fungible_asset::Withdraw", + "event_index": 0 }, { "sequence_number": 0, @@ -25,9 +24,8 @@ "store": "0xfe90bdd996728b93e09f5d59fd91d6d44be85ab7acea5d1ed535b4c13b2c32c0", "amount": "100000000" }, - "inserted_at": "2024-10-15T05:16:55.191117", - "event_index": 1, - "indexed_type": "0x1::fungible_asset::Deposit" + "indexed_type": "0x1::fungible_asset::Deposit", + "event_index": 1 }, { "sequence_number": 0, @@ -43,8 +41,7 @@ "total_charge_gas_units": "12", "storage_fee_refund_octas": "0" }, - "inserted_at": "2024-10-15T05:16:55.191117", - "event_index": 2, - "indexed_type": "0x1::transaction_fee::FeeStatement" + "indexed_type": "0x1::transaction_fee::FeeStatement", + "event_index": 2 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/multi_txns_handling_test.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/multi_txns_handling_test.json new file mode 100644 index 000000000..338e7e633 --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/events_processor/multi_txns_handling_test.json @@ -0,0 +1,94 @@ +[ + { + "sequence_number": 1, + "creation_number": 3, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000001", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::block::NewBlockEvent", + "data": { + "hash": "0x1f4392dc07a74b39eaea58b912855cbbd1ab67e5089ae6166329e883c2085f0", + "epoch": "1", + "round": "3", + "height": "1", + "proposer": "0xdffe3c93b756bf6fec59b052d6fe71b40c3f9b7899d69ab06ba385b1c6728d16", + "time_microseconds": "1662686657227425", + "failed_proposer_indices": [ + "2", + "1" + ], + "previous_block_votes_bitvec": "0x00" + }, + "indexed_type": "0x1::block::NewBlockEvent", + "event_index": 0 + }, + { + "sequence_number": 0, + "creation_number": 12, + "account_address": "0xb7c7d12080209e9dc14498c80200706e760363fb31782247e82cf57d1d6e5d6c", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::stake::DistributeRewardsEvent", + "data": { + "pool_address": "0xb7c7d12080209e9dc14498c80200706e760363fb31782247e82cf57d1d6e5d6c", + "rewards_amount": "0" + }, + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 1 + }, + { + "sequence_number": 0, + "creation_number": 12, + "account_address": "0xdffe3c93b756bf6fec59b052d6fe71b40c3f9b7899d69ab06ba385b1c6728d16", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::stake::DistributeRewardsEvent", + "data": { + "pool_address": "0xdffe3c93b756bf6fec59b052d6fe71b40c3f9b7899d69ab06ba385b1c6728d16", + "rewards_amount": "4566200000" + }, + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 2 + }, + { + "sequence_number": 0, + "creation_number": 12, + "account_address": "0x828ca971e35c8b9a807439e5a328fdc9a5ed0efbfb12f40bc451d17f6998be3f", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::stake::DistributeRewardsEvent", + "data": { + "pool_address": "0x828ca971e35c8b9a807439e5a328fdc9a5ed0efbfb12f40bc451d17f6998be3f", + "rewards_amount": "0" + }, + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 3 + }, + { + "sequence_number": 0, + "creation_number": 12, + "account_address": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::stake::DistributeRewardsEvent", + "data": { + "pool_address": "0xacb107b98cd634ca32d39d38ab13df8cbcd5fe7856ce2a3c3d123e53f95d0b6f", + "rewards_amount": "0" + }, + "indexed_type": "0x1::stake::DistributeRewardsEvent", + "event_index": 4 + }, + { + "sequence_number": 1, + "creation_number": 2, + "account_address": "0x0000000000000000000000000000000000000000000000000000000000000001", + "transaction_version": 1, + "transaction_block_height": 1, + "type_": "0x1::reconfiguration::NewEpochEvent", + "data": { + "epoch": "2" + }, + "indexed_type": "0x1::reconfiguration::NewEpochEvent", + "event_index": 5 + } +] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1/coin_supply.json index 94ba261f3..05dd7f35b 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "18448344078275751615", "transaction_timestamp": "2022-09-09T01:24:17", - "transaction_epoch": 1, - "inserted_at": "2024-10-15T05:16:57.771610" + "transaction_epoch": 1 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/coin_supply.json index 5b418f2b1..937a86719 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "29152644549222814344", "transaction_timestamp": "2024-06-18T05:07:55", - "transaction_epoch": 15650, - "inserted_at": "2024-10-15T05:16:55.270115" + "transaction_epoch": 15650 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/current_fungible_asset_balances.json index 2cc36a315..e5c643eb6 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/current_fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/current_fungible_asset_balances.json @@ -8,8 +8,7 @@ "amount": "29450400", "last_transaction_timestamp": "2024-06-18T05:07:55", "last_transaction_version": 1255836496, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:55.264297" + "token_standard": "v1" }, { "storage_id": "0x56c216a20a151df2e917008e27f3b70250f1cbb80eeef24e64e2335630825fa3", @@ -20,8 +19,7 @@ "amount": "17374075418", "last_transaction_timestamp": "2024-06-18T05:07:55", "last_transaction_version": 1255836496, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:55.264297" + "token_standard": "v1" }, { "storage_id": "0x7ea259eaaacce518a7479baca008e17fab2d0267a16e11979d52eb6c5433aad6", @@ -32,8 +30,7 @@ "amount": "93054699", "last_transaction_timestamp": "2024-06-18T05:07:55", "last_transaction_version": 1255836496, - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.264297" + "token_standard": "v2" }, { "storage_id": "0x8f4f0991e18bd9620a4b3756dbe15afd20135eaaa93e0d0b82e6e2412a8e12b8", @@ -44,7 +41,6 @@ "amount": "17272186129", "last_transaction_timestamp": "2024-06-18T05:07:55", "last_transaction_version": 1255836496, - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.264297" + "token_standard": "v2" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json index 4aa6149e0..deda77d29 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:16:54.793594", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:16:54.793594", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 295534162, "token_standard": "v1", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:16:54.793594", "storage_refund_amount": "0" }, { @@ -72,7 +69,6 @@ "block_height": 295534162, "token_standard": "v2", "transaction_timestamp": "2024-06-18T05:07:55", - "inserted_at": "2024-10-15T05:16:54.793594", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_balances.json index 07d9814a4..2dd21aa02 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_balances.json @@ -9,8 +9,7 @@ "is_frozen": false, "amount": "17374075418", "transaction_timestamp": "2024-06-18T05:07:55", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:55.253856" + "token_standard": "v1" }, { "transaction_version": 1255836496, @@ -22,8 +21,7 @@ "is_frozen": false, "amount": "93054699", "transaction_timestamp": "2024-06-18T05:07:55", - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.253856" + "token_standard": "v2" }, { "transaction_version": 1255836496, @@ -35,8 +33,7 @@ "is_frozen": false, "amount": "17272186129", "transaction_timestamp": "2024-06-18T05:07:55", - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.253856" + "token_standard": "v2" }, { "transaction_version": 1255836496, @@ -48,7 +45,6 @@ "is_frozen": false, "amount": "29450400", "transaction_timestamp": "2024-06-18T05:07:55", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:55.253856" + "token_standard": "v1" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_metadata.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_metadata.json index 6f61d2773..3bbb1d851 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_metadata.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/1255836496/fungible_asset_metadata.json @@ -13,8 +13,7 @@ "supply_aggregator_table_key_v1": null, "token_standard": "v2", "is_token_v2": null, - "inserted_at": "2024-10-15T05:16:55.056027", - "supply_v2": "17374075418", - "maximum_v2": "340282366920938463463374607431768211455" + "maximum_v2": "340282366920938463463374607431768211455", + "supply_v2": "17374075418" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/coin_supply.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/current_fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_activities.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/2/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/coin_supply.json index 240eb07ab..c7455ae56 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "18544645433533405815", "transaction_timestamp": "2022-10-13T01:46:57", - "transaction_epoch": 746, - "inserted_at": "2024-10-15T05:16:56.913064" + "transaction_epoch": 746 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/current_fungible_asset_balances.json index a4834fa77..f45ae6826 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/current_fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/current_fungible_asset_balances.json @@ -8,8 +8,7 @@ "amount": "10041540182", "last_transaction_timestamp": "2022-10-13T01:46:57", "last_transaction_version": 278556781, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:56.910478" + "token_standard": "v1" }, { "storage_id": "0xfc6edbad85409914ab088b68fed0528e4d8e36dcee31075bb8252b4f426a6cff", @@ -20,7 +19,6 @@ "amount": "1000000000000000000", "last_transaction_timestamp": "2022-10-13T01:46:57", "last_transaction_version": 278556781, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:56.910478" + "token_standard": "v1" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json index 3de70092e..436b43072 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 20040326, "token_standard": "v1", "transaction_timestamp": "2022-10-13T01:46:57", - "inserted_at": "2024-10-15T05:16:56.507588", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 20040326, "token_standard": "v1", "transaction_timestamp": "2022-10-13T01:46:57", - "inserted_at": "2024-10-15T05:16:56.507588", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_balances.json index a837b8657..779d4957c 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_balances.json @@ -9,8 +9,7 @@ "is_frozen": false, "amount": "10041540182", "transaction_timestamp": "2022-10-13T01:46:57", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:56.905449" + "token_standard": "v1" }, { "transaction_version": 278556781, @@ -22,7 +21,6 @@ "is_frozen": false, "amount": "1000000000000000000", "transaction_timestamp": "2022-10-13T01:46:57", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:56.905449" + "token_standard": "v1" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_metadata.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_metadata.json index ae1143fb1..9733b88cd 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_metadata.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/278556781/fungible_asset_metadata.json @@ -13,8 +13,7 @@ "supply_aggregator_table_key_v1": null, "token_standard": "v1", "is_token_v2": null, - "inserted_at": "2024-10-15T05:16:56.771727", - "supply_v2": null, - "maximum_v2": null + "maximum_v2": null, + "supply_v2": null } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/coin_supply.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/current_fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_activities.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_balances.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/3/fungible_asset_metadata.json @@ -0,0 +1 @@ +[] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5523474016/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5523474016/coin_supply.json index 80a05f16c..3d51eb2f6 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5523474016/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5523474016/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "29159026553346716168", "transaction_timestamp": "2024-07-29T00:02:18", - "transaction_epoch": 16643, - "inserted_at": "2024-10-15T05:16:57.349833" + "transaction_epoch": 16643 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/coin_supply.json index 19c29be9d..04bab61ee 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "29164832318786122251", "transaction_timestamp": "2024-09-13T16:48:29", - "transaction_epoch": 17778, - "inserted_at": "2024-10-15T05:16:54.402430" + "transaction_epoch": 17778 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/current_fungible_asset_balances.json index a26ddda00..9727ea023 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/current_fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/current_fungible_asset_balances.json @@ -8,8 +8,7 @@ "amount": "10", "last_transaction_timestamp": "2024-09-13T16:48:29", "last_transaction_version": 5979639459, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:54.392129" + "token_standard": "v1" }, { "storage_id": "0x32edf0b123cd57094ba7b0b5a0b1524e0f2117b547adf65e8b0c08b39e30d242", @@ -20,7 +19,6 @@ "amount": "16673484350", "last_transaction_timestamp": "2024-09-13T16:48:29", "last_transaction_version": 5979639459, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:54.392129" + "token_standard": "v1" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json index 6c17156cd..5e99ebdf9 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:16:54.031990", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:16:54.031990", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 354619634, "token_standard": "v1", "transaction_timestamp": "2024-09-13T16:48:29", - "inserted_at": "2024-10-15T05:16:54.031990", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_balances.json index 53a1af128..9305714f7 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5979639459/fungible_asset_balances.json @@ -9,8 +9,7 @@ "is_frozen": false, "amount": "16673484350", "transaction_timestamp": "2024-09-13T16:48:29", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:54.313422" + "token_standard": "v1" }, { "transaction_version": 5979639459, @@ -22,7 +21,6 @@ "is_frozen": false, "amount": "10", "transaction_timestamp": "2024-09-13T16:48:29", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:54.313422" + "token_standard": "v1" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/coin_supply.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/coin_supply.json index 729a5959d..78207671f 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/coin_supply.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/coin_supply.json @@ -5,7 +5,6 @@ "coin_type": "0x1::aptos_coin::AptosCoin", "supply": "29165678689185321503", "transaction_timestamp": "2024-09-16T06:58:10", - "transaction_epoch": 17841, - "inserted_at": "2024-10-15T05:16:56.088926" + "transaction_epoch": 17841 } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/current_fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/current_fungible_asset_balances.json index 38d0269b9..fdb2aaccb 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/current_fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/current_fungible_asset_balances.json @@ -8,8 +8,7 @@ "amount": "18901942640", "last_transaction_timestamp": "2024-09-16T06:58:10", "last_transaction_version": 5992795934, - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:56.081056" + "token_standard": "v1" }, { "storage_id": "0x8bd5745daa2d6e5817819c6bf37600196e55cfba8c5bcdfdf55684bf4accbb9c", @@ -20,8 +19,7 @@ "amount": "0", "last_transaction_timestamp": "2024-09-16T06:58:10", "last_transaction_version": 5992795934, - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:56.081056" + "token_standard": "v2" }, { "storage_id": "0xfe90bdd996728b93e09f5d59fd91d6d44be85ab7acea5d1ed535b4c13b2c32c0", @@ -32,7 +30,6 @@ "amount": "9996985969300000000", "last_transaction_timestamp": "2024-09-16T06:58:10", "last_transaction_version": 5992795934, - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:56.081056" + "token_standard": "v2" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json index 3e6f92c89..bc3197a95 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_activities.json @@ -15,7 +15,6 @@ "block_height": 356437526, "token_standard": "v1", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:16:55.666070", "storage_refund_amount": "0" }, { @@ -34,7 +33,6 @@ "block_height": 356437526, "token_standard": "v2", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:16:55.666070", "storage_refund_amount": "0" }, { @@ -53,7 +51,6 @@ "block_height": 356437526, "token_standard": "v2", "transaction_timestamp": "2024-09-16T06:58:10", - "inserted_at": "2024-10-15T05:16:55.666070", "storage_refund_amount": "0" } ] \ No newline at end of file diff --git a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_balances.json b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_balances.json index 9ba1049a7..750b30768 100644 --- a/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_balances.json +++ b/rust/integration-tests/sdk_expected_db_output_files/imported_testnet_txns/fungible_asset_processor/5992795934/fungible_asset_balances.json @@ -9,8 +9,7 @@ "is_frozen": false, "amount": "0", "transaction_timestamp": "2024-09-16T06:58:10", - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.923614" + "token_standard": "v2" }, { "transaction_version": 5992795934, @@ -22,8 +21,7 @@ "is_frozen": false, "amount": "18901942640", "transaction_timestamp": "2024-09-16T06:58:10", - "token_standard": "v1", - "inserted_at": "2024-10-15T05:16:55.923614" + "token_standard": "v1" }, { "transaction_version": 5992795934, @@ -35,7 +33,6 @@ "is_frozen": false, "amount": "9996985969300000000", "transaction_timestamp": "2024-09-16T06:58:10", - "token_standard": "v2", - "inserted_at": "2024-10-15T05:16:55.923614" + "token_standard": "v2" } ] \ No newline at end of file diff --git a/rust/integration-tests/src/diff_test_helper/event_processor.rs b/rust/integration-tests/src/diff_test_helper/event_processor.rs index 28e9ea85c..7e764a668 100644 --- a/rust/integration-tests/src/diff_test_helper/event_processor.rs +++ b/rust/integration-tests/src/diff_test_helper/event_processor.rs @@ -10,15 +10,21 @@ use serde_json::Value; use std::collections::HashMap; #[allow(dead_code)] -pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result> { +pub fn load_data( + conn: &mut PgConnection, + txn_versions: Vec, +) -> Result> { let mut result_map: HashMap = HashMap::new(); let events_result = events - .filter(transaction_version.eq(txn_version.parse::().unwrap())) + .filter(transaction_version.eq_any(txn_versions)) + .then_order_by(transaction_version.asc()) .then_order_by(event_index.asc()) .load::(conn); let all_events = events_result?; + + println!("size of events: {}", all_events.len()); let events_json_data = serde_json::to_string_pretty(&all_events)?; result_map.insert( diff --git a/rust/integration-tests/src/diff_test_helper/fungible_asset_processor.rs b/rust/integration-tests/src/diff_test_helper/fungible_asset_processor.rs index 24a730350..188eb8fc3 100644 --- a/rust/integration-tests/src/diff_test_helper/fungible_asset_processor.rs +++ b/rust/integration-tests/src/diff_test_helper/fungible_asset_processor.rs @@ -17,12 +17,16 @@ use serde_json::Value; use std::collections::HashMap; #[allow(dead_code)] -pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result> { +pub fn load_data( + conn: &mut PgConnection, + txn_versions: Vec, +) -> Result> { let mut result_map: HashMap = HashMap::new(); // Query from fungible_asset_activities let fungible_asset_activities_result = faa_dsl::fungible_asset_activities - .filter(faa_dsl::transaction_version.eq(txn_version.parse::().unwrap())) + .filter(faa_dsl::transaction_version.eq_any(&txn_versions)) + .then_order_by(faa_dsl::transaction_version.asc()) .then_order_by(faa_dsl::event_index.asc()) .load::(conn); let all_fungible_asset_activities = fungible_asset_activities_result?; @@ -35,7 +39,8 @@ pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result().unwrap())) + .filter(fam_dsl::last_transaction_version.eq_any(&txn_versions)) + .then_order_by(fam_dsl::last_transaction_version.asc()) .load::(conn); let all_fungible_asset_metadata = fungible_asset_metadata_result?; let fungible_asset_metadata_json = serde_json::to_string_pretty(&all_fungible_asset_metadata)?; @@ -46,7 +51,8 @@ pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result().unwrap())) + .filter(fab_dsl::transaction_version.eq_any(&txn_versions)) + .then_order_by(fab_dsl::transaction_version.asc()) .load::(conn); let all_fungible_asset_balances = fungible_asset_balances_result?; let fungible_asset_balances_json = serde_json::to_string_pretty(&all_fungible_asset_balances)?; @@ -57,7 +63,8 @@ pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result().unwrap())) + .filter(cfab_dsl::last_transaction_version.eq_any(&txn_versions)) + .then_order_by(cfab_dsl::last_transaction_version.asc()) .load::(conn); let all_current_fungible_asset_balances = current_fungible_asset_balances_result?; let current_fungible_asset_balances_json = @@ -67,21 +74,10 @@ pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result().unwrap())) - // .load::(conn); - // let all_current_unified_fungible_asset_balances = current_unified_fungible_asset_balances_result?; - // let current_unified_fungible_asset_balances_json = serde_json::to_string_pretty(&all_current_unified_fungible_asset_balances)?; - // result_map.insert( - // "current_unified_fungible_asset_balances".to_string(), - // serde_json::from_str(¤t_unified_fungible_asset_balances_json)?, - // ); - // Query from coin_supply let coin_supply_result = cs_dsl::coin_supply - .filter(cs_dsl::transaction_version.eq(txn_version.parse::().unwrap())) + .filter(cs_dsl::transaction_version.eq_any(&txn_versions)) + .then_order_by(cs_dsl::transaction_version.asc()) .load::(conn); let all_coin_supply = coin_supply_result?; let coin_supply_json = serde_json::to_string_pretty(&all_coin_supply)?; diff --git a/rust/integration-tests/src/diff_test_helper/token_v2_processor.rs b/rust/integration-tests/src/diff_test_helper/token_v2_processor.rs index 7c96f7122..f312cad68 100644 --- a/rust/integration-tests/src/diff_test_helper/token_v2_processor.rs +++ b/rust/integration-tests/src/diff_test_helper/token_v2_processor.rs @@ -10,17 +10,23 @@ use serde_json::Value; use std::collections::HashMap; #[allow(dead_code)] -pub fn load_data(conn: &mut PgConnection, txn_version: &str) -> Result> { +pub fn load_data( + conn: &mut PgConnection, + txn_versions: Vec, +) -> Result> { let mut result_map: HashMap = HashMap::new(); + // Query to fetch token activities for multiple transaction versions let token_activities_v2_result = token_activities_v2 - .filter(transaction_version.eq(txn_version.parse::().unwrap())) + .filter(transaction_version.eq_any(&txn_versions)) + .then_order_by(transaction_version.asc()) .then_order_by(event_index.asc()) .load::(conn); - let all_collections_v2 = token_activities_v2_result?; - let token_activities_v2_json_data = serde_json::to_string_pretty(&all_collections_v2)?; + let all_token_activities_v2 = token_activities_v2_result?; + let token_activities_v2_json_data = serde_json::to_string_pretty(&all_token_activities_v2)?; + // Insert the JSON data into the result map result_map.insert( "token_activities_v2".to_string(), serde_json::from_str(&token_activities_v2_json_data)?, diff --git a/rust/integration-tests/src/diff_tests/all_tests.rs b/rust/integration-tests/src/diff_tests/all_tests.rs index cbf60125a..aa8e21b89 100644 --- a/rust/integration-tests/src/diff_tests/all_tests.rs +++ b/rust/integration-tests/src/diff_tests/all_tests.rs @@ -113,7 +113,7 @@ mod test { test_type, move |conn: &mut PgConnection, txn_version: &str| { - let mut db_values = match db_values_fn(conn, txn_version) { + let mut db_values = match db_values_fn(conn, vec![txn_version.parse::().unwrap()]) { Ok(db_data) => db_data, Err(e) => { eprintln!( @@ -136,6 +136,7 @@ mod test { txn_version, db_value, output_path.clone(), + None, )?; } diff --git a/rust/integration-tests/src/lib.rs b/rust/integration-tests/src/lib.rs index 995b57633..4f508d92f 100644 --- a/rust/integration-tests/src/lib.rs +++ b/rust/integration-tests/src/lib.rs @@ -16,7 +16,6 @@ mod diff_test_helper; mod diff_tests; mod models; mod scenarios_tests; - #[cfg(test)] mod sdk_tests; diff --git a/rust/integration-tests/src/sdk_tests/events_processor_tests.rs b/rust/integration-tests/src/sdk_tests/events_processor_tests.rs index 8538047b6..2b567dd94 100644 --- a/rust/integration-tests/src/sdk_tests/events_processor_tests.rs +++ b/rust/integration-tests/src/sdk_tests/events_processor_tests.rs @@ -1,28 +1,64 @@ +use ahash::AHashMap; +use aptos_indexer_testing_framework::sdk_test_context::SdkTestContext; +use sdk_processor::config::{ + db_config::{DbConfig, PostgresConfig}, + indexer_processor_config::IndexerProcessorConfig, + processor_config::{DefaultProcessorConfig, ProcessorConfig}, +}; +use std::collections::HashSet; + +pub fn setup_events_processor_config( + test_context: &SdkTestContext, + txn_version: u64, + txn_count: usize, + db_url: &str, +) -> (IndexerProcessorConfig, &'static str) { + let transaction_stream_config = + test_context.create_transaction_stream_config(txn_version, txn_count as u64); + let postgres_config = PostgresConfig { + connection_string: db_url.to_string(), + db_pool_size: 100, + }; + + let db_config = DbConfig::PostgresConfig(postgres_config); + let default_processor_config = DefaultProcessorConfig { + per_table_chunk_sizes: AHashMap::new(), + channel_size: 100, + deprecated_tables: HashSet::new(), + }; + + let processor_config = ProcessorConfig::EventsProcessor(default_processor_config); + let processor_name = processor_config.name(); + ( + IndexerProcessorConfig { + processor_config, + transaction_stream_config, + db_config, + }, + processor_name, + ) +} + #[allow(clippy::needless_return)] #[cfg(test)] mod tests { use crate::{ diff_test_helper::event_processor::load_data, sdk_tests::{ - run_processor_test, setup_test_environment, validate_json, DEFAULT_OUTPUT_FOLDER, + events_processor_tests::setup_events_processor_config, run_processor_test, + setup_test_environment, validate_json, DEFAULT_OUTPUT_FOLDER, }, }; - use ahash::AHashMap; - use aptos_indexer_test_transactions::ALL_IMPORTED_TESTNET_TXNS; + use aptos_indexer_test_transactions::{ + ALL_IMPORTED_TESTNET_TXNS, IMPORTED_TESTNET_TXNS_1_GENESIS, + IMPORTED_TESTNET_TXNS_2_GENESIS, IMPORTED_TESTNET_TXNS_3_GENESIS, + }; use aptos_indexer_testing_framework::{cli_parser::get_test_config, database::TestDatabase}; use aptos_protos::transaction::v1::Transaction; - use sdk_processor::{ - config::{ - db_config::{DbConfig, PostgresConfig}, - indexer_processor_config::IndexerProcessorConfig, - processor_config::{DefaultProcessorConfig, ProcessorConfig}, - }, - processors::events_processor::EventsProcessor, - }; - use std::collections::HashSet; + use sdk_processor::processors::events_processor::EventsProcessor; // This test cases runs the events processor and validates the output of all available transactions proto jsons - #[tokio::test] + #[tokio::test(flavor = "multi_thread", worker_threads = 2)] async fn testnet_events_processor_db_output_diff_test() { let (diff_flag, custom_output_path) = get_test_config(); let output_path = custom_output_path @@ -43,27 +79,8 @@ mod tests { // Step 3: Run the processor let db_url = db.get_db_url(); - let transaction_stream_config = - test_context.create_transaction_stream_config(txn_version); - let postgres_config = PostgresConfig { - connection_string: db_url.to_string(), - db_pool_size: 100, - }; - - let db_config = DbConfig::PostgresConfig(postgres_config); - let default_processor_config = DefaultProcessorConfig { - per_table_chunk_sizes: AHashMap::new(), - channel_size: 100, - deprecated_tables: HashSet::new(), - }; - - let processor_config = ProcessorConfig::EventsProcessor(default_processor_config); - let process_name = processor_config.name(); - let indexer_processor_config = IndexerProcessorConfig { - processor_config, - transaction_stream_config, - db_config, - }; + let (indexer_processor_config, processor_name) = + setup_events_processor_config(&test_context, txn_version, 1, &db_url); let events_processor = EventsProcessor::new(indexer_processor_config) .await @@ -73,10 +90,11 @@ mod tests { &mut test_context, events_processor, load_data, - &db_url, - txn_version, + db_url, + vec![txn_version as i64], diff_flag, output_path.clone(), + None, ) .await { @@ -84,7 +102,7 @@ mod tests { let _ = validate_json( &mut db_value, txn_version, - process_name, + processor_name, output_path.clone(), ); }, @@ -98,4 +116,54 @@ mod tests { } } } + + #[tokio::test(flavor = "multi_thread", worker_threads = 2)] + async fn testnet_events_processor_db_output_scenario_testing() { + let (diff_flag, custom_output_path) = get_test_config(); + let output_path = custom_output_path + .unwrap_or_else(|| format!("{}/imported_testnet_txns", DEFAULT_OUTPUT_FOLDER)); + + let imported = [ + IMPORTED_TESTNET_TXNS_1_GENESIS, + IMPORTED_TESTNET_TXNS_2_GENESIS, + IMPORTED_TESTNET_TXNS_3_GENESIS, + ]; + + let (db, mut test_context) = setup_test_environment(&imported).await; + + let transaction_batches: Vec = imported + .iter() + .map(|txn| serde_json::from_slice(txn).expect("Failed to deserialize transaction")) + .collect(); + + let starting_version = transaction_batches + .first() + .expect("No transactions found") + .version; + + let db_url = db.get_db_url(); + let (indexer_processor_config, _processor_name) = setup_events_processor_config( + &test_context, + starting_version, + transaction_batches.len(), + &db_url, + ); + + let events_processor = EventsProcessor::new(indexer_processor_config) + .await + .expect("Failed to create EventsProcessor"); + + // TODO: we can a validation here later. + let _ = run_processor_test( + &mut test_context, + events_processor, + load_data, + db_url, + vec![starting_version as i64], + diff_flag, + output_path, + Some("multi_txns_handling_test".to_string()), + ) + .await; + } } diff --git a/rust/integration-tests/src/sdk_tests/fungible_asset_processor_tests.rs b/rust/integration-tests/src/sdk_tests/fungible_asset_processor_tests.rs index 7ad4a4c5b..600c8c119 100644 --- a/rust/integration-tests/src/sdk_tests/fungible_asset_processor_tests.rs +++ b/rust/integration-tests/src/sdk_tests/fungible_asset_processor_tests.rs @@ -1,25 +1,59 @@ +use ahash::AHashMap; +use aptos_indexer_testing_framework::sdk_test_context::SdkTestContext; +use sdk_processor::config::{ + db_config::{DbConfig, PostgresConfig}, + indexer_processor_config::IndexerProcessorConfig, + processor_config::{DefaultProcessorConfig, ProcessorConfig}, +}; +use std::collections::HashSet; + +pub fn setup_fa_processor_config( + test_context: &SdkTestContext, + txn_version: u64, + txn_count: usize, + db_url: &str, +) -> (IndexerProcessorConfig, &'static str) { + let transaction_stream_config = + test_context.create_transaction_stream_config(txn_version, txn_count as u64); + let postgres_config = PostgresConfig { + connection_string: db_url.to_string(), + db_pool_size: 100, + }; + + let db_config = DbConfig::PostgresConfig(postgres_config); + let default_processor_config = DefaultProcessorConfig { + per_table_chunk_sizes: AHashMap::new(), + channel_size: 100, + deprecated_tables: HashSet::new(), + }; + + let processor_config = ProcessorConfig::FungibleAssetProcessor(default_processor_config); + + let processor_name = processor_config.name(); + ( + IndexerProcessorConfig { + processor_config, + transaction_stream_config, + db_config, + }, + processor_name, + ) +} + #[allow(clippy::needless_return)] #[cfg(test)] mod tests { use crate::{ diff_test_helper::fungible_asset_processor::load_data, sdk_tests::{ - run_processor_test, setup_test_environment, validate_json, DEFAULT_OUTPUT_FOLDER, + fungible_asset_processor_tests::setup_fa_processor_config, run_processor_test, + setup_test_environment, validate_json, DEFAULT_OUTPUT_FOLDER, }, }; - use ahash::AHashMap; use aptos_indexer_test_transactions::ALL_IMPORTED_TESTNET_TXNS; use aptos_indexer_testing_framework::{cli_parser::get_test_config, database::TestDatabase}; use aptos_protos::transaction::v1::Transaction; - use sdk_processor::{ - config::{ - db_config::{DbConfig, PostgresConfig}, - indexer_processor_config::IndexerProcessorConfig, - processor_config::{DefaultProcessorConfig, ProcessorConfig}, - }, - processors::fungible_asset_processor::FungibleAssetProcessor, - }; - use std::collections::HashSet; + use sdk_processor::processors::fungible_asset_processor::FungibleAssetProcessor; #[tokio::test] async fn fa_processor_db_output_diff_test() { @@ -41,28 +75,8 @@ mod tests { // Step 3: Run the processor let db_url = db.get_db_url(); - let transaction_stream_config = - test_context.create_transaction_stream_config(txn_version); - let postgres_config = PostgresConfig { - connection_string: db_url.to_string(), - db_pool_size: 100, - }; - - let db_config = DbConfig::PostgresConfig(postgres_config); - let default_processor_config = DefaultProcessorConfig { - per_table_chunk_sizes: AHashMap::new(), - channel_size: 100, - deprecated_tables: HashSet::new(), - }; - - let processor_config = - ProcessorConfig::FungibleAssetProcessor(default_processor_config); - - let indexer_processor_config = IndexerProcessorConfig { - processor_config, - transaction_stream_config, - db_config, - }; + let (indexer_processor_config, processor_name) = + setup_fa_processor_config(&test_context, txn_version, 1, &db_url); let fungible_asset_processor = FungibleAssetProcessor::new(indexer_processor_config) .await @@ -72,10 +86,11 @@ mod tests { &mut test_context, fungible_asset_processor, load_data, - &db_url, - txn_version, + db_url, + vec![txn_version as i64], diff_flag, output_path.clone(), + None, ) .await { @@ -83,7 +98,7 @@ mod tests { let _ = validate_json( &mut db_value, txn_version, - "fungible_asset_processor", + processor_name, output_path.clone(), ); }, diff --git a/rust/integration-tests/src/sdk_tests/mod.rs b/rust/integration-tests/src/sdk_tests/mod.rs index f60333cf3..a282052ae 100644 --- a/rust/integration-tests/src/sdk_tests/mod.rs +++ b/rust/integration-tests/src/sdk_tests/mod.rs @@ -9,13 +9,15 @@ use diesel::{Connection, PgConnection}; use serde_json::Value; use std::{collections::HashMap, fs, path::Path}; -mod events_processor_tests; -mod fungible_asset_processor_tests; -mod test_cli_flag_util; +#[cfg(test)] +pub mod events_processor_tests; +#[cfg(test)] +pub mod fungible_asset_processor_tests; #[allow(dead_code)] -const DEFAULT_OUTPUT_FOLDER: &str = "sdk_expected_db_output_files/"; +pub const DEFAULT_OUTPUT_FOLDER: &str = "sdk_expected_db_output_files/"; +#[allow(dead_code)] pub fn read_and_parse_json(path: &str) -> anyhow::Result { match fs::read_to_string(path) { Ok(content) => match serde_json::from_str::(&content) { @@ -33,7 +35,10 @@ pub fn read_and_parse_json(path: &str) -> anyhow::Result { } // Common setup for database and test context -async fn setup_test_environment(transactions: &[&[u8]]) -> (PostgresTestDatabase, SdkTestContext) { +#[allow(dead_code)] +pub async fn setup_test_environment( + transactions: &[&[u8]], +) -> (PostgresTestDatabase, SdkTestContext) { let mut db = PostgresTestDatabase::new(); db.setup().await.unwrap(); @@ -42,7 +47,8 @@ async fn setup_test_environment(transactions: &[&[u8]]) -> (PostgresTestDatabase (db, test_context) } -fn validate_json( +#[allow(dead_code)] +pub fn validate_json( db_values: &mut HashMap, txn_version: u64, processor_name: &str, @@ -78,52 +84,50 @@ fn validate_json( } // Helper function to configure and run the processor -async fn run_processor_test( +#[allow(dead_code)] +pub async fn run_processor_test( test_context: &mut SdkTestContext, processor: impl ProcessorTrait, load_data: F, - db_url: &str, - txn_version: u64, - diff_flag: bool, + db_url: String, + txn_versions: Vec, + generate_file_flag: bool, output_path: String, + custom_file_name: Option, ) -> anyhow::Result> where - F: Fn(&mut PgConnection, &str) -> anyhow::Result> + F: Fn(&mut PgConnection, Vec) -> anyhow::Result> + Send + Sync + 'static, { - println!( - "[INFO] Running {} test for transaction version: {}", - processor.name(), - txn_version - ); - - let db_value = test_context + let db_values = test_context .run( &processor, - db_url, - txn_version, - diff_flag, + txn_versions[0] as u64, + generate_file_flag, output_path.clone(), - move |db_url| { + custom_file_name, + move || { // TODO: might not need this. let mut conn = - PgConnection::establish(db_url).expect("Failed to establish DB connection"); + PgConnection::establish(&db_url).expect("Failed to establish DB connection"); + + let starting_version = txn_versions[0]; + let ending_version = txn_versions[txn_versions.len() - 1]; - let db_values = match load_data(&mut conn, &txn_version.to_string()) { + let db_values = match load_data(&mut conn, txn_versions) { Ok(db_data) => db_data, Err(e) => { eprintln!( - "[ERROR] Failed to load data for transaction version {}: {}", - txn_version, e + "[ERROR] Failed to load data {}", e ); return Err(e); }, }; if db_values.is_empty() { - eprintln!("[WARNING] No data found for txn version: {}", txn_version); + eprintln!("[WARNING] No data found for starting txn version: {} and ending txn version {}", starting_version, ending_version); } Ok(db_values) @@ -131,5 +135,5 @@ where ) .await?; - Ok(db_value) + Ok(db_values) } diff --git a/rust/integration-tests/src/sdk_tests/test_cli_flag_util.rs b/rust/integration-tests/src/sdk_tests/test_cli_flag_util.rs deleted file mode 100644 index c84793565..000000000 --- a/rust/integration-tests/src/sdk_tests/test_cli_flag_util.rs +++ /dev/null @@ -1,43 +0,0 @@ -#[allow(dead_code)] -#[derive(Debug, Clone)] -pub struct TestArgs { - pub generate_output: bool, - pub output_path: Option, -} - -#[allow(dead_code)] -pub fn parse_test_args() -> TestArgs { - // Capture the raw arguments - let raw_args: Vec = std::env::args().collect(); - - // Log the raw arguments for debugging - println!("Raw arguments: {:?}", raw_args); - - // Find the "--" separator (if it exists) - let clap_args_position = raw_args.iter().position(|arg| arg == "--"); - - // Only pass the arguments that come after "--", if it exists - let custom_args: Vec = match clap_args_position { - Some(position) => raw_args[position + 1..].to_vec(), // Slice after `--` - None => Vec::new(), // If no `--` is found, treat as no custom args - }; - println!("Custom arguments: {:?}", custom_args); - - // Manually parse the "--generate-output" flag - let generate_output_flag = custom_args.contains(&"--generate-output".to_string()); - - // Manually parse the "--output-path" flag and get its associated value - let output_path = custom_args - .windows(2) - .find(|args| args[0] == "--output-path") - .map(|args| args[1].clone()); // Correct the flag name to `--output-path` - - // Log the parsed values - println!("Parsed generate_output_flag: {}", generate_output_flag); - println!("Parsed output_path: {:?}", output_path); - - TestArgs { - generate_output: generate_output_flag, - output_path, - } -}