0

I've been looking at the OmiseGo Plasma-MVP,

And the finalizeExits() looks like this :

    // @dev Loops through the priority queue of exits, settling the ones whose challenge
    // @dev challenge period has ended
    function finalizeExits()
        public
    {
        uint256 utxoPos;
        uint256 exitable_at;
        (utxoPos, exitable_at) = getNextExit();
        exit memory currentExit = exits[utxoPos];
        while (exitable_at < block.timestamp && exitsQueue.currentSize() > 0) {
            currentExit = exits[utxoPos];
            currentExit.owner.transfer(currentExit.amount);
            exitsQueue.delMin();
            delete exits[utxoPos].owner;

            if (exitsQueue.currentSize() > 0) {
                (utxoPos, exitable_at) = getNextExit();
            } else {
                return;
            }
        }
}

In the case that many participants are listed in the exitsQueue, the gas required to execute this function may be prohibitively high or even exceed the maximum allowed.

Two questions here

  1. Who is expected to pay the gas for executing this function?
  2. How do we handle high number of exiters in terms of gas?
0

1) Who ever is submitting the transaction call (nothing changes, a transaction is still a transaction) 2) There is no way around this, other than keeep the total number of exiters that could ever be around to be quite low. If you allow enough people onto your child-chain such that an exit can't even be performed due to reaching gas block limits, than your plasma implementation was horribly designed (IMO).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.