Skip to content

v0.1.0

Compare
Choose a tag to compare
@PaulZhemanov PaulZhemanov released this 05 Sep 21:51
· 137 commits to main since this release

Changelog for Spark Order Book

[v0.1.0] - 2024-09-06

Changes in Configuration for Spark Order Book (config.yaml)

  • Added New Events:
    • The following events were added to the configuration:
      • DepositEvent
      • WithdrawEvent

Changes in GraphQL Schema (schema.graphql)

  • New Event Types:

    • The following event types were added to the schema:
      • DepositEvent: Tracks asset deposits by users.
      • WithdrawEvent: Tracks asset withdrawals by users.
  • Updated Event Types:

    • The CancelOrderEvent type now includes the user field to track which user canceled the order.
    • The TradeOrderEvent type now includes seller and buyer fields to track participants in the trade.
  • Removed Event Type:

    • The MatchOrderEvent type was removed, simplifying the schema by eliminating unused event types.
  • New Balance Type:

    • A Balance type was introduced to track user balances of assets within the system. This type includes fields:
      • id: The unique identifier of the balance.
      • amount: The amount of the asset the user holds.
      • asset: The type of asset (base or quote).
      • user: The user associated with the balance.
      • timestamp: The last updated time of the balance.

Changes in Handlers (OrderBookHandlers.ts)

  • Added Handlers for New Events:

    • DepositEvent and WithdrawEvent handlers were added to handle user deposits and withdrawals, updating the user balances accordingly.
  • Balance Adjustments:

    • Handlers for CancelOrderEvent and TradeOrderEvent now update user balances when orders are canceled or trades are executed.
  • Removed Match Order Logic:

    • The logic and handler for MatchOrderEvent were removed as the event is no longer part of the schema.

These changes bring improvements to the event tracking system and the management of user balances, while simplifying the schema by removing unused elements.

Full Changelog: v0.0.5...v0.1.0