Releases: bosnet/sebak
0.1.4-rc2: Better consensus, jsonrpc.Snapshot, improved tx API
New features
The JSONRPC endpoints now support a Snapshot
method
This allows to get an atomic view of the LevelDB data,
which in turn can be used for backups and other operations requiring atomic access.
An example usage can be found here.
/transactions
endpoints now contains operations, not just links
A common usage of the transactions API endpoint was to get the transaction,
and then immediately get every associated operations.
Besides being a great way to DoS the API, this was not very convenient for callers,
so operations are now included in full instead of a mere link.
At some point in a future release, the operations endpoint will be cast into oblivion.
Sebak can auto-sync the system time
If time-sync is configured (via --ntp=my.ntp.server.net
CLI arg
or SEBAK_NTP_SERVER
env variable), sebak will frequently (every minute)
issue a query to the NTP server.
If the diff is over 4 seconds, Sebak will attempt to set the time, system-wide,
by calling sh $SEBAK_TIME_SYNC_COMMAND
(cmd
on Windows).
This can also be configured via the --time-sync-command=cmd
CLI argument.
The default server is time.bora.net
, and the default command is nothing,
disabling this feature by default.
Bug fixes
Saving blocks hangs when some blocks are missing
A minor bug led to Sebak hanging in some erroneous condition,
instead of correctly reporting an error.
Consensus stuck after recovering enough validators
Under certain circumstances, a network could get stuck if a prolonged outage happened.
Nodes now expose a /node/ballots
API, used by the consensus protocol,
and will no longer expose this behavior.
Retry when ballot sending fails
Another liveness fix: network outage could results in nodes not talking to each other anymore.
Nodes are now much more insistent in having their ballot taken into account by other nodes,
pestering them as much as needed.
Changes
Improvements to memory usage
In an effort to reduce memory and disk usage, some refactoring reduced the overhead of operations.
This currently only have an impact on the memory usage of Sebak,
but should soon lead to large reductions of the disk usage as well.
Slight changes in the Client API
If you are using the client API that comes with Sebak, you might notice your project now fails to compile.
Worry not, for the changes are minimal: Use client.MustNewClient
instead of client.NewClient
(or the later if you wish to check for the returned error instead of panicking),
remove the body
parameter from client.StreamTransactionStatus
(it was not used anyway),
same thing for the id
parameter of client.StreamAccount
(and same reasoning),
and replace your calls to client.StreamTransactionsByHash
by calls to client.StreamTransactions
,
as the later now provide the ability to listen to multiple transactions with one call.
... And more!
A few internal changes are not listed here for brevity and because they only affect the Go API.
If your Go code broke, we're sorry, and a git blame
should give you enough informations to fix your code.
In addition, a full list of commits is available here.
Add option for set up validator and discovery node.
Important Changes
Please see #705.
Originally this feature was brought at v0.1.3, but we think it is important change so we introduce once again. Previous release v0.1.2 , node must know these things about its validators,
- all public addresses of nodes.
- all endpoints of nodes.
When one of the endpoints is updated, all the nodes in the network must be restarted with the updated endpoints. This will be a painful job for maintenance.
This change will solve this problem and new endpoint of validators will be updated without downtime.
--validators
only with public address.
The current way to set --validators
is,
--validators "self https://127.0.0.1:2822?address=G..W&alias=node2 https://127.0.0.1:2823/?address=G..4&alias=node3 https://127.0.0.1:2824/?address=G..O&alias=node4"
New way to set up validators only with public address like below;
--validators "self G..W G..4 G..O"
Caution : Node just knows only the public address, the variable information like endpoint and alias are removed.
The environment variable also can be set like below;
SEBAK_VALIDATORS="self G..W G..4 G..O"
Note : New option, --discovery
--discovery https://1.2.3.4:5678 --discovery https://8.7.6.5:4321
Instead of setting endpoint in --validators
option, using --discovery
node will try to discover the validators. When a node starts, the node will send network.DiscoveryMessage to --discovery
values. Each node sends and receives network.DiscoveryMessages, the node can be started until the number of discovered validators is over consensus threshold.
--discovery
also can be set by an environment variable, SEBAK_DISCOVERY
, multiple values can be separated by empty space.
Omitting -discovery
option also be possible. Without --discovery
node will just wait network.DiscoveryMessage
from other nodes.
WatcherMode
Watcher does not care about the validator, it just needs the target node to watch. Watcher will use --discovery
instead of --validators
, the node address will be fetched from the node info of --discovery
node. At this process, the remote node info is compared with watcher; the network id and initial balance are matched.
For more about this changes, please see #705, Adaptable Discovering Nodes.
Changes
You can see other changes in #883 ,#893.
Detailed changes you can see through here -
Fixed syncer
The major changes are,
- fixed #883
- support the adaptable node discovery #705; The watcher should change the deploy option, please check the updated instruction https://github.com/bosnet/docs/blob/78ed47ffb0f2a099e29be7e7bcb9d03a49a598b7/sebak/watcher_mode.md .
- The minor changes can be checked at https://github.com/bosnet/sebak/compare/0.1.3..0.1.2 .
Support watcher
- Watcher is officially supported
All the changes can be found at https://github.com/bosnet/sebak/issues?utf8=✓&q=+project%3Abosnet%2Fsebak%2F9+ .
First release candidate for 0.1.2
This changes a lot, but most of all this version will be the first watcher support.
First Patch
This is the first patch update.
First SEBAK Stable
This is the first release of SEBAK to the public. This version will be used for launching BOScoin mainnet. Thanks for developers and our community.