Abstraction

Although all General Message Passing (GMP) protocols are designed to enable the exchange of cross-chain messages, each one features its own unique interface and interaction mechanism. Significant variations exist primarily in terms of:

  • Interface: Different function names, parameter number and format

  • Security: Requirement of pre-approvement of the destination address

  • Identification: Arbitrary chain Codification (chainId)

  • Payment: Native or ERC20 acceptance, exact amount or overpay/refund approaches

  • Interaction: Payment or price quoting in advance

In the following example source and destination contracts are interacting with a GMP that:

  • Requires a separated payment function with refund

  • Uses string format for the message payload

  • Uses an arbitrary vendor defined chain ID

  • Requires to implement a specific reception interface

In this other example source and destination contracts are interacting with a GMP that:

  • Requires an initial query for the current operation price

  • Uses byte array format for the message payload

  • Uses an arbitrary vendor defined chain ID

  • Requires to implement a specific reception interface

These variations can be specifically challenging when trying to work with more than one GMP:

This translates to:

  • Increased complexity: Users or developers have to deal with all the different details of each GMP implementation. New team members have a steeper learning curve of the protocol.

  • Less Flexibility: Switching to a new GMP becomes challenging in the event of a hack or downtime of the current one.

  • Difficulty in Maintenance: Since the high-level functionality is tightly coupled with the GMP implementation, a change in GMP interface will require rewriting of all the components and related tests.

Glacis Abstraction

The Abstraction functionality of Glacis enables users and developers to engage with any compatible General Message Passing (GMP) solution seamlessly, using a singular, streamlined interaction flow, without the necessity to understand the intricate usage details inherent to each solution.

When engaging with multiple GMP protocols, the abstraction layer of Glacis ensures a consistent user interface. This means that regardless of the number or type of GMPs involved, users experience a uniform interaction pattern.

Last updated