WholeStageCodegen (7) duration: 1 ms WholeStageCodegen (6) duration: total (min, med, max (stageId: taskId) ) 211 ms (0 ms, 0 ms, 7 ms (stage 38.0: task 2459) ) WholeStageCodegen (5) duration: total (min, med, max (stageId: taskId) ) 1.2 s (4 ms, 6 ms, 31 ms (stage 33.0: task 2040) ) WholeStageCodegen (2) duration: total (min, med, max (stageId: taskId) ) 511 ms (0 ms, 3 ms, 55 ms (stage 33.0: task 2040) ) WholeStageCodegen (1) duration: total (min, med, max (stageId: taskId) ) 7.0 s (133 ms, 1.6 s, 2.1 s (stage 31.0: task 2035) ) WholeStageCodegen (4) duration: total (min, med, max (stageId: taskId) ) 470 ms (0 ms, 2 ms, 52 ms (stage 33.0: task 2040) ) WholeStageCodegen (3) duration: total (min, med, max (stageId: taskId) ) 2.4 s (1.2 s, 1.3 s, 1.3 s (stage 32.0: task 2037) ) Execute InsertIntoHadoopFsRelationCommand number of written files: 1 written output: 1038.0 B number of output rows: 31 number of dynamic part: 0
Coalesce
Sort sort time: 0 ms peak memory: 1985.9 MiB spill size: 0.0 B
Exchange shuffle records written: 31 shuffle write time total (min, med, max (stageId: taskId) ) 14 ms (0 ms, 0 ms, 0 ms (stage 38.0: task 2447) ) records read: 31 local bytes read: 1427.0 B fetch wait time: 0 ms remote bytes read: 1176.0 B local blocks read: 17 remote blocks read: 14 data size total (min, med, max (stageId: taskId) ) 1240.0 B (0.0 B, 0.0 B, 120.0 B (stage 38.0: task 2447) ) shuffle bytes written total (min, med, max (stageId: taskId) ) 2.5 KiB (0.0 B, 0.0 B, 252.0 B (stage 38.0: task 2447) )
HashAggregate time in aggregation build total (min, med, max (stageId: taskId) ) 147 ms (0 ms, 0 ms, 5 ms (stage 38.0: task 2459) ) peak memory total (min, med, max (stageId: taskId) ) 3.6 GiB (256.0 KiB, 256.0 KiB, 64.3 MiB (stage 38.0: task 2440) ) number of output rows: 62 avg hash probe bucket list iters (min, med, max (stageId: taskId) ): (1, 1, 1 (stage 38.0: task 2440) )
Exchange shuffle records written: 6,200 shuffle write time total (min, med, max (stageId: taskId) ) 703 ms (3 ms, 3 ms, 8 ms (stage 33.0: task 2086) ) records read: 12,400 local bytes read total (min, med, max (stageId: taskId) ) 467.1 KiB (0.0 B, 0.0 B, 13.0 KiB (stage 38.0: task 2447) ) fetch wait time total (min, med, max (stageId: taskId) ) 0 ms (0 ms, 0 ms, 0 ms (stage 38.0: task 2440) ) remote bytes read total (min, med, max (stageId: taskId) ) 467.8 KiB (0.0 B, 0.0 B, 11.1 KiB (stage 38.0: task 2447) ) local blocks read: 5,584 remote blocks read: 5,616 data size total (min, med, max (stageId: taskId) ) 242.2 KiB (1240.0 B, 1240.0 B, 1240.0 B (stage 33.0: task 2039) ) shuffle bytes written total (min, med, max (stageId: taskId) ) 467.5 KiB (2.3 KiB, 2.3 KiB, 2.3 KiB (stage 33.0: task 2114) )
HashAggregate time in aggregation build total (min, med, max (stageId: taskId) ) 227 ms (1 ms, 1 ms, 24 ms (stage 33.0: task 2040) ) peak memory total (min, med, max (stageId: taskId) ) 50.0 MiB (256.0 KiB, 256.0 KiB, 256.0 KiB (stage 33.0: task 2039) ) number of output rows: 6,200
Project
SortMergeJoin number of output rows: 72,118
Sort sort time total (min, med, max (stageId: taskId) ) 0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039) ) peak memory total (min, med, max (stageId: taskId) ) 12.5 GiB (64.1 MiB, 64.1 MiB, 64.1 MiB (stage 33.0: task 2039) ) spill size total (min, med, max (stageId: taskId) ) 0.0 B (0.0 B, 0.0 B, 0.0 B (stage 33.0: task 2039) )
Exchange shuffle records written: 156,095 shuffle write time total (min, med, max (stageId: taskId) ) 28 ms (0 ms, 0 ms, 15 ms (stage 31.0: task 2035) ) records read: 156,095 local bytes read total (min, med, max (stageId: taskId) ) 5.1 MiB (15.9 KiB, 30.8 KiB, 36.6 KiB (stage 33.0: task 2171) ) fetch wait time total (min, med, max (stageId: taskId) ) 0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039) ) remote bytes read total (min, med, max (stageId: taskId) ) 4.9 MiB (16.2 KiB, 19.9 KiB, 37.5 KiB (stage 33.0: task 2111) ) local blocks read: 200 remote blocks read: 200 data size total (min, med, max (stageId: taskId) ) 16.7 MiB (0.0 B, 0.0 B, 10.7 MiB (stage 31.0: task 2035) ) shuffle bytes written total (min, med, max (stageId: taskId) ) 10.0 MiB (0.0 B, 0.0 B, 6.4 MiB (stage 31.0: task 2035) )
Project
Filter number of output rows: 156,095
Scan csv number of files read: 1 metadata time: 0 ms size of files read: 519.0 MiB number of output rows: 500,001
Sort sort time total (min, med, max (stageId: taskId) ) 0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039) ) peak memory total (min, med, max (stageId: taskId) ) 12.5 GiB (64.1 MiB, 64.1 MiB, 64.1 MiB (stage 33.0: task 2039) ) spill size total (min, med, max (stageId: taskId) ) 0.0 B (0.0 B, 0.0 B, 0.0 B (stage 33.0: task 2039) )
Exchange shuffle records written: 171,282 shuffle write time total (min, med, max (stageId: taskId) ) 30 ms (15 ms, 15 ms, 15 ms (stage 32.0: task 2037) ) records read: 171,282 local bytes read total (min, med, max (stageId: taskId) ) 5.9 MiB (25.5 KiB, 29.7 KiB, 36.3 KiB (stage 33.0: task 2209) ) fetch wait time total (min, med, max (stageId: taskId) ) 0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039) ) remote bytes read total (min, med, max (stageId: taskId) ) 5.9 MiB (24.8 KiB, 30.2 KiB, 36.4 KiB (stage 33.0: task 2148) ) local blocks read: 200 remote blocks read: 200 data size total (min, med, max (stageId: taskId) ) 20.9 MiB (10.1 MiB, 10.8 MiB, 10.8 MiB (stage 32.0: task 2037) ) shuffle bytes written total (min, med, max (stageId: taskId) ) 11.8 MiB (5.6 MiB, 6.2 MiB, 6.2 MiB (stage 32.0: task 2037) )
Project
Filter number of output rows: 171,282
Scan csv number of files read: 1 metadata time: 0 ms size of files read: 173.6 MiB number of output rows: 504,708
digraph G {
0 [labelType="html" label="<b>Execute InsertIntoHadoopFsRelationCommand</b><br><br>number of written files: 1<br>written output: 1038.0 B<br>number of output rows: 31<br>number of dynamic part: 0"];
1 [labelType="html" label="<br><b>Coalesce</b><br><br>"];
subgraph cluster2 {
isCluster="true";
label="WholeStageCodegen (7)\n \nduration: 1 ms";
3 [labelType="html" label="<b>Sort</b><br><br>sort time: 0 ms<br>peak memory: 1985.9 MiB<br>spill size: 0.0 B"];
}
4 [labelType="html" label="<b>Exchange</b><br><br>shuffle records written: 31<br>shuffle write time total (min, med, max (stageId: taskId))<br>14 ms (0 ms, 0 ms, 0 ms (stage 38.0: task 2447))<br>records read: 31<br>local bytes read: 1427.0 B<br>fetch wait time: 0 ms<br>remote bytes read: 1176.0 B<br>local blocks read: 17<br>remote blocks read: 14<br>data size total (min, med, max (stageId: taskId))<br>1240.0 B (0.0 B, 0.0 B, 120.0 B (stage 38.0: task 2447))<br>shuffle bytes written total (min, med, max (stageId: taskId))<br>2.5 KiB (0.0 B, 0.0 B, 252.0 B (stage 38.0: task 2447))"];
subgraph cluster5 {
isCluster="true";
label="WholeStageCodegen (6)\n \nduration: total (min, med, max (stageId: taskId))\n211 ms (0 ms, 0 ms, 7 ms (stage 38.0: task 2459))";
6 [labelType="html" label="<b>HashAggregate</b><br><br>time in aggregation build total (min, med, max (stageId: taskId))<br>147 ms (0 ms, 0 ms, 5 ms (stage 38.0: task 2459))<br>peak memory total (min, med, max (stageId: taskId))<br>3.6 GiB (256.0 KiB, 256.0 KiB, 64.3 MiB (stage 38.0: task 2440))<br>number of output rows: 62<br>avg hash probe bucket list iters (min, med, max (stageId: taskId)):<br>(1, 1, 1 (stage 38.0: task 2440))"];
}
7 [labelType="html" label="<b>Exchange</b><br><br>shuffle records written: 6,200<br>shuffle write time total (min, med, max (stageId: taskId))<br>703 ms (3 ms, 3 ms, 8 ms (stage 33.0: task 2086))<br>records read: 12,400<br>local bytes read total (min, med, max (stageId: taskId))<br>467.1 KiB (0.0 B, 0.0 B, 13.0 KiB (stage 38.0: task 2447))<br>fetch wait time total (min, med, max (stageId: taskId))<br>0 ms (0 ms, 0 ms, 0 ms (stage 38.0: task 2440))<br>remote bytes read total (min, med, max (stageId: taskId))<br>467.8 KiB (0.0 B, 0.0 B, 11.1 KiB (stage 38.0: task 2447))<br>local blocks read: 5,584<br>remote blocks read: 5,616<br>data size total (min, med, max (stageId: taskId))<br>242.2 KiB (1240.0 B, 1240.0 B, 1240.0 B (stage 33.0: task 2039))<br>shuffle bytes written total (min, med, max (stageId: taskId))<br>467.5 KiB (2.3 KiB, 2.3 KiB, 2.3 KiB (stage 33.0: task 2114))"];
subgraph cluster8 {
isCluster="true";
label="WholeStageCodegen (5)\n \nduration: total (min, med, max (stageId: taskId))\n1.2 s (4 ms, 6 ms, 31 ms (stage 33.0: task 2040))";
9 [labelType="html" label="<b>HashAggregate</b><br><br>time in aggregation build total (min, med, max (stageId: taskId))<br>227 ms (1 ms, 1 ms, 24 ms (stage 33.0: task 2040))<br>peak memory total (min, med, max (stageId: taskId))<br>50.0 MiB (256.0 KiB, 256.0 KiB, 256.0 KiB (stage 33.0: task 2039))<br>number of output rows: 6,200"];
10 [labelType="html" label="<br><b>Project</b><br><br>"];
11 [labelType="html" label="<b>SortMergeJoin</b><br><br>number of output rows: 72,118"];
}
subgraph cluster12 {
isCluster="true";
label="WholeStageCodegen (2)\n \nduration: total (min, med, max (stageId: taskId))\n511 ms (0 ms, 3 ms, 55 ms (stage 33.0: task 2040))";
13 [labelType="html" label="<b>Sort</b><br><br>sort time total (min, med, max (stageId: taskId))<br>0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039))<br>peak memory total (min, med, max (stageId: taskId))<br>12.5 GiB (64.1 MiB, 64.1 MiB, 64.1 MiB (stage 33.0: task 2039))<br>spill size total (min, med, max (stageId: taskId))<br>0.0 B (0.0 B, 0.0 B, 0.0 B (stage 33.0: task 2039))"];
}
14 [labelType="html" label="<b>Exchange</b><br><br>shuffle records written: 156,095<br>shuffle write time total (min, med, max (stageId: taskId))<br>28 ms (0 ms, 0 ms, 15 ms (stage 31.0: task 2035))<br>records read: 156,095<br>local bytes read total (min, med, max (stageId: taskId))<br>5.1 MiB (15.9 KiB, 30.8 KiB, 36.6 KiB (stage 33.0: task 2171))<br>fetch wait time total (min, med, max (stageId: taskId))<br>0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039))<br>remote bytes read total (min, med, max (stageId: taskId))<br>4.9 MiB (16.2 KiB, 19.9 KiB, 37.5 KiB (stage 33.0: task 2111))<br>local blocks read: 200<br>remote blocks read: 200<br>data size total (min, med, max (stageId: taskId))<br>16.7 MiB (0.0 B, 0.0 B, 10.7 MiB (stage 31.0: task 2035))<br>shuffle bytes written total (min, med, max (stageId: taskId))<br>10.0 MiB (0.0 B, 0.0 B, 6.4 MiB (stage 31.0: task 2035))"];
subgraph cluster15 {
isCluster="true";
label="WholeStageCodegen (1)\n \nduration: total (min, med, max (stageId: taskId))\n7.0 s (133 ms, 1.6 s, 2.1 s (stage 31.0: task 2035))";
16 [labelType="html" label="<br><b>Project</b><br><br>"];
17 [labelType="html" label="<b>Filter</b><br><br>number of output rows: 156,095"];
}
18 [labelType="html" label="<b>Scan csv </b><br><br>number of files read: 1<br>metadata time: 0 ms<br>size of files read: 519.0 MiB<br>number of output rows: 500,001"];
subgraph cluster19 {
isCluster="true";
label="WholeStageCodegen (4)\n \nduration: total (min, med, max (stageId: taskId))\n470 ms (0 ms, 2 ms, 52 ms (stage 33.0: task 2040))";
20 [labelType="html" label="<b>Sort</b><br><br>sort time total (min, med, max (stageId: taskId))<br>0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039))<br>peak memory total (min, med, max (stageId: taskId))<br>12.5 GiB (64.1 MiB, 64.1 MiB, 64.1 MiB (stage 33.0: task 2039))<br>spill size total (min, med, max (stageId: taskId))<br>0.0 B (0.0 B, 0.0 B, 0.0 B (stage 33.0: task 2039))"];
}
21 [labelType="html" label="<b>Exchange</b><br><br>shuffle records written: 171,282<br>shuffle write time total (min, med, max (stageId: taskId))<br>30 ms (15 ms, 15 ms, 15 ms (stage 32.0: task 2037))<br>records read: 171,282<br>local bytes read total (min, med, max (stageId: taskId))<br>5.9 MiB (25.5 KiB, 29.7 KiB, 36.3 KiB (stage 33.0: task 2209))<br>fetch wait time total (min, med, max (stageId: taskId))<br>0 ms (0 ms, 0 ms, 0 ms (stage 33.0: task 2039))<br>remote bytes read total (min, med, max (stageId: taskId))<br>5.9 MiB (24.8 KiB, 30.2 KiB, 36.4 KiB (stage 33.0: task 2148))<br>local blocks read: 200<br>remote blocks read: 200<br>data size total (min, med, max (stageId: taskId))<br>20.9 MiB (10.1 MiB, 10.8 MiB, 10.8 MiB (stage 32.0: task 2037))<br>shuffle bytes written total (min, med, max (stageId: taskId))<br>11.8 MiB (5.6 MiB, 6.2 MiB, 6.2 MiB (stage 32.0: task 2037))"];
subgraph cluster22 {
isCluster="true";
label="WholeStageCodegen (3)\n \nduration: total (min, med, max (stageId: taskId))\n2.4 s (1.2 s, 1.3 s, 1.3 s (stage 32.0: task 2037))";
23 [labelType="html" label="<br><b>Project</b><br><br>"];
24 [labelType="html" label="<b>Filter</b><br><br>number of output rows: 171,282"];
}
25 [labelType="html" label="<b>Scan csv </b><br><br>number of files read: 1<br>metadata time: 0 ms<br>size of files read: 173.6 MiB<br>number of output rows: 504,708"];
1->0;
3->1;
4->3;
6->4;
7->6;
9->7;
10->9;
11->10;
13->11;
14->13;
16->14;
17->16;
18->17;
20->11;
21->20;
23->21;
24->23;
25->24;
}
26
Execute InsertIntoHadoopFsRelationCommand s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october, false, CSV, Map(header -> true, path -> s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october), Overwrite, [formatted_date, total_transaction_fee]
Coalesce 1
Sort [formatted_date#136 ASC NULLS FIRST], true, 0
WholeStageCodegen (7)
Exchange rangepartitioning(formatted_date#136 ASC NULLS FIRST, 200), true, [id=#442]
HashAggregate(keys=[formatted_date#136], functions=[sum(transaction_fee#390)])
WholeStageCodegen (6)
Exchange hashpartitioning(formatted_date#136, 200), true, [id=#438]
HashAggregate(keys=[formatted_date#136], functions=[partial_sum(transaction_fee#390)])
Project [formatted_date#136, (cast(gas#78 as double) * cast(gas_price#79 as double)) AS transaction_fee#390]
SortMergeJoin [hash#17], [block_hash#72], Inner
WholeStageCodegen (5)
Sort [hash#17 ASC NULLS FIRST], false, 0
WholeStageCodegen (2)
Exchange hashpartitioning(hash#17, 200), true, [id=#420]
Project [hash#17, date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) AS formatted_date#136]
Filter (((date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) >= 2015-10-01) AND (date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) <= 2015-10-31)) AND isnotnull(hash#17))
WholeStageCodegen (1)
FileScan csv [hash#17,timestamp#32] Batched: false, DataFilters: [(date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as..., Format: CSV, Location: InMemoryFileIndex[s3a://data-repository-bkt/ECS765/ethereum/blocks.csv], PartitionFilters: [], PushedFilters: [IsNotNull(hash)], ReadSchema: struct<hash:string,timestamp:string>
Sort [block_hash#72 ASC NULLS FIRST], false, 0
WholeStageCodegen (4)
Exchange hashpartitioning(block_hash#72, 200), true, [id=#429]
Project [block_hash#72, gas#78, gas_price#79]
Filter ((isnotnull(transaction_index#74) AND (cast(transaction_index#74 as int) = 0)) AND isnotnull(block_hash#72))
WholeStageCodegen (3)
FileScan csv [block_hash#72,transaction_index#74,gas#78,gas_price#79] Batched: false, DataFilters: [isnotnull(transaction_index#74), (cast(transaction_index#74 as int) = 0), isnotnull(block_hash#72)], Format: CSV, Location: InMemoryFileIndex[s3a://data-repository-bkt/ECS765/ethereum/transactions.csv], PartitionFilters: [], PushedFilters: [IsNotNull(transaction_index), IsNotNull(block_hash)], ReadSchema: struct<block_hash:string,transaction_index:string,gas:string,gas_price:string>
== Parsed Logical Plan ==
InsertIntoHadoopFsRelationCommand s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october, false, CSV, Map(header -> true, path -> s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october), Overwrite, [formatted_date, total_transaction_fee]
+- Repartition 1, false
+- Sort [formatted_date#136 ASC NULLS FIRST], true
+- Aggregate [formatted_date#136], [formatted_date#136, sum(transaction_fee#390) AS total_transaction_fee#464]
+- Project [number#16, hash#17, parent_hash#18, nonce#19, sha3_uncles#20, logs_bloom#21, transactions_root#22, state_root#23, receipts_root#24, miner#25, difficulty#26, total_difficulty#27, size#28, extra_data#29, gas_limit#30, gas_used#31, timestamp#32, transaction_count#33, base_fee_per_gas#34, formatted_date#136, hash#70, nonce#71, block_hash#72, block_number#73, ... 12 more fields]
+- Filter (((formatted_date#136 >= 2015-10-01) AND (formatted_date#136 <= 2015-10-31)) AND (cast(transaction_index#74 as int) = 0))
+- Join Inner, (hash#17 = block_hash#72)
:- Project [number#16, hash#17, parent_hash#18, nonce#19, sha3_uncles#20, logs_bloom#21, transactions_root#22, state_root#23, receipts_root#24, miner#25, difficulty#26, total_difficulty#27, size#28, extra_data#29, gas_limit#30, gas_used#31, timestamp#32, transaction_count#33, base_fee_per_gas#34, date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) AS formatted_date#136]
: +- Relation[number#16,hash#17,parent_hash#18,nonce#19,sha3_uncles#20,logs_bloom#21,transactions_root#22,state_root#23,receipts_root#24,miner#25,difficulty#26,total_difficulty#27,size#28,extra_data#29,gas_limit#30,gas_used#31,timestamp#32,transaction_count#33,base_fee_per_gas#34] csv
+- Relation[hash#70,nonce#71,block_hash#72,block_number#73,transaction_index#74,from_address#75,to_address#76,value#77,gas#78,gas_price#79,input#80,block_timestamp#81,max_fee_per_gas#82,max_priority_fee_per_gas#83,transaction_type#84] csv
== Analyzed Logical Plan ==
InsertIntoHadoopFsRelationCommand s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october, false, CSV, Map(header -> true, path -> s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october), Overwrite, [formatted_date, total_transaction_fee]
+- Repartition 1, false
+- Sort [formatted_date#136 ASC NULLS FIRST], true
+- Aggregate [formatted_date#136], [formatted_date#136, sum(transaction_fee#390) AS total_transaction_fee#464]
+- Project [number#16, hash#17, parent_hash#18, nonce#19, sha3_uncles#20, logs_bloom#21, transactions_root#22, state_root#23, receipts_root#24, miner#25, difficulty#26, total_difficulty#27, size#28, extra_data#29, gas_limit#30, gas_used#31, timestamp#32, transaction_count#33, base_fee_per_gas#34, formatted_date#136, hash#70, nonce#71, block_hash#72, block_number#73, ... 12 more fields]
+- Filter (((formatted_date#136 >= 2015-10-01) AND (formatted_date#136 <= 2015-10-31)) AND (cast(transaction_index#74 as int) = 0))
+- Join Inner, (hash#17 = block_hash#72)
:- Project [number#16, hash#17, parent_hash#18, nonce#19, sha3_uncles#20, logs_bloom#21, transactions_root#22, state_root#23, receipts_root#24, miner#25, difficulty#26, total_difficulty#27, size#28, extra_data#29, gas_limit#30, gas_used#31, timestamp#32, transaction_count#33, base_fee_per_gas#34, date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) AS formatted_date#136]
: +- Relation[number#16,hash#17,parent_hash#18,nonce#19,sha3_uncles#20,logs_bloom#21,transactions_root#22,state_root#23,receipts_root#24,miner#25,difficulty#26,total_difficulty#27,size#28,extra_data#29,gas_limit#30,gas_used#31,timestamp#32,transaction_count#33,base_fee_per_gas#34] csv
+- Relation[hash#70,nonce#71,block_hash#72,block_number#73,transaction_index#74,from_address#75,to_address#76,value#77,gas#78,gas_price#79,input#80,block_timestamp#81,max_fee_per_gas#82,max_priority_fee_per_gas#83,transaction_type#84] csv
== Optimized Logical Plan ==
InsertIntoHadoopFsRelationCommand s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october, false, CSV, Map(header -> true, path -> s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october), Overwrite, [formatted_date, total_transaction_fee]
+- Repartition 1, false
+- Sort [formatted_date#136 ASC NULLS FIRST], true
+- Aggregate [formatted_date#136], [formatted_date#136, sum(transaction_fee#390) AS total_transaction_fee#464]
+- Project [formatted_date#136, (cast(gas#78 as double) * cast(gas_price#79 as double)) AS transaction_fee#390]
+- Join Inner, (hash#17 = block_hash#72)
:- Project [hash#17, date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) AS formatted_date#136]
: +- Filter (((date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) >= 2015-10-01) AND (date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) <= 2015-10-31)) AND isnotnull(hash#17))
: +- Relation[number#16,hash#17,parent_hash#18,nonce#19,sha3_uncles#20,logs_bloom#21,transactions_root#22,state_root#23,receipts_root#24,miner#25,difficulty#26,total_difficulty#27,size#28,extra_data#29,gas_limit#30,gas_used#31,timestamp#32,transaction_count#33,base_fee_per_gas#34] csv
+- Project [block_hash#72, gas#78, gas_price#79]
+- Filter ((isnotnull(transaction_index#74) AND (cast(transaction_index#74 as int) = 0)) AND isnotnull(block_hash#72))
+- Relation[hash#70,nonce#71,block_hash#72,block_number#73,transaction_index#74,from_address#75,to_address#76,value#77,gas#78,gas_price#79,input#80,block_timestamp#81,max_fee_per_gas#82,max_priority_fee_per_gas#83,transaction_type#84] csv
== Physical Plan ==
Execute InsertIntoHadoopFsRelationCommand s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october, false, CSV, Map(header -> true, path -> s3a://object-bucket-ec21590-0f30a127-4a67-4141-bbea-16743f6395f8/processed_data/october), Overwrite, [formatted_date, total_transaction_fee]
+- Coalesce 1
+- *(7) Sort [formatted_date#136 ASC NULLS FIRST], true, 0
+- Exchange rangepartitioning(formatted_date#136 ASC NULLS FIRST, 200), true, [id=#442]
+- *(6) HashAggregate(keys=[formatted_date#136], functions=[sum(transaction_fee#390)], output=[formatted_date#136, total_transaction_fee#464])
+- Exchange hashpartitioning(formatted_date#136, 200), true, [id=#438]
+- *(5) HashAggregate(keys=[formatted_date#136], functions=[partial_sum(transaction_fee#390)], output=[formatted_date#136, sum#470])
+- *(5) Project [formatted_date#136, (cast(gas#78 as double) * cast(gas_price#79 as double)) AS transaction_fee#390]
+- *(5) SortMergeJoin [hash#17], [block_hash#72], Inner
:- *(2) Sort [hash#17 ASC NULLS FIRST], false, 0
: +- Exchange hashpartitioning(hash#17, 200), true, [id=#420]
: +- *(1) Project [hash#17, date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) AS formatted_date#136]
: +- *(1) Filter (((date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) >= 2015-10-01) AND (date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as timestamp), yyyy-MM-dd, Some(GMT)) <= 2015-10-31)) AND isnotnull(hash#17))
: +- FileScan csv [hash#17,timestamp#32] Batched: false, DataFilters: [(date_format(cast(from_unixtime(cast(timestamp#32 as bigint), yyyy-MM-dd HH:mm:ss, Some(GMT)) as..., Format: CSV, Location: InMemoryFileIndex[s3a://data-repository-bkt/ECS765/ethereum/blocks.csv], PartitionFilters: [], PushedFilters: [IsNotNull(hash)], ReadSchema: struct<hash:string,timestamp:string>
+- *(4) Sort [block_hash#72 ASC NULLS FIRST], false, 0
+- Exchange hashpartitioning(block_hash#72, 200), true, [id=#429]
+- *(3) Project [block_hash#72, gas#78, gas_price#79]
+- *(3) Filter ((isnotnull(transaction_index#74) AND (cast(transaction_index#74 as int) = 0)) AND isnotnull(block_hash#72))
+- FileScan csv [block_hash#72,transaction_index#74,gas#78,gas_price#79] Batched: false, DataFilters: [isnotnull(transaction_index#74), (cast(transaction_index#74 as int) = 0), isnotnull(block_hash#72)], Format: CSV, Location: InMemoryFileIndex[s3a://data-repository-bkt/ECS765/ethereum/transactions.csv], PartitionFilters: [], PushedFilters: [IsNotNull(transaction_index), IsNotNull(block_hash)], ReadSchema: struct<block_hash:string,transaction_index:string,gas:string,gas_price:string>