Liquidity Curation with MarketV1AdapterV2
How the Liquidity Adapter Works
When a MorphoMarketV1AdapterV2 is set as the vault's liquidityAdapter, it points to one specific underlying Variable Rate Market (Market V1) at a time, configured via liquidityData.
All deposits flow into this market, and all withdrawals are sourced from it.
This means:
- If the adapter is deployed across multiple Variable Rate Markets (Markets V1) (e.g., cbBTC/USDC, WETH/USDC, WBTC/USDC), only the one selected as the liquidity adapter is used for deposits and withdrawals.
- On Morpho Vault V2 withdrawals, the vault's idle assets are used first, and then the liquidity adapter's available liquidity.
- If that specific market reaches 100% utilization, and the vault's idle assets are empty, the vault is effectively illiquid from the user's perspective. Any withdrawal attempt will revert.
- There is no automatic fallthrough to other markets within the same adapter. There is no configurable withdrawal queue in Morpho Vault V2 — unlike Vault V1, where the allocator can define and reorder the queue.
- If the liquidity adapter's allocation caps are reached, deposit and mint operations will revert. There is no fallback to idle assets for deposits.
Dynamic Reallocation
A good practice to maintain liquidity is to run a reallocation bot that continuously manages the liquidity adapter configuration:
- Monitor the available liquidity of the current liquidity adapter.
- Switch the liquidity adapter to the most liquid Variable Rate Market when needed, or reallocate funds after a large withdrawal or when available liquidity drops below a defined threshold.
Both the liquidityAdapter and the underlying liquidityData (i.e. which Variable Rate Market is used) can be changed on the fly by the allocator bot to meet demand. This is conceptually similar to how Morpho Vaults V1 already work: you need to reallocate liquidity between withdrawal and deposit events to avoid allocation drift.
The forceDeallocate Safety Net
Even if the reallocation bot has not caught up, users have a way out. The forceDeallocate mechanism allows anyone to permissionlessly trigger available liquidity movement from an adapter into the vault's idle assets, thus making these idle assets available for withdrawals.
Zero-Fee forceDeallocate
Setting the forceDeallocatePenalty to zero on the Morpho Vault V2 for the MorphoMarketV1AdapterV2 adapter allows users to trigger reallocation at no cost. This effectively makes all vault available liquidity accessible for withdrawals at all times.
Important: The forceDeallocatePenalty is configured at Morpho Vault V2 level per adapter, not globally. You can set it to zero for the MorphoMarketV1AdapterV2 without affecting other adapters in the vault.
Griefing Risk with Zero-Fee forceDeallocate
Setting the penalty to zero introduces a griefing vector: anyone can repeatedly force all available liquidity into the vault's idle assets, even if the curator's intended allocation is different. This is analogous to the Public Allocator griefing dynamics in Morpho Vault V1.
After a griefing event, the allocator bot would need to reallocate funds back to the intended distribution.
Mitigation
This is a fundamental tradeoff of making all liquidity available at all times. To reduce the impact of griefing:
- Ensure the reallocation bot can respond quickly to restore the intended allocation.
- Monitor for repeated
forceDeallocatecalls and adjust the penalty if griefing becomes persistent.
Summary
| Aspect | Morpho Vault V1 | Morpho Vault V2 with MarketV1AdapterV2 |
|---|---|---|
| Withdrawal source | Iterates through withdraw queue across multiple markets | Single liquidity market at a time |
| Liquidity curation | Manual or bot-driven reallocation | Bot dynamically reallocates liquidity via liquidityData or changes the liquidity adapter |
| Fallback mechanism | Queue iteration | forceDeallocate (permissionless) |
| Gas cost | Higher per tx | Lower per tx |
| Griefing surface | Public Allocator manipulation | forceDeallocate manipulation (if penalty is zero) |
Good Practices
- Use
MorphoMarketV1AdapterV2as your liquidity adapter for lower gas costs. - Run a reallocation bot that monitors liquidity and dynamically switch the liquidity adapter as conditions change.
- Set
forceDeallocatePenaltyto zero on the Morpho Vault V2 for theMorphoMarketV1AdapterV2adapter to ensure withdrawals are never stuck. - Monitor for allocation drift. As with Morpho Vault V1, the allocator should reallocate to maintain yield and risk profile.
