Switch branches/tags
Find file
Fetching contributors…
Cannot retrieve contributors at this time
432 lines (356 sloc) 32.3 KB

Riak 1.4.2 Release Notes

This is a bugfix release on the Riak 1.4.x series.

  • Fixed various problems related to crashing stats
  • Fixed extra noisy logs introduced in 1.4.1 (Not found errors and others)
  • Fixed issues related to 2i queries timing out
  • Added more protection against corrupt data in backends
  • Fixed incorrect capability negotiation causing nodes to appear incompatible in Riak Control

Issues / PR's Resolved

Riak 1.4.1 Release Notes

This is a bugfix release. The major fixes are to the Secondary Index, Riak Control, and LevelDB subsystems.

  • Pagination for equality queries is fixed by riak_kv/615.

  • The ability to set a timeout on a 2i query has been added by riak_kv/616.

  • Using 2i as input for a map-reduce job has been fixed by riak_kv/618.

  • Riak Control can crash its host node when in a mixed-cluster environment containing a 1.4.0 node. This has been addressed by riak_control/120.

  • Basho's leveldb fork has added better fadvise support and fixed some race conditions in the write path. See leveldb/88.

Issues / PR's Resolved

Riak 1.4.0 Release Notes

Major Features / Improvements

Improved Binary Format

Data stored in Riak can now be represented in a more compact format. The new format reduces storage overhead, especially in the case of small objects or those with large bucket names, keys, or metadata.

By default new Riak clusters, starting with Riak 1.4, will have the new format enabled by default. Users upgrading to Riak 1.4 should first perform the upgrade and once happy with the operation enable the new format. Riak supports both the old and new representation simultaneously, so no additional upgrade process is necessary.

Which representation is used can be configured by setting object_format to either v0 or v1 in the riak_kv section of app.config. v1 is the new format.

The new format is also used during handoff if the cluster supports it.

For users who upgrade to Riak 1.4 and enable the new format, downgrading to a previous version requires reformatting any data written in the new representation (previous version of Riak won't understand it). A utility is provided via riak-admin to perform this operation:

riak-admin downgrade-objects <kill-handoffs> [<concurrency>]

The utility should be run per-node immediately prior to downgrading it. <kill-handoffs> must be either true or false. If false any ongoing handoff will be waited on before performing the reformat. Otherwise, all in-flight handoff, inbound to the node or outbound from it, will be killed. During and after the reformat the transfer-limit will be set to 0. The optional <concurrency> argument must be an integer greater than zero. It determines how many partitions are reformatted on the node concurrently. By default the concurrency is two. Additionally, in anticipation that the entire cluster will be downgraded downgrade-objects sets the preferred format to v0. downgrade-objects can be run multiple times in the case of error or if the node crashes.

Changed behavior of riak attach

If you are a frequent user of riak attach it is worth noting that the behavior has changed in 1.4. riak attach used to attach to a named pipe that erlang provides to talk to running erlang nodes. This is great except that an accidental Ctrl-C would not only kill your session, but also kill the running node. The behavior has now changed to use -remsh (remote shell) to connect to the node. This method is safer because a Ctrl-C will not kill a running node. In cases where distributed erlang having problems for some reason and a -remsh is not wanted, riak attach-direct is a new command which uses the old pipe behavior of riak attach.

riak-admin transfers Improvements

The output of riak-admin transfers now includes per-transfer progress reporting and improved display of long node names.

Whether or not progress is reported and how the progress is calculated is dependent on the cluster's backend. Progress reporting is enabled for riak_kv_bitcask_backend, riak_kv_eleveldb_backend and riak_kv_memory_backend. Clusters using riak_kv_multi_backend will not have progress reporting enabled. When using riak_kv_bitcask_backend or riak_kv_memory_backend progress is determined by the number of keys already transferred out of the total number stored. Large variance in value sizes can skew reporting. For riak_kv_eleveldb_backend progress is measured in stored bytes. The total number of bytes used may be an overestimate -- meaning progress will always be what is reported or further along than reported in the worst case.

Lager Upgrade 1.2.2 to 2.0.0

Lager has been updated in Riak from Lager 1.2.2 that was in the Riak 1.3.x series to Lager 2.0.0. Please see the lager documentation at for the new capabilities in Lager 2.0.


Pagination Support in 2i

We've extended Riak's Secondary Indexing (2i) interface to allow for paginated results. This is done via the max_results option in both the Protocol Buffers and HTTP 2i end points. Full details can be found here.

Client APIs

Client-specified timeouts

Clients can now specify a timeout value, in milliseconds, that will override the default internal timeout on requests that manipulate objects (fetch, store, delete), list buckets, or list keys.

Protocol Buffers bucket properties

The Protocol Buffers interface now supports all known bucket properties, and the ability to "reset" bucket properties to their defaults.

List-buckets streaming

Similar to listing keys, listing buckets can be streamed to clients. This means that Riak will send bucket names to the client as they are received, rather than waiting for the request to complete on all nodes.

Protocol buffers binds to multiple interfaces

Similar to HTTP, Protocol Buffers will now bind to multiple interfaces and ports. Existing configurations will change the previous pb_port and pb_ip settings to the singular pb setting, which is a list of IP/port pairs.

Data Types


1.4 sees the addition of Riak's first data type: PN-Counters. A PN-Counter is capable of being both incremented (P) and decremented (N). The full details are here. We're also fast at work on a CRDT Cookbook that will demonstrate this and future data types in Riak.

Riak Control

Riak Control now has an improved cluster management interface, and standalone node management interface, for staging and committing changes to the cluster, which mimics the CLI API.

New command: riak-debug

The command riak-debug is a shell script provided to aid in the automation of gathering information from Riak nodes for troubleshooting. Information gathered includes operating system command output, Riak command output, Riak configuration files, and Riak logs. See riak-debug -h and man riak-debug for more information on using the script and for tips on integrating its usage into your workflow.

Packaging / Runtime changes

Riak 1.4 took a major step forward in how it is packaged by changing over to using node_package for its packaging. This is the same tool used for RiakCS since its first release. This commonality will improve overall feature parity and stability of the packages themselves by cutting down on the number of places packaging bug fixes need to happen. See the 'node_package' section in the Issues section for all the bug fixes to packaging in this release.

Platforms Added / Removed

Support for Debian Wheezy and SmartOS 13.1 have been added to 1.4. As planned, support for 32bit packages has been dropped.

Major changes in packages and runtime
  • init.d scripts for Deb and RPM systems have been rewritten to comply with the standards of those distributions. In particular the init scripts now actually return nonzero exit codes on failure. This was a major issue we had that prevented tools from working seamlessly.
  • All start, stop, and status commands use return codes rather than reading stdout. This has been a major 'technical debt' we've had for a long time and it is about time the rest of it is finally fixed.
  • files are now created and removed on riak start/stop. This allows other tools to take advantage of .pid files without them needing knowledge about the riak script or nodetool.
  • Warnings added to riak attach and riak attach-direct to let users know about implications of q() and CTRL-C
  • The riak script now makes it more obvious which commands need to be run as the Riak user (or root user). Status commands like getpid or ping can be run by any user while daemon commands like start and stop will error in a more graceful if not run by the Riak user.

Issues / PR's Resolved

Known Issues

leveldb 1.3 to 1.4 conversion

The first execution of 1.4.0 leveldb using a 1.3.x or 1.2.x dataset will initiate an automatic conversion that could pause the startup of each node by 3 to 7 minutes. The leveldb data in "level #1" is being adjusted such that "level #1" can operate as an overlapped data level instead of as a sorted data level. The conversion is simply the reduction of the number of files in "level #1" to being less than eight via normal compaction of data from "level #1" into "level #2". This is a one time conversion.

Deprecation Warnings

Ubuntu 11.04 (Natty) EOL

Ubuntu 11.04 Natty Narwhal reached its end-of-life October 2012 and recently the public apt updates and security repos were removed. Due to this, Riak will no longer be built against 11.04 going forward. We will consider supporting the latest non-LTS release depending on the timing of the next major Riak release.

Ubuntu LTS releases still supported (10.04 and 12.04) are unaffected.