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

Check if cardano-cli works with DraftCommitTxResponse json output #1180

Merged
merged 4 commits into from
Nov 27, 2023

Conversation

v0d1ch
Copy link
Contributor

@v0d1ch v0d1ch commented Nov 24, 2023

Why

To make sure that cardano-cli can be used on our draft commit transaction.

What

Produce a DraftCommitTxResponse json output and assert it is usable from the cardano-cli.


  • CHANGELOG updated or not needed
  • Documentation updated or not needed
  • Haddocks updated or not needed
  • No new TODOs introduced or explained herafter

@v0d1ch v0d1ch self-assigned this Nov 24, 2023
We produce a `DraftCommitTxResponse` and want to assert
it is usable from the cardano-cli present in local scope.
@v0d1ch v0d1ch force-pushed the cardano-cli-text-envelope-format branch from 8b043a8 to 7bf7427 Compare November 24, 2023 10:30
@ffakenz ffakenz linked an issue Nov 24, 2023 that may be closed by this pull request
Copy link

github-actions bot commented Nov 24, 2023

Transactions Costs

Sizes and execution budgets for Hydra protocol transactions. Note that unlisted parameters are currently using arbitrary values and results are not fully deterministic and comparable to previous runs.

Metadata
Generated at 2023-11-27 11:22:34.09709969 UTC
Max. memory units 14000000
Max. CPU units 10000000000
Max. tx size (kB) 16384

Script summary

Name Hash Size (Bytes)
νInitial 4868d5365af5120ae0b3c93b819d3452a3cbdcc98595da2a7ae765b5 4069
νCommit 171a1e6bdbc8aa96d957a65b3f505517386af06ba265e3f784741f67 2050
νHead e89b0c4a6155bac2434d1e500bd49c155b2b56744ccf5a0efa72a82e 9092
μHead 6849328242b5912ad218f134378e6baff11f3e74f7e36dcf8e13d53e* 4062
  • The minting policy hash is only usable for comparison. As the script is parameterized, the actual script is unique per Head.

Cost of Init Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 4586 10.85 4.30 0.47
2 4786 13.07 5.15 0.50
3 4985 15.61 6.13 0.54
5 5392 19.85 7.74 0.60
10 6400 30.81 11.92 0.77
41 12629 99.54 38.15 1.79

Cost of Commit Transaction

This is using ada-only outputs for better comparability.

UTxO Tx size % max Mem % max CPU Min fee ₳
1 531 12.22 4.81 0.31
2 720 15.93 6.48 0.36
3 909 19.77 8.20 0.41
5 1286 27.87 11.80 0.52
10 2225 50.58 21.69 0.81
18 3714 94.20 40.16 1.36

Cost of CollectCom Transaction

Parties UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
1 57 480 22.88 9.12 0.42
2 113 590 34.01 13.73 0.55
3 170 700 50.51 20.43 0.74
4 227 810 62.00 25.39 0.87
5 283 920 84.21 34.42 1.12

Cost of Close Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 540 17.80 8.36 0.38
2 671 19.00 9.59 0.40
3 939 21.13 11.57 0.45
5 1187 24.25 14.45 0.50
10 2170 32.76 22.62 0.67
50 8793 95.60 82.69 1.91

Cost of Contest Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 578 21.33 9.70 0.42
2 765 23.27 11.41 0.45
3 940 25.08 13.04 0.49
5 1230 28.51 16.07 0.55
10 2122 37.53 24.14 0.72
45 8077 99.46 79.75 1.88

Cost of Abort Transaction

Some variation because of random mixture of still initial and already committed outputs.

Parties Tx size % max Mem % max CPU Min fee ₳
1 4544 20.10 8.75 0.58
2 4711 33.76 14.88 0.74
3 4792 44.47 19.48 0.86
4 4969 63.47 27.99 1.08
5 5139 85.11 37.69 1.34

Cost of FanOut Transaction

Involves spending head output and burning head tokens. Uses ada-only UTxO for better comparability.

Parties UTxO UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
5 0 0 4417 9.21 3.88 0.45
5 1 57 4452 10.28 4.57 0.46
5 5 285 4597 15.70 7.84 0.54
5 10 570 4777 21.82 11.66 0.62
5 20 1138 5134 34.79 19.60 0.80
5 30 1709 5497 47.90 27.60 0.98
5 40 2276 5854 61.12 35.65 1.16
5 50 2848 6216 73.65 43.41 1.33
5 70 3985 6934 99.87 59.42 1.69

End-To-End Benchmark Results

This page is intended to collect the latest end-to-end benchmarks results produced by Hydra's Continuous Integration system from the latest master code.

Please take those results with a grain of salt as they are currently produced from very limited cloud VMs and not controlled hardware. Instead of focusing on the absolute results, the emphasis should be on relative results, eg. how the timings for a scenario evolve as the code changes.

Generated at 2023-11-27 11:18:25.914038186 UTC

3-nodes Scenario

A rather typical setup, with 3 nodes forming a Hydra head.

Number of nodes 3
Number of txs 900
Avg. Confirmation Time (ms) 24.791227601
P99 117.46864500999999ms
P95 34.8342671ms
P50 21.405576ms
Number of Invalid txs 0

Baseline Scenario

This scenario represents a minimal case and as such is a good baseline against which to assess the overhead introduced by more complex setups. There is a single hydra-node d with a single client submitting single input and single output transactions with a constant UTxO set of 1.

Number of nodes 1
Number of txs 300
Avg. Confirmation Time (ms) 4.672606133
P99 8.490102509999993ms
P95 5.6524899500000005ms
P50 4.5002759999999995ms
Number of Invalid txs 0

We now need  cardano-cli binary to run one test we have
for it in the hydra-cluster package.
Copy link

github-actions bot commented Nov 24, 2023

Test Results

370 tests  +1   365 ✔️ +1   20m 17s ⏱️ - 1m 37s
125 suites +1       5 💤 ±0 
    5 files   ±0       0 ±0 

Results for commit e607e47. ± Comparison against base commit 8f4aedc.

♻️ This comment has been updated with latest results.

Copy link
Collaborator

@ch1bo ch1bo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Helpful addition as tests. Some refactoring possible as commented.

hydra-cluster/test/Test/Hydra/Cluster/CardanoCliSpec.hs Outdated Show resolved Hide resolved
hydra-cluster/test/Test/Hydra/Cluster/CardanoCliSpec.hs Outdated Show resolved Hide resolved
@v0d1ch v0d1ch merged commit bad1bc1 into master Nov 27, 2023
20 checks passed
@v0d1ch v0d1ch deleted the cardano-cli-text-envelope-format branch November 27, 2023 11:39
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.

Drafted commit transaction - wrong description
3 participants