Skip to content

Conversation

@matiwinnetou
Copy link
Collaborator

No description provided.

@matiwinnetou matiwinnetou changed the base branch from main to develop2 October 30, 2025 14:06
Implement support for Cardano Node 10.5.1 which uses Ouroboros Genesis consensus protocol.
This replaces bootstrap peers with big ledger peer snapshots for better decentralization.

Changes:
- Add PeerSnapshotService to load peers from Genesis peer snapshot files
- Create model classes for BigLedgerPool, PeerSnapshotConfig, and Relay
- Update TopologyConfigServiceImpl to use peer snapshots with bootstrap fallback
- Add support for domain, IPv4, IPv6, and address relay formats
- Update mainnet, preprod, and preview topology.json to use peer-snapshot.json
- Add comprehensive unit tests (16 test cases) using mainnet peer snapshot
- Keep devkit with bootstrap peers for backward compatibility

The implementation maintains dynamic peer discovery priority:
1. Try dynamically discovered peers from yaci-indexer (when enabled)
2. Fallback to static peers from peer-snapshot.json (Genesis mode)
3. Fallback to bootstrap peers (legacy mode)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@matiwinnetou matiwinnetou merged commit c2a4002 into develop2 Oct 30, 2025
2 of 4 checks passed
@matiwinnetou matiwinnetou deleted the genesis-support branch October 30, 2025 15:23
matiwinnetou added a commit that referenced this pull request Nov 4, 2025
* fix: enable peer discovery by default.

* refactor: remove assetName (#619)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>

* fix: symbol search will be now in hex, not ascii, which will support CIP-26, CIP-68 and other type of such assets. (#620)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>

* chore: upgrade cardano-node from 10.4.1 to 10.5.1 (#626)

Updates cardano-node version across Dockerfile, config files, and documentation to 10.5.1.

Key changes in 10.5.1:
- PeerSharing configuration behavior changes (default depends on BP vs relay)
- Networking improvements (DNS caching reduced to 15min, Windows socket fixes)
- Tracing system improvements for slotsMissed_int metric

Changes:
- Update CARDANO_NODE_VERSION build arg to 10.5.1 in both Dockerfiles
- Update MinNodeVersion to 10.5.0 in mainnet/preprod/preview configs
- Download official config.json, topology.json, checkpoints.json for all networks
- Download peer-snapshot.json for mainnet, preprod, and preview
- Keep hasPrometheus as 0.0.0.0 in all configs for metrics access
- Update version references in documentation and test configs

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>

* chore: upgrade mithril from 2524.0 to 2537.0 (#630)

Updated Mithril version across all Docker and environment configuration files to use the latest release 2537.0.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>

* chore: update cardano-node version to 10.5.1 in remaining env files

Updated CARDANO_NODE_VERSION from 10.4.1 to 10.5.1 in additional environment configuration files that were missed in the previous upgrade.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* fix: separate versions for cnode/mithril/pg in dockerhub

* chore: disable peer discovery by default

Set PEER_DISCOVERY to false in the default docker-compose configuration.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* chore: version upgrade to 1.4.1

Updated project version from 1.4.0 to 1.4.1 in pom.xml and README.md Docker run examples.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* chore: update peer discovery and token registry config

- Remove outdated token registry comment from preprod config
- Change peer discovery initial delay from 1 to 5 minutes
- Refactor TimeUnit import to use static import for MINUTES

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* fix: add Ouroboros Genesis support for Cardano Node 10.5.1+ (#637)

Implement support for Cardano Node 10.5.1 which uses Ouroboros Genesis consensus protocol.
This replaces bootstrap peers with big ledger peer snapshots for better decentralization.

Changes:
- Add PeerSnapshotService to load peers from Genesis peer snapshot files
- Create model classes for BigLedgerPool, PeerSnapshotConfig, and Relay
- Update TopologyConfigServiceImpl to use peer snapshots with bootstrap fallback
- Add support for domain, IPv4, IPv6, and address relay formats
- Update mainnet, preprod, and preview topology.json to use peer-snapshot.json
- Add comprehensive unit tests (16 test cases) using mainnet peer snapshot
- Keep devkit with bootstrap peers for backward compatibility

The implementation maintains dynamic peer discovery priority:
1. Try dynamically discovered peers from yaci-indexer (when enabled)
2. Fallback to static peers from peer-snapshot.json (Genesis mode)
3. Fallback to bootstrap peers (legacy mode)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>

* test: fix currency hex encoding and refactor

Issue #610 fixed: /search/transactions now requires hex-encoded currency symbols.
Updated all tests to comply with this change and fixed several validation issues.

Changes:
- Add symbol_hex field to network_test_data.yaml for native assets
- Convert test_native_asset_filtering_by_ascii_symbol to negative test
  (expects error 5059)
- Unskip test_currency_filter_with_hex_encoded_symbol (issue #610 now fixed)
- Update all currency search tests to use hex symbols instead of ASCII
- Fix test assertions to validate ALL transactions contain filtered asset (not just "at least one")
- Correct tokenBundle validation (native assets live there, not in operation amounts)
- Update peer discovery test for Genesis mode (peer-snapshot.json) with time-based validation
- Refactor token_registry tests: convert assertion helpers to pytest fixtures
- Fix registry metadata extraction to handle v2 API structure ({value,
  source} objects)
- Fix test_rosetta_metadata_matches_registry to compare Rosetta vs Registry (not vs config)
- Add "domain" to valid peer types (Genesis peer-snapshot.json support)

* ci: DRY test env configuration in PR workflow

- Extracted env var configuration into configure_test_env() function.
- Ensures rollback stage uses same config as PR test stage (fixes missing PEER_DISCOVERY and other vars in rollback).
- Document testing patterns learned during hex symbol migration

* feat: limit and randomize peer discovery to 25 peers (#640)

Implements peer limiting and randomization to improve network peer distribution:
- Limits peer responses to 25 peers (configurable via MAX_PEERS constant)
- Randomizes peer selection on each load/discovery to avoid always returning the same peers
- Updates PeerSnapshotServiceImpl to shuffle and limit peers from snapshot files
- Updates PeerDiscoveryManager to shuffle and limit discovered peers from cardano-node
- Maintains deterministic in-memory cache between refreshes
- Updates tests to reflect new peer limiting and randomization behavior

This prevents excessive peer lists and naturally distributes connections across the network
without needing to track peer performance metrics.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>

---------

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: VladislavKudrin <vladislavkudrin@gmail.com>
Co-authored-by: Lincon Vidal <lincon.vidal@cardanofoundation.org>
matiwinnetou added a commit that referenced this pull request Nov 4, 2025
Implement support for Cardano Node 10.5.1 which uses Ouroboros Genesis consensus protocol.
This replaces bootstrap peers with big ledger peer snapshots for better decentralization.

Changes:
- Add PeerSnapshotService to load peers from Genesis peer snapshot files
- Create model classes for BigLedgerPool, PeerSnapshotConfig, and Relay
- Update TopologyConfigServiceImpl to use peer snapshots with bootstrap fallback
- Add support for domain, IPv4, IPv6, and address relay formats
- Update mainnet, preprod, and preview topology.json to use peer-snapshot.json
- Add comprehensive unit tests (16 test cases) using mainnet peer snapshot
- Keep devkit with bootstrap peers for backward compatibility

The implementation maintains dynamic peer discovery priority:
1. Try dynamically discovered peers from yaci-indexer (when enabled)
2. Fallback to static peers from peer-snapshot.json (Genesis mode)
3. Fallback to bootstrap peers (legacy mode)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Mateusz Czeladka <mateusz.czeladka@cardanofoundation.org>
Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants