You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## @Reviewer
This PR may be more digestible / reviewable on a commit-by-commit basis.
Commits are organized logically and any given line is only modified in a
single commit, with few exceptions.
---
## Description
Re-consolidates Libp2p and P2P modules and types.
## Issue
Fixes#554
## Type of change
Please mark the relevant option(s):
- [ ] New feature, functionality or library
- [ ] Bug fix
- [x] Code health or cleanup
- [ ] Major breaking change
- [ ] Documentation
- [ ] Other <!-- add details here if it a different type of change -->
## List of changes
- Moved peer & url conversion utils to `p2p/utils` package
- Refactor `getPeerIP` to use `net.DefaultResolver` for easier testing
- Moved & refactor libp2p `host.Host` setup util to `p2p/utils`
- Consolidated Libp2p & P2P `modules.Module` implementations
- Consolidated Libp2p & P2P `stdnetwork` `typesP2P.Network`
implementations
- Refactored raintree `typesP2P.Network` implementation to use libp2p
- Moved `shared/p2p` package into `p2p/types` packages
- Removed `Trnasport` interface and implementations
- Removed `ConnectionFactory` type and related members
- Added libp2p `host.Host` mock generator
- Refactor debug CLI post P2P module re-consolidation
- Removed *temporary* `shared/p2p` package
- Removed `runtime/configs.Config#UseLibp2p` field
- Use pod IP for validator DNS resolution tilt localnet
- Add `LIBP2P_DEBUG` env var
- Debug logging improvements
- Set validator `POCKET_P2P_HOSTNAME` env var to the pod IP
- Set validator `p2p.hostname` config value to empty string so that the
env var applies
## Testing
- [x] `make develop_test`
- [x]
[LocalNet](https://github.com/pokt-network/pocket/blob/main/docs/development/README.md)
w/ all of the steps outlined in the `README`
## Required Checklist
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [x] I have tested my changes using the available tooling
- [x] I have updated the corresponding CHANGELOG
### If Applicable Checklist
- [ ] I have updated the corresponding README(s); local and/or global
- [x] I have added tests that prove my fix is effective or that my
feature works
- [ ] I have added, or updated,
[mermaid.js](https://mermaid-js.github.io) diagrams in the corresponding
README(s)
- [ ] I have added, or updated, documentation and
[mermaid.js](https://mermaid-js.github.io) diagrams in `shared/docs/*`
if I updated `shared/*`README(s)
---------
Co-authored-by: Daniel Olshansky <[email protected]>
Co-authored-by: Dmitry K <[email protected]>
Co-authored-by: github-actions <[email protected]>
0 commit comments