Skip to content

Commit

Permalink
Merge pull request #720 from 0xProject/release/9.0.1
Browse files Browse the repository at this point in the history
Release version 9.0.1
  • Loading branch information
albrow committed Feb 21, 2020
2 parents ccec0f3 + f10e11e commit 1a4a775
Show file tree
Hide file tree
Showing 17 changed files with 809 additions and 630 deletions.
2 changes: 1 addition & 1 deletion .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ steps:
api_key:
from_secret: github_public_repo
files:
- /
- *
note: RELEASE_CHANGELOG.md
when:
event: tag
Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

This changelog is a work in progress and may contain notes for versions which have not actually been released. Check the [Releases](https://github.com/0xProject/0x-mesh/releases) page to see full release notes and more information about the latest released versions.

## v9.0.1

### Bug fixes 🐞

- Fix bug where we weren't enforcing that we never store more than `miniHeaderRetentionLimit` block headers in the DB. This caused [issue #667](https://github.com/0xProject/0x-mesh/issues/667) and also caused the Mesh node's DB storage to continuously grow over time. ([#716](https://github.com/0xProject/0x-mesh/pull/716))

## v9.0.0

### Breaking changes 🛠
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Version](https://img.shields.io/badge/version-9.0.0-orange.svg)](https://github.com/0xProject/0x-mesh/releases)
[![Version](https://img.shields.io/badge/version-9.0.1-orange.svg)](https://github.com/0xProject/0x-mesh/releases)
[![Docs](https://img.shields.io/badge/docs-website-yellow.svg)](https://0x-org.gitbook.io/mesh)
[![Chat with us on Discord](https://img.shields.io/badge/chat-Discord-blueViolet.svg)](https://discord.gg/HF7fHwk)
[![Circle CI](https://img.shields.io/circleci/project/0xProject/0x-mesh/master.svg)](https://circleci.com/gh/0xProject/0x-mesh/tree/master)
Expand Down
19 changes: 2 additions & 17 deletions RELEASE_CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,10 @@
- [Docker image](https://hub.docker.com/r/0xorg/mesh/tags)
- [README](https://github.com/0xProject/0x-mesh/blob/v9.0.0/README.md)
- [README](https://github.com/0xProject/0x-mesh/blob/v9.0.1/README.md)

## Summary

### Breaking changes 🛠

- As a result of implementing custom order filters, some of the code Mesh uses under the hood to share orders with peers has changed. As a result this version of Mesh cannot share orders with any older versions and vice versa ([#630](https://github.com/0xProject/0x-mesh/pull/630)).
- Implemented a new protocol for sharing existing orders with peers. This will drastically reduce bandwidth and CPU usage and increase the speed at which _new_ orders are propagated. ([#692](https://github.com/0xProject/0x-mesh/pull/692)).
- Rename `RPC_ADDR` to `WS_RPC_ADDR` since we now support both WS and HTTP JSON-RPC endpoints. ([#658](https://github.com/0xProject/0x-mesh/pull/658))

### Features ✅

- Implemented custom order filters, which allow users to filter out all but the orders they care about. When a custom order filter is specified, Mesh will only send and receive orders that pass the filter. ([#630](https://github.com/0xProject/0x-mesh/pull/630)).
- Developers can now override the contract addresses for any testnet using the `CUSTOM_CONTRACT_ADDRESSES` env config ([#640](https://github.com/0xProject/0x-mesh/pull/640)).
- Added `getOrdersForPageAsync` method to `@0x/mesh-rpc-client` WS client interface so that clients can paginate through the retrieved orders themselves ([#642](https://github.com/0xProject/0x-mesh/pull/642)).
- Added support for passing in your own Web3 provider when using the `@0x/mesh-browser` package. ([#665](https://github.com/0xProject/0x-mesh/pull/665)).
- Add support for orders involving Chai ERC20Bridge assetData ([#663](https://github.com/0xProject/0x-mesh/pull/663))
- Add support for calling JSON-RPC methods over HTTP (env config `HTTP_RPC_ADDR` defaults to `localhost:60556`). ([#658](https://github.com/0xProject/0x-mesh/pull/658))

### Bug fixes 🐞

- Fixed some of the browser typescript bindings to be consistent with the Go and smart contract implementations ([#697](https://github.com/0xProject/0x-mesh/pull/697)).
- Fix bug where we weren't enforcing that we never store more than `miniHeaderRetentionLimit` block headers in the DB. This caused [issue #667](https://github.com/0xProject/0x-mesh/issues/667) and also caused the Mesh node's DB storage to continuously grow over time. ([#716](https://github.com/0xProject/0x-mesh/pull/716))


2 changes: 1 addition & 1 deletion browser/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@0x/mesh-browser",
"version": "9.0.0",
"version": "9.0.1",
"description": "TypeScript and JavaScript bindings for running Mesh directly in the browser.",
"main": "./lib/index.js",
"license": "Apache-2.0",
Expand Down
19 changes: 16 additions & 3 deletions core/core.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ import (
)

const (
blockWatcherRetentionLimit = 20
ethereumRPCRequestTimeout = 30 * time.Second
peerConnectTimeout = 60 * time.Second
checkNewAddrInterval = 20 * time.Second
Expand All @@ -61,7 +60,7 @@ const (
estimatedNonPollingEthereumRPCRequestsPer24Hrs = 50000
// logStatsInterval is how often to log stats for this node.
logStatsInterval = 5 * time.Minute
version = "9.0.0"
version = "9.0.1"
// ordersyncMinPeers is the minimum amount of peers to receive orders from
// before considering the ordersync process finished.
ordersyncMinPeers = 5
Expand Down Expand Up @@ -307,12 +306,26 @@ func New(config Config) (*App, error) {
if err != nil {
return nil, err
}

// Remove any old mini headers that might be lingering in the database.
// See https://github.com/0xProject/0x-mesh/issues/667 and https://github.com/0xProject/0x-mesh/pull/716
// We need to leave this in place becuase:
//
// 1. It is still necessary for anyone upgrading from older versions to >= 9.0.1 in the future.
// 2. There's still a chance there are old MiniHeaders in the database (e.g. due to a sudden
// unexpected shut down).
//
err = meshDB.PruneMiniHeadersAboveRetentionLimit()
if err != nil {
return nil, err
}

topics := orderwatch.GetRelevantTopics()
miniHeaders, err := meshDB.FindAllMiniHeadersSortedByNumber()
if err != nil {
return nil, err
}
stack := simplestack.New(blockWatcherRetentionLimit, miniHeaders)
stack := simplestack.New(meshDB.MiniHeaderRetentionLimit, miniHeaders)
blockWatcherConfig := blockwatch.Config{
Stack: stack,
PollingInterval: config.BlockPollingInterval,
Expand Down

0 comments on commit 1a4a775

Please sign in to comment.