Skip to content

Dedicated etcd version check#1914

Merged
ch1bo merged 7 commits into
masterfrom
dedicated-etcd-version
Mar 31, 2025
Merged

Dedicated etcd version check#1914
ch1bo merged 7 commits into
masterfrom
dedicated-etcd-version

Conversation

@ch1bo
Copy link
Copy Markdown
Member

@ch1bo ch1bo commented Mar 26, 2025

This checks the version compiled into hydra-node against a version stored on the etcd key-value store and emits a "network-level" version mismatch ConnectivityEvent whenever we (re-)connect to the majority cluster.

This is different to before where we would encode a version into each peers message (quite crudely) and also check it on each message received.


  • CHANGELOG updated
  • Documentation update not needed
  • Haddocks updated
  • New TODOs explained herafter
    • Encountered that the prop_specIsComplete used in ClientInputSpec and ServerOutputSpec is not working!

@ch1bo ch1bo moved this from Triage 🏥 to In review 👀 in ☕ Hydra Team Work Mar 26, 2025
@ch1bo ch1bo requested a review from a team March 26, 2025 08:34
@ch1bo ch1bo self-assigned this Mar 26, 2025
@ch1bo ch1bo force-pushed the dedicated-etcd-version branch from a0db857 to d10c94e Compare March 26, 2025 08:36
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Mar 26, 2025

Transaction cost differences

No cost or size differences found

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Mar 26, 2025

Transaction 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 2025-03-31 10:37:47.913809185 UTC
Max. memory units 14000000
Max. CPU units 10000000000
Max. tx size (kB) 16384

Script summary

Name Hash Size (Bytes)
νInitial c8a101a5c8ac4816b0dceb59ce31fc2258e387de828f02961d2f2045 2652
νCommit 61458bc2f297fff3cc5df6ac7ab57cefd87763b0b7bd722146a1035c 685
νHead 0e35115a2c7c13c68ecd8d74e4987c04d4539e337643be20bb3274bd 14756
μHead 57166715eadb8d3135964325c016eea546c21e1c0aae974ca67df9a5* 5541
νDeposit ae01dade3a9c346d5c93ae3ce339412b90a0b8f83f94ec6baa24e30c 1102
  • The minting policy hash is only usable for comparison. As the script is parameterized, the actual script is unique per head.

Init transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 6091 11.02 3.43 0.53
2 6295 13.44 4.18 0.57
3 6495 15.98 4.97 0.60
5 6895 20.19 6.25 0.66
10 7904 31.06 9.57 0.82
40 13933 98.18 30.14 1.77

Commit transaction costs

This uses ada-only outputs for better comparability.

UTxO Tx size % max Mem % max CPU Min fee ₳
1 561 2.44 1.16 0.20
2 744 3.38 1.73 0.22
3 923 4.36 2.33 0.24
5 1280 6.41 3.60 0.28
10 2179 12.13 7.25 0.40
54 10067 98.61 68.52 1.88

CollectCom transaction costs

Parties UTxO (bytes) Tx size % max Mem % max CPU Min fee ₳
1 57 525 25.67 7.41 0.43
2 114 636 33.83 9.73 0.52
3 171 747 41.81 12.01 0.61
4 225 858 53.32 15.15 0.73
5 282 969 63.99 18.15 0.84
6 339 1081 78.69 22.06 0.99
7 396 1192 90.69 25.32 1.12
8 452 1303 98.74 27.69 1.20
9 506 1414 92.88 26.59 1.15

Cost of Increment Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 1752 24.01 7.84 0.48
2 1938 27.12 9.50 0.52
3 2070 28.65 10.65 0.55
5 2348 31.66 12.93 0.60
10 3278 45.32 20.81 0.81
37 7373 98.23 56.00 1.67

Cost of Decrement Transaction

Parties Tx size % max Mem % max CPU Min fee ₳
1 601 23.95 7.60 0.43
2 756 25.31 8.65 0.45
3 992 29.36 10.43 0.51
5 1090 28.54 11.51 0.51
10 1915 40.81 18.23 0.70
39 6045 97.36 53.11 1.59

Close transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 639 30.87 9.66 0.50
2 816 30.94 10.42 0.51
3 951 32.82 11.65 0.54
5 1254 37.14 14.40 0.61
10 1962 49.31 21.47 0.79
34 5785 98.12 53.70 1.58

Contest transaction costs

Parties Tx size % max Mem % max CPU Min fee ₳
1 707 35.95 11.01 0.55
2 760 37.49 12.02 0.57
3 942 40.36 13.65 0.62
5 1361 46.70 17.18 0.71
10 1967 56.66 23.39 0.86
27 4470 96.83 47.24 1.47

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 5978 28.36 9.35 0.71
2 6054 34.08 11.18 0.77
3 6280 47.90 15.82 0.93
4 6401 56.98 18.81 1.03
5 6430 62.19 20.45 1.08
6 6586 72.09 23.80 1.19
7 6657 78.18 25.73 1.26
8 6803 89.08 29.37 1.38

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 6092 20.58 6.77 0.63
10 1 57 6126 21.33 7.13 0.64
10 5 285 6262 30.51 10.66 0.75
10 10 570 6431 41.42 14.88 0.88
10 20 1139 6770 62.72 23.14 1.12
10 30 1707 7110 83.57 31.25 1.36
10 37 2104 7347 98.48 37.03 1.54

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 2025-03-31 10:40:50.511985942 UTC

Baseline Scenario

Number of nodes 1
Number of txs 300
Avg. Confirmation Time (ms) 4.736070333
P99 7.809971439999998ms
P95 5.840501100000001ms
P50 4.5574580000000005ms
Number of Invalid txs 0

Memory data

Time Used Free
2025-03-31 10:39:34.106634498 UTC 895M 6152M
2025-03-31 10:39:39.10657279 UTC 1029M 5915M
2025-03-31 10:39:44.106446297 UTC 1033M 5911M
2025-03-31 10:39:49.106465602 UTC 1033M 5911M
2025-03-31 10:39:54.106448794 UTC 1036M 5907M
2025-03-31 10:39:59.106563446 UTC 1037M 5907M

Three local nodes

Number of nodes 3
Number of txs 900
Avg. Confirmation Time (ms) 27.547468474
P99 42.09003730999999ms
P95 36.01457489999999ms
P50 26.560801ms
Number of Invalid txs 0

Memory data

Time Used Free
2025-03-31 10:40:12.800569545 UTC 980M 5972M
2025-03-31 10:40:17.800681047 UTC 1219M 5732M
2025-03-31 10:40:22.801775828 UTC 1295M 5595M
2025-03-31 10:40:27.800663719 UTC 1294M 5545M
2025-03-31 10:40:32.800765599 UTC 1300M 5539M
2025-03-31 10:40:37.800691196 UTC 1302M 5537M
2025-03-31 10:40:42.800612349 UTC 1305M 5533M
2025-03-31 10:40:47.800639652 UTC 1305M 5533M

Comment thread hydra-node/src/Hydra/Network/Etcd.hs
Comment thread hydra-node/src/Hydra/Network/Etcd.hs
Comment thread hydra-node/test/Hydra/NetworkSpec.hs Outdated
@ch1bo ch1bo added this to the 0.21.0 milestone Mar 28, 2025
@ch1bo ch1bo force-pushed the dedicated-etcd-version branch 2 times, most recently from 295ca6c to 9bad158 Compare March 28, 2025 20:27
Shifting to a network-level incompatibility message makes it easier to
determine (especially for etcd based network).

In the end, an operator only needs to know whether they need to update
the hydra-node or their counter parties.
@ch1bo ch1bo force-pushed the dedicated-etcd-version branch from 9bad158 to 3a14340 Compare March 28, 2025 20:28
@ch1bo ch1bo requested review from a team and noonio March 28, 2025 20:28
ch1bo added 5 commits March 28, 2025 21:30
Apparently the prop_specIsComplete is not sufficient to detect
incompatibilities (and seems to be broken too?).
The version check test is still flaky.
The NetworkVersionMismatch may or may not know what 'theirVersion' is
and this is indicated by 'null' or an integer.
@ch1bo ch1bo force-pushed the dedicated-etcd-version branch from 3a14340 to 0a14a9b Compare March 28, 2025 20:30
@ch1bo ch1bo enabled auto-merge March 31, 2025 10:41
@ch1bo ch1bo merged commit d17b7e9 into master Mar 31, 2025
@ch1bo ch1bo deleted the dedicated-etcd-version branch March 31, 2025 11:55
@github-project-automation github-project-automation Bot moved this from In review 👀 to Done ✔ in ☕ Hydra Team Work Mar 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants