Skip to content

control the minimum amount that can be redistributed or recycled in fee disbursal #329

@rudolfix

Description

@rudolfix

Background
We allow holders to redistribute their payouts in FeeDisbursal contract and we allow anyone to recycle old payouts back to the community.
This is very desirable feature and was not the problem until gas price for READ operation rose and we expect it to go insanely high as proposed here https://ethereum-magicians.org/t/protocol-changes-to-bound-witness-size/3885
Increasing cost combined with many redistributions will increase transaction costs of claiming the payouts and may exceed the block limit easily (we can claim in tranches but why people should pay for this)
Therefore we want to replace the controller with one that will put a minimum limit on redistributed amounts

What to do

  • allow ROLE_DISBURSAL_MANAGER to set minimum limits for redistributions per any payment token on FeeDisbursalController
  • provide method to read current limit
  • enforce those limits in onDisburse method. mind that redistributions are defined by disbursals that are done by the FeeDisbursal contract itself (see recycyle and reject methods~).
  • add migration step where controller will be replaced and limits for ETHER TOKEN is set to 0.1 ETH and on EURO TOKEN to 10 EUR
  • new controller is fully compatible with old one if limits are not set!

Testing

  • full unit tests for enforcing the limits on both recycle and redistribute.
  • if no limits are set at all, the behavior is identical to old controller

Deployment

  • ABI change for FeeDisbursalController must be distributed in forked_live and live artifacts when deploying to those networks.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions