Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add logs exporter #49

Merged
merged 6 commits into from
Aug 3, 2022
Merged

Add logs exporter #49

merged 6 commits into from
Aug 3, 2022

Conversation

BohuTANG
Copy link
Contributor

@BohuTANG BohuTANG commented Aug 3, 2022

Summary

Summary about this PR

Close #issue

@BohuTANG
Copy link
Contributor Author

BohuTANG commented Aug 3, 2022

There is an array type:
https://github.com/deepeth/mars/pull/49/files#diff-fd658bbb5311a4d9f2a39c8d44537c066095a8f529874797108f1a8a558df52aR80-R90

CSV:
./target/release/ethetl -c scripts/deploy/ethetl_config_spec.toml   -s 10260000 -e 10260000 -o /tmp/eth -w 16 -f csv
[2022-08-03T08:54:02Z INFO ] Config: EthConfig { log: LogConfig { level: "ERROR", dir: "_logs" }, export: ExportConfig { provider_uri: "http://192.168.191.66:8848", start_block: 10260000, end_block: 10260000, batch_size: 10000, max_worker: 16, web3_batch_size: 1000, output_dir: "/tmp/eth", output_format: "csv" }, storage: StorageConfig { storage_type: "fs", fs: FsStorageConfig { data_path: "_datas/" }, s3: S3StorageConfig { endpoint_url: "https://s3.amazonaws.com", region: "", bucket: "", root: "", access_key_id: "", secret_access_key: "" }, azblob: AzureStorageBlobConfig { endpoint_url: "", container: "", root: "", account_name: "", account_key: "" } }, config_file: "scripts/deploy/ethetl_config_spec.toml" }
[2022-08-03T08:54:02Z INFO ] backend build started: Builder { root: Some("/home/bohu/github/deepeth/mars/_datas/") }
[2022-08-03T08:54:02Z INFO ] backend build finished: Builder { root: Some("/home/bohu/github/deepeth/mars/_datas/") }
[2022-08-03T08:54:02Z INFO ] fetch_with_no_retry;
[2022-08-03T08:54:02Z INFO ] Write blocks to /tmp/eth/10260000_10260000/blocks.csv
[2022-08-03T08:54:02Z INFO ] Write transactions to /tmp/eth/10260000_10260000/transactions.csv
[2022-08-03T08:54:02Z INFO ] Write /tmp/eth/10260000_10260000/_transaction_hashes.txt
[2022-08-03T08:54:02Z INFO ] fetch_with_no_retry;
[2022-08-03T08:54:03Z INFO ] Write receipts to /tmp/eth/10260000_10260000/receipts.csv
[2022-08-03T08:54:03Z INFO ] Write logs to /tmp/eth/10260000_10260000/logs.csv
thread 'tokio-runtime-worker' panicked at 'data type: List(Field { name: "topics", data_type: Utf8, is_nullable: true, metadata: {} }) not supported by csv writer', /home/bohu/.cargo/registry/src/github.aaakk.us.kg-1ecc6299db9ec823/arrow2-0.12.0/src/io/csv/write/serialize.rs:463:15


Parquet:
 ./target/release/ethetl -c scripts/deploy/ethetl_config_spec.toml   -s 10260000 -e 10260000 -o /tmp/eth -w 16 -f parquet
[2022-08-03T08:54:38Z INFO ] Config: EthConfig { log: LogConfig { level: "ERROR", dir: "_logs" }, export: ExportConfig { provider_uri: "http://192.168.191.66:8848", start_block: 10260000, end_block: 10260000, batch_size: 10000, max_worker: 16, web3_batch_size: 1000, output_dir: "/tmp/eth", output_format: "parquet" }, storage: StorageConfig { storage_type: "fs", fs: FsStorageConfig { data_path: "_datas/" }, s3: S3StorageConfig { endpoint_url: "https://s3.amazonaws.com", region: "", bucket: "", root: "", access_key_id: "", secret_access_key: "" }, azblob: AzureStorageBlobConfig { endpoint_url: "", container: "", root: "", account_name: "", account_key: "" } }, config_file: "scripts/deploy/ethetl_config_spec.toml" }
[2022-08-03T08:54:38Z INFO ] backend build started: Builder { root: Some("/home/bohu/github/deepeth/mars/_datas/") }
[2022-08-03T08:54:38Z INFO ] backend build finished: Builder { root: Some("/home/bohu/github/deepeth/mars/_datas/") }
[2022-08-03T08:54:38Z INFO ] fetch_with_no_retry;
[2022-08-03T08:54:38Z INFO ] Write blocks to /tmp/eth/10260000_10260000/blocks.parquet
[2022-08-03T08:54:38Z INFO ] Write transactions to /tmp/eth/10260000_10260000/transactions.parquet
[2022-08-03T08:54:38Z INFO ] Write /tmp/eth/10260000_10260000/_transaction_hashes.txt
[2022-08-03T08:54:38Z INFO ] fetch_with_no_retry;
[2022-08-03T08:54:38Z INFO ] Write receipts to /tmp/eth/10260000_10260000/receipts.parquet
[2022-08-03T08:54:38Z ERROR] Pipeline execute error:Code: 1002, displayText = ExternalFormat("The max_value of statistics MUST be plain encoded").
    
    <Backtrace disabled by default. Please use RUST_BACKTRACE=1 to enable> 
[2022-08-03T08:54:38Z INFO ] 1 blocks processed, 149 transactions processed, 149 receipts processed. Progress is 100%

@BohuTANG BohuTANG marked this pull request as ready for review August 3, 2022 10:05
@BohuTANG BohuTANG merged commit 88b3825 into main Aug 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant