Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
consensus: implement TxLimits via the cardano-base:measures package
This has a few small benefits * define's TxMeasure `leq` via the pointwise minimum * removes the redundancy of specifying the `pointwiseMin` method per ledger instead of per 'Measure' * avoids the need for type applications, which let's us re-use the <= operator and two large benefits * creates an opportunity for more use of deriving * the top-bounded meet-semilattice foundation means that `noOverrides` can be implemented as `top`; we don't need it to be a function from the (dynamic!) ledger limits anymore. We had previously decided on a function because it made it trivial to override only parts of the ledger-derived capacity. However, we simplified the override representation (no more `NP`) and a interface that uses the static `top` instead of the dynamic "current ledger capacity" is more appropriate for a interface used for static configuration. In other words, the function space was "too big" for the following reasons. * in practice, these values are parsed from a file, and I doubt the Node Team wants to parse functions anytime soon * we do not anticipate the node operator wanting to vary their override depending on the ledger capacity The 'Measure' class's lattice semantics let us remove the function space without losing any convenience.
- Loading branch information
Showing
10 changed files
with
134 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.