-
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
Align protocol parameters JSON #1226
Conversation
Transactions CostsSizes and execution budgets for Hydra protocol transactions. Note that unlisted parameters are currently using
Script summary
Cost of Init Transaction
Cost of Commit TransactionThis is using ada-only outputs for better comparability.
Cost of CollectCom Transaction
Cost of Close Transaction
Cost of Contest Transaction
Cost of Abort TransactionSome variation because of random mixture of still initial and already committed outputs.
Cost of FanOut TransactionInvolves spending head output and burning head tokens. Uses ada-only UTxO for better comparability.
End-To-End Benchmark ResultsThis page is intended to collect the latest end-to-end benchmarks results produced by Hydra's Continuous Integration system from the latest 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 2024-01-05 18:06:43.034545384 UTC Baseline Scenario
Baseline Scenario
|
890e634
to
4a69ba4
Compare
6a2fb64
to
c7ec699
Compare
ab50449
to
dcfc5e3
Compare
2c83d56
to
59e70b3
Compare
dea7363
to
91f5d83
Compare
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.
The fact a single change to the withHydraNode
function ripples all over the place because we need to modify how it's called appears to me as a want for refactoring and encapsulating the parameters into some structure with default values
let cardanoLedgerProtocolParametersFile = dir </> "pparams.json" | ||
writeFileBS cardanoLedgerProtocolParametersFile (writeZeroedPParams pparams) | ||
let cardanoLedgerProtocolParametersFile = dir </> "protocol-parameters.json" | ||
case chainConfig 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.
This logic is starting to be quite large, I would suggest to extract a function eg. makeProtocolParametersFile
or something
945d500
to
1bd94d3
Compare
This is needed until the upstram bug fix is released.
Move one related cardano-cli test to appropriate module
The removed test is pointless as it does compare the output of using cardano-api with using cardano-cli. We do not care whether those are consistent, but rather that the output matches our expectations.
This deliberately uses the cardano-cli to query protocol parameters as JSON.
These are a documented starting point to come up with parameters for the hydra-node and are also used for the offline mode 'withHydraNode' in hydra-cluster.
This also improves the parse error message on hydra-node --contestation-period as it helped us to debug this.
It's not a good idea to keep protocol parameters in the RunningNode handle as they could change throughout our scenarios.
We were missing the cardano-cli from the shell environment running the benchmark in CI. The `withFile` from `base` is actively rewriting the ioe_location from "posix_spawnp" to "withFile" and thus obfuscates any errors raised within the wrapped action.
Rebased the whole PR on top of #1236 and so we do not need this workaround anymore.
1bd94d3
to
191cb0c
Compare
@ch1bo / @locallycompact adopted this PR:
In fact, the
cardano-cli
was not broken, but thehydra-node
was expectingcardano-ledger
PParams
on the--ledger-protocol-parameters
input file .. which is wrong and this PR fixes this now. This was a hidden breaking change onmaster
so far!👾 Load
--ledger-protocol-parameters
using the cardano-apiProtocolParameters
instance, which is the one thecardano-cli
also uses.👾 Adds a test that asserts the
Hydra.Ledger.Cardano.Configuration.pparamsFromJson
function can read the JSON returned bycardano-cli query protocol-parameters
pparamsFromJson
works as expected inhydra-node
-> follow-up PR