Skip to content

Sedimark/catalogue-coordinator

Repository files navigation

Catalogue Coordinator

The Catalogue Coordinator is a Python service designed to synchronize offering data from the SEDIMARK Registry (a Decentralized Ledger Technology (DLT)) source into the Catalogue service. It operates by periodically polling the DLT for new NFT addresses, querying metadata from each one, and posting or removing entries in the Catalogue based on their availability.

catalogue coordinator

🔧 Features

  • Polls the DLT service every configurable interval for NFTs addresses with Offering metadata.
  • In-memory TTL cache prevents duplicate processing within a time window.
  • Fetches offering data from NFT metadata field descriptionUri.
  • Posts valid offerings to the Catalogue or deletes invalid/unavailable ones.
  • Includes retry and backoff logic for robust error handling.

🚀 Deployment Tutorial (Using Docker)

✅ Prerequisites

  • Docker & Docker Compose

  • Update the .env file with your custom configuration values:

    DLT_BASE_URL=https://your-dlt-booth.com
    CATALOGUE_BASE_URL=https://catalogue-service.com
    POLL_INTERVAL_SECONDS=300
    CACHE_TTL_SECONDS=3600
    

🐳 Build and Run

1. Just run the docker-compose file:
docker-compose up -d

📜 File structure

.
├── catalogue-coordinator.py  # Python entry point
├── config.py                 # Loads environment variables
├── utils/
│   ├── cache.py              # TTL-based ID cache
│   ├── dlt_client.py         # Functions to query the DLT
│   ├── catalogue_client.py   # Functions to post/delete to Catalogue
│   └── worker.py             # NFTs and Offerings handler logic
├── Dockerfile
├── docker-compose.yml
├── requirements.txt          # required python packages
├── .env
└── README.md

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •