-
Notifications
You must be signed in to change notification settings - Fork 87
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
Reuse functions from Cardano.Api.Tx.Body and match nomenclature. #1761
base: master
Are you sure you want to change the base?
Conversation
72e1391
to
b2103f4
Compare
Transaction costsSizes and execution budgets for Hydra protocol transactions. Note that unlisted parameters are currently using
Script summary
|
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 11683 | 9.08 | 2.98 | 0.76 |
2 | 11884 | 10.53 | 3.43 | 0.78 |
3 | 12082 | 12.38 | 4.03 | 0.81 |
5 | 12491 | 15.90 | 5.18 | 0.87 |
10 | 13490 | 24.90 | 8.11 | 1.00 |
24 | 16306 | 49.27 | 16.01 | 1.38 |
Commit
transaction costs
This uses ada-only outputs for better comparability.
UTxO | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 561 | 2.45 | 1.17 | 0.20 |
2 | 743 | 3.40 | 1.74 | 0.22 |
3 | 920 | 4.39 | 2.34 | 0.24 |
5 | 1279 | 6.46 | 3.61 | 0.28 |
10 | 2180 | 12.24 | 7.28 | 0.40 |
54 | 10045 | 99.20 | 68.72 | 1.89 |
CollectCom
transaction costs
Parties | UTxO (bytes) | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|---|
1 | 56 | 524 | 24.83 | 7.22 | 0.43 |
2 | 114 | 636 | 32.69 | 9.48 | 0.51 |
3 | 170 | 747 | 40.50 | 11.74 | 0.60 |
4 | 228 | 862 | 47.30 | 13.76 | 0.67 |
5 | 282 | 969 | 55.39 | 16.11 | 0.76 |
6 | 338 | 1081 | 73.33 | 20.81 | 0.94 |
7 | 396 | 1192 | 73.00 | 21.08 | 0.94 |
8 | 450 | 1303 | 79.47 | 23.12 | 1.02 |
9 | 507 | 1414 | 89.92 | 26.02 | 1.13 |
Cost of Decrement Transaction
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 597 | 22.63 | 7.30 | 0.41 |
2 | 784 | 25.34 | 8.73 | 0.45 |
3 | 827 | 23.84 | 8.96 | 0.44 |
5 | 1139 | 27.74 | 11.39 | 0.51 |
10 | 2126 | 42.48 | 18.86 | 0.72 |
43 | 6756 | 96.18 | 55.92 | 1.63 |
Close
transaction costs
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 622 | 24.38 | 8.02 | 0.43 |
2 | 761 | 25.94 | 9.18 | 0.46 |
3 | 905 | 27.54 | 10.36 | 0.49 |
5 | 1217 | 31.06 | 12.92 | 0.55 |
10 | 2032 | 40.43 | 19.53 | 0.71 |
43 | 7007 | 98.88 | 61.32 | 1.70 |
Contest
transaction costs
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 662 | 30.42 | 9.64 | 0.49 |
2 | 844 | 32.96 | 11.19 | 0.53 |
3 | 946 | 34.83 | 12.42 | 0.56 |
5 | 1132 | 37.22 | 14.29 | 0.60 |
10 | 2053 | 49.42 | 21.92 | 0.80 |
34 | 5665 | 99.00 | 54.24 | 1.59 |
Abort
transaction costs
There is some variation due to the random mixture of initial and already committed outputs.
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | 11566 | 25.63 | 8.72 | 0.93 |
2 | 11683 | 34.10 | 11.58 | 1.02 |
3 | 11928 | 44.27 | 15.16 | 1.14 |
4 | 12029 | 52.76 | 18.02 | 1.24 |
5 | 12316 | 63.72 | 21.84 | 1.36 |
6 | 12202 | 69.34 | 23.56 | 1.42 |
7 | 12393 | 76.14 | 25.93 | 1.50 |
8 | 12402 | 83.92 | 28.44 | 1.58 |
9 | 12609 | 93.64 | 31.90 | 1.69 |
10 | 12555 | 96.99 | 32.89 | 1.72 |
FanOut
transaction costs
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 ₳ |
---|---|---|---|---|---|---|
10 | 0 | 0 | 11679 | 17.34 | 5.93 | 0.85 |
10 | 1 | 57 | 11713 | 19.56 | 6.83 | 0.87 |
10 | 5 | 285 | 11849 | 25.14 | 9.21 | 0.94 |
10 | 10 | 569 | 12019 | 36.54 | 13.80 | 1.07 |
10 | 20 | 1135 | 12355 | 52.92 | 20.63 | 1.27 |
10 | 30 | 1707 | 12699 | 73.27 | 28.92 | 1.51 |
10 | 40 | 2275 | 13036 | 90.71 | 36.14 | 1.72 |
10 | 44 | 2508 | 13177 | 98.49 | 39.32 | 1.81 |
End-to-end benchmark results
This page is intended to collect the latest end-to-end benchmark results produced by Hydra's continuous integration (CI) system from the latest master
code.
Please note that these results are approximate as they are currently produced from limited cloud VMs and not controlled hardware. Rather than focusing on the absolute results, the emphasis should be on relative results, such as how the timings for a scenario evolve as the code changes.
Generated at 2024-12-08 12:08:49.438515007 UTC
Baseline Scenario
Number of nodes | 1 |
---|---|
Number of txs | 300 |
Avg. Confirmation Time (ms) | 4.259944640 |
P99 | 8.907863879999999ms |
P95 | 5.244689450000001ms |
P50 | 4.0672565ms |
Number of Invalid txs | 0 |
Three local nodes
Number of nodes | 3 |
---|---|
Number of txs | 900 |
Avg. Confirmation Time (ms) | 22.604736463 |
P99 | 40.66356677ms |
P95 | 31.799586649999984ms |
P50 | 21.0593485ms |
Number of Invalid txs | 0 |
Transaction cost differencesScript summary
|
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | - | |
2 | - | - | - | |
3 | - | - | - | |
5 | - | - | - | |
10 | - | - | - | |
24 | - | - |
Commit
transaction costs
UTxO | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | - | - |
2 | - | - | - | - |
3 | - | - | - | - |
5 | - | - | - | - |
10 | - | - | - | - |
54 | - | - | - |
CollectCom
transaction costs
Parties | UTxO (bytes) | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|---|
1 | - | ||||
2 | - | ||||
3 | - | +1.27 | +0.31 | +0.01 | |
4 | - | ||||
5 | - | +4.28 | +1.03 | +0.04 | |
6 | - | ||||
7 | - | ||||
8 | - |
Cost of Decrement Transaction
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | - | |
2 | - | - | - | |
3 | - | - | - | |
5 | - | - | ||
10 | - | - | - | |
45 | - | - | - |
Close
transaction costs
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | - | |
2 | - | - | - | |
3 | - | - | - | |
5 | - | - | - | |
10 | - | - | - | |
43 | - | - | - |
Contest
transaction costs
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | ||
2 | - | - | ||
3 | - | - | ||
5 | - | - | - | |
10 | - | - | - | |
34 | - | - | - |
Abort
transaction costs
Parties | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|
1 | - | - | - | |
2 | - | - | ||
3 | +0.04 | +0.01 | - | |
4 | +0.04 | +0.01 | - | |
5 | ||||
6 | ||||
7 | +0.06 | +0.02 | - | |
8 | - | |||
9 | ||||
10 | +0.13 | +0.03 | - |
FanOut
transaction costs
Parties | UTxO | UTxO (bytes) | Tx size | % max Mem | % max CPU | Min fee ₳ |
---|---|---|---|---|---|---|
10 | - | - | - | - | - | |
10 | - | - | - | - | - | |
10 | - | - | - | - | - | |
10 | - | - | - | - | - | |
10 | - | - | - | - | ||
10 | - | - | - | - | - | |
10 | - | - | - | - | - | |
10 | - | - | - | - | - |
57f83b0
to
2b929b5
Compare
2b929b5
to
8e3aeaa
Compare
case txMintValue $ txBodyContent $ txBody tx of | ||
TxMintValueNone -> error "expected minted value" | ||
TxMintValue v _ -> fromList $ filter (not . isPT) $ toList v | ||
case toList $ txMintValueToValue $ txMintValue $ txBodyContent $ txBody tx of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a drive-by comment, but i think this was much clearer in the first version; what was the reason to change it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it? It just dismisses the Nothing case.
But moreover, having played around with this a bit - I'd be tempted to do the mutations in terms of the cardano-api TxBodyContent type in general and use modTxMintValue
.
8e3aeaa
to
51e24d9
Compare
These functions that modify TxBodyContent can now be upstreamed to Cardano.Api.Tx.Body.
These can be removed after IntersectMBO/cardano-api#704 is merged.