Skip to content

[P2P] Move Peerstore interface to a module-shared pkg #811

@bryanchriswhite

Description

@bryanchriswhite

Objective

Support usage of the Peerstore interface type in (sub)module method signatures while preventing import cycles.

Origin Document

Observation made while working on #732 & #855. In order to complete the peerstore provider refactor as a submodule the Peerstore type needs to be moved to avoid creating an import cycle between the p2p/types package and the shared/modules package.

Goals

  • Avoid import cycle on Peerstore.

Deliverable

  • Move the Peerstore interface from p2p/types/peerstore.go to a shared/core/types (or similar / more appropriate)

Non-goals / Non-deliverables

  • Unrelated refactoring

General issue deliverables

  • Update the appropriate CHANGELOG(s)
  • Update any relevant local/global README(s)
  • Update relevant source code tree explanations
  • Add or update any relevant or supporting mermaid diagrams

Testing Methodology

  • All tests: make test_all
  • LocalNet: verify a LocalNet is still functioning correctly by following the instructions at docs/development/README.md
  • k8s LocalNet: verify a k8s LocalNet is still functioning correctly by following the instructions here

Creator: @bryanchriswhite

Metadata

Metadata

Labels

coreCore infrastructure - protocol relatedp2pP2P specific changes

Type

No type

Projects

Status

Up Next

Relationships

None yet

Development

No branches or pull requests

Issue actions