mirror of
https://github.com/fluencelabs/js-libp2p
synced 2025-07-11 14:51:34 +00:00
Compare commits
38 Commits
v0.29.0-rc
...
v0.29.0
Author | SHA1 | Date | |
---|---|---|---|
bbf8ef7065 | |||
d6d1a746ea | |||
28b79a76a8 | |||
81e70df742 | |||
e9478cee2e | |||
7be17a3ce1 | |||
93dda74085 | |||
cfbd52d7f7 | |||
6cd23ea6c9 | |||
9b75a0f184 | |||
b606ce0e91 | |||
64c8c0f097 | |||
9be582e222 | |||
55c9bfac44 | |||
1e869717ff | |||
9107efe121 | |||
cd09327eb6 | |||
ca57e65ecc | |||
f574e82a5d | |||
15613ccf19 | |||
dab1c8b2a5 | |||
d437defede | |||
74d414c21f | |||
8f2e69048f | |||
b0a36ccbc8 | |||
3158366579 | |||
1d318e12d8 | |||
8a97dded26 | |||
e50f0eeb7b | |||
ee57a643cc | |||
89658dd655 | |||
4ab125e017 | |||
71daac24b1 | |||
02a5095b9c | |||
3e5d450eca | |||
098f3d1dd3 | |||
689f90a698 | |||
0e3cc5866b |
82
CHANGELOG.md
82
CHANGELOG.md
@ -1,3 +1,85 @@
|
|||||||
|
<a name="0.29.0"></a>
|
||||||
|
# [0.29.0](https://github.com/libp2p/js-libp2p/compare/v0.28.10...v0.29.0) (2020-08-27)
|
||||||
|
|
||||||
|
|
||||||
|
### Bug Fixes
|
||||||
|
|
||||||
|
* do not return self on peerstore.peers ([15613cc](https://github.com/libp2p/js-libp2p/commit/15613cc))
|
||||||
|
* peer record interop with go ([#739](https://github.com/libp2p/js-libp2p/issues/739)) ([93dda74](https://github.com/libp2p/js-libp2p/commit/93dda74))
|
||||||
|
* replace node buffers with uint8arrays ([#730](https://github.com/libp2p/js-libp2p/issues/730)) ([1e86971](https://github.com/libp2p/js-libp2p/commit/1e86971))
|
||||||
|
* revert new identify protocol versions ([3158366](https://github.com/libp2p/js-libp2p/commit/3158366))
|
||||||
|
* signature compliant with spec ([4ab125e](https://github.com/libp2p/js-libp2p/commit/4ab125e))
|
||||||
|
|
||||||
|
|
||||||
|
### Chores
|
||||||
|
|
||||||
|
* update travis to use node lts and stable ([098f3d1](https://github.com/libp2p/js-libp2p/commit/098f3d1))
|
||||||
|
|
||||||
|
|
||||||
|
### Features
|
||||||
|
|
||||||
|
* cerified addressbook ([8f2e690](https://github.com/libp2p/js-libp2p/commit/8f2e690))
|
||||||
|
* create self peer record in identify ([8a97dde](https://github.com/libp2p/js-libp2p/commit/8a97dde))
|
||||||
|
* exchange signed peer records in identify ([e50f0ee](https://github.com/libp2p/js-libp2p/commit/e50f0ee))
|
||||||
|
* gossipsub 1.1 ([#733](https://github.com/libp2p/js-libp2p/issues/733)) ([55c9bfa](https://github.com/libp2p/js-libp2p/commit/55c9bfa))
|
||||||
|
* signed peer records record manager ([3e5d450](https://github.com/libp2p/js-libp2p/commit/3e5d450))
|
||||||
|
|
||||||
|
|
||||||
|
### Reverts
|
||||||
|
|
||||||
|
* reapply "fix: throw if no conn encryption module provided ([#665](https://github.com/libp2p/js-libp2p/issues/665))" ([689f90a](https://github.com/libp2p/js-libp2p/commit/689f90a))
|
||||||
|
|
||||||
|
|
||||||
|
### BREAKING CHANGES
|
||||||
|
|
||||||
|
* pubsub implementation is now directly exposed and its API was updated according to the new pubsub interface in js-libp2p-interfaces repo
|
||||||
|
|
||||||
|
* chore: use gossipsub branch with src added
|
||||||
|
|
||||||
|
* fix: add pubsub handlers adapter
|
||||||
|
|
||||||
|
* chore: fix deps
|
||||||
|
|
||||||
|
* chore: update pubsub docs and examples
|
||||||
|
|
||||||
|
* chore: apply suggestions from code review
|
||||||
|
|
||||||
|
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
|
||||||
|
|
||||||
|
* chore: use new floodsub
|
||||||
|
|
||||||
|
* chore: change validator doc set
|
||||||
|
|
||||||
|
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
|
||||||
|
|
||||||
|
* chore: add new gossipsub src
|
||||||
|
|
||||||
|
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
|
||||||
|
* - All deps used by this module now use Uint8Arrays in place of node Buffers
|
||||||
|
|
||||||
|
* chore: browser fixes
|
||||||
|
|
||||||
|
* chore: remove .only
|
||||||
|
|
||||||
|
* chore: stringify uint8array before parsing
|
||||||
|
|
||||||
|
* chore: update interop suite
|
||||||
|
|
||||||
|
* chore: remove ts from build command
|
||||||
|
|
||||||
|
* chore: update deps
|
||||||
|
|
||||||
|
* fix: update records to use uint8array
|
||||||
|
|
||||||
|
* chore: fix lint
|
||||||
|
|
||||||
|
* chore: update deps
|
||||||
|
|
||||||
|
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
|
||||||
|
* this drops testing support in node 10.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<a name="0.29.0-rc.1"></a>
|
<a name="0.29.0-rc.1"></a>
|
||||||
# [0.29.0-rc.1](https://github.com/libp2p/js-libp2p/compare/v0.29.0-rc.0...v0.29.0-rc.1) (2020-08-27)
|
# [0.29.0-rc.1](https://github.com/libp2p/js-libp2p/compare/v0.29.0-rc.0...v0.29.0-rc.1) (2020-08-27)
|
||||||
|
|
||||||
|
@ -1220,7 +1220,7 @@ Get the stored information of a given peer, namely its [`PeerId`][peer-id], know
|
|||||||
|
|
||||||
| Type | Description |
|
| Type | Description |
|
||||||
|------|-------------|
|
|------|-------------|
|
||||||
| `{ id: PeerId, addresses: Array<Address>, protocols: Array<string> }` | Peer information of the provided peer |
|
| `{ id: PeerId, addresses: Array<Address>, metadata: Map<string, Buffer>}, protocols: Array<string> }` | Peer information of the provided peer |
|
||||||
|
|
||||||
#### Example
|
#### Example
|
||||||
|
|
||||||
@ -1247,13 +1247,13 @@ Get all the stored information of every peer.
|
|||||||
|
|
||||||
| Type | Description |
|
| Type | Description |
|
||||||
|------|-------------|
|
|------|-------------|
|
||||||
| `Map<string, { id: PeerId, addresses: Array<Address>, protocols: Array<string> }>` | Peer data of every peer known |
|
| `Map<string, { id: PeerId, addresses: Array<Address>, metadata: Map<string, Buffer>}, protocols: Array<string> }>` | Peer data of every peer known |
|
||||||
|
|
||||||
#### Example
|
#### Example
|
||||||
|
|
||||||
```js
|
```js
|
||||||
for (let [peerIdString, peer] of peerStore.peers.entries()) {
|
for (let [peerIdString, peer] of peerStore.peers.entries()) {
|
||||||
// peer { id, addresses, protocols }
|
// peer { id, addresses, metadata, protocols }
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "libp2p",
|
"name": "libp2p",
|
||||||
"version": "0.29.0-rc.1",
|
"version": "0.29.0",
|
||||||
"description": "JavaScript implementation of libp2p, a modular peer to peer network stack",
|
"description": "JavaScript implementation of libp2p, a modular peer to peer network stack",
|
||||||
"leadMaintainer": "Jacob Heun <jacobheun@gmail.com>",
|
"leadMaintainer": "Jacob Heun <jacobheun@gmail.com>",
|
||||||
"main": "src/index.js",
|
"main": "src/index.js",
|
||||||
@ -92,7 +92,7 @@
|
|||||||
"cids": "^1.0.0",
|
"cids": "^1.0.0",
|
||||||
"delay": "^4.3.0",
|
"delay": "^4.3.0",
|
||||||
"dirty-chai": "^2.0.1",
|
"dirty-chai": "^2.0.1",
|
||||||
"interop-libp2p": "libp2p/interop#chore/gossipsub-1.1",
|
"interop-libp2p": "^0.3.0",
|
||||||
"ipfs-http-client": "^46.0.0",
|
"ipfs-http-client": "^46.0.0",
|
||||||
"it-concat": "^1.0.0",
|
"it-concat": "^1.0.0",
|
||||||
"it-pair": "^1.0.0",
|
"it-pair": "^1.0.0",
|
||||||
|
@ -32,6 +32,7 @@ class PeerStore extends EventEmitter {
|
|||||||
* @property {PeerId} id peer's peer-id instance.
|
* @property {PeerId} id peer's peer-id instance.
|
||||||
* @property {Array<Address>} addresses peer's addresses containing its multiaddrs and metadata.
|
* @property {Array<Address>} addresses peer's addresses containing its multiaddrs and metadata.
|
||||||
* @property {Array<string>} protocols peer's supported protocols.
|
* @property {Array<string>} protocols peer's supported protocols.
|
||||||
|
* @property {Map<string, Buffer>} metadata peer's metadata map.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -311,7 +311,11 @@ describe('Pubsub subsystem operates correctly', () => {
|
|||||||
expect(handlerSpy.args.map(([message]) => uint8ArrayToString(message.data))).to.include.members(['message1', 'message2'])
|
expect(handlerSpy.args.map(([message]) => uint8ArrayToString(message.data))).to.include.members(['message1', 'message2'])
|
||||||
|
|
||||||
// Disconnect the first connection (this acts as a delayed reconnect)
|
// Disconnect the first connection (this acts as a delayed reconnect)
|
||||||
|
const libp2pConnUpdateSpy = sinon.spy(libp2p.connectionManager.connections, 'set')
|
||||||
|
const remoteLibp2pConnUpdateSpy = sinon.spy(remoteLibp2p.connectionManager.connections, 'set')
|
||||||
|
|
||||||
await originalConnection.close()
|
await originalConnection.close()
|
||||||
|
await pWaitFor(() => libp2pConnUpdateSpy.callCount === 1 && remoteLibp2pConnUpdateSpy.callCount === 1)
|
||||||
|
|
||||||
// Verify messages go both ways after the disconnect
|
// Verify messages go both ways after the disconnect
|
||||||
handlerSpy.resetHistory()
|
handlerSpy.resetHistory()
|
||||||
|
Reference in New Issue
Block a user