LogoLogo
Summer.fiContact us
  • Summer.fi
    • Overview
    • Basic Concepts
    • Audits
  • Lazy Summer Protocol
    • Lazy Summer Protocol
      • ARKs
        • Buffer ARK
        • RAFT
          • Dutch Auctions
      • Fees
      • Contracts Addresses
    • Rebalancer
    • Governance
      • Cross-Chain Governance
      • Rewards
      • Tip Streams
      • $SUMR Token
        • Delegation
        • Voting Power Decay
  • Summer.fi pro
    • General
      • Smart Contracts and Documentation
      • Costs and Fees
      • Address Compliance Check
      • Security
      • Referrals Program
        • FAQ
        • How to refer a friend
    • Products
      • Borrow
        • Frequently Asked Questions
      • Multiply
        • The difference between Borrow and Multiply Vaults
        • Frequently Asked Questions
      • Swap and Bridge
      • Earn
        • Aave v2 stETH
        • Aave v3 stETH
        • Dai Savings Rate (DSR)
          • sDAI
          • What is sDAI Conversion?
      • $RAYS
        • FAQ
    • Automation
      • Stop-Loss
        • How to setup your Stop-Loss
        • Trailing Stop-Loss
      • Auto-Buy
      • Auto-Sell
      • Take Profit
        • Auto Take Profit
          • How to setup Auto Take Profit
  • LEGAL
    • UK Disclaimer
    • Risks of using our products
  • Get in touch
    • Contact Us
Powered by GitBook
LogoLogo

Products

  • Borrow
  • Multiply
  • Earn

About

  • Team
  • Security
  • Terms
  • Privacy

Resources

  • Blog
  • Bug Bounty
  • Brand Assets

Oazo Apps 2023

On this page
  • Functionality
  • Withdrawal Methods

Was this helpful?

Export as PDF
  1. Lazy Summer Protocol
  2. Lazy Summer Protocol
  3. ARKs

Buffer ARK

The Buffer ARK is a specialized holding contract in the Lazy Summer Protocol that manages deposits and withdrawals. It maintains a portion of Fleet assets in an undeployed state for efficient withdrawals.

Functionality

The Buffer ARK holds incoming deposits until they are allocated to yield-generating strategies. It maintains a minimum balance relative to the Fleet's total value locked (TVL) to facilitate efficient withdrawals, particularly beneficial for smaller transactions.

Withdrawal Methods

  1. Standard Withdrawal

    • Executes from Buffer ARK balance

    • Lower gas consumption

    • Efficient for most transaction sizes

  2. Force Withdrawal

    • Activates when Buffer ARK balance is insufficient

    • Withdraws directly from yield-generating ARKs

    • Higher gas consumption

    • Necessary for large withdrawals

    The Buffer ARK contract (BufferArk.sol) inherits from the base Ark contract and implement specialized buffer functionality:

    Constructor

    constructor(ArkParams memory _params, address commanderAddress) Ark(_params) {
        config.commander = commanderAddress;
    }
    • Initializes Buffer ARK with configuration parameters

    • Sets Fleet Commander address

    Asset Management Functions

    Total Assets View

    function totalAssets() public view override returns (uint256) {
        return config.asset.balanceOf(address(this));
    }
    • Returns current token balance

    • Direct reflection of undeployed assets

    • No yield calculations involved

    Withdrawable Assets View

    function _withdrawableTotalAssets() internal view override returns (uint256) {
        return totalAssets();
    }
    • All assets are always withdrawable

    • Returns same value as totalAssets()

    • No withdrawal restrictions implemented

    Asset Boarding

    function _board(uint256 amount, bytes calldata) internal override {}
    • Empty implementation

    • Assets automatically held in contract

    • No external protocol interactions

    Asset Disembarking

    function _disembark(uint256 amount, bytes calldata) internal override {}
    • Empty implementation

    • Standard ERC20 transfers handled by base contract

    • No position unwinding required

    Data Validation

    Board Data Validation

    function _validateBoardData(bytes calldata) internal override {}
    • No additional validation required

    • Accepts any boarding data

    • Empty implementation

    Disembark Data Validation

    function _validateDisembarkData(bytes calldata) internal override {}
    • No additional validation required

    • Accepts any disembarking data

    • Empty implementation

    Reward Handling

    function _harvest(bytes calldata) internal override returns (
        address[] memory rewardTokens,
        uint256[] memory rewardAmounts
    ) {}
    • Returns empty arrays

    • No reward generation

    • Empty implementation

    Integration Points

    1. Fleet Commander Interface

    config.commander = commanderAddress;
    • Set during construction

    • Controls asset allocation

    • Manages withdrawal coordination

    • ERC20 Token Interface

    config.asset.balanceOf(address(this))
    • Used for balance tracking

    • Core asset accounting

    • Inherited from base Ark contract

    Access Control

    The Buffer ARK inherits access control from the base Ark contract:

    • Only Fleet Commander can initiate withdrawals

    • Only authorized addresses can board assets

    • RAFT contract controls harvest operations

PreviousARKsNextRAFT

Last updated 4 months ago

Was this helpful?