Releases: rethinkdb/rethinkdb-go
v0.7.1
v0.7.0 - 2015-04-14
This release includes support for RethinkDB 2.0 and connecting to clusters. To connect to a cluster you should use the new Addresses
field in ConnectOpts
, for example:
session, err := r.Connect(r.ConnectOpts{
Addresses: []string{"localhost:28015", "localhost:28016"},
})
if err != nil {
log.Fatalln(err.Error())
}
Also added was the ability to read from a cursor using a channel, this is especially useful when using changefeeds. For more information see this gist
cursor, err := r.Table("items").Changes()
ch := make(chan map[string]interface{})
cursor.Listen(ch)
For more details checkout the README and godoc. As always if you have any further questions send me a message on Gitter.
- Added the ability to connect to multiple nodes, queries are then distributed between these nodes. If a node stops responding then queries stop being sent to this node.
- Added the
DiscoverHosts
optional argument toConnectOpts
, when this value istrue
the driver will listen for new nodes added to the cluster. - Added the
Addresses
optional argument toConnectOpts
, this allows the driver to connect to multiple nodes in a cluster. - Added the
IncludeStates
optional argument toChanges
. - Added
MinVal
andMaxVal
which represent the smallest and largest possible values. - Added the
Listen
cursor helper function which publishes database results to a channel. - Added support for optional arguments for the
Wait
function. - Added the
Type
function to theCursor
, by default this value will be "Cursor" unless using a changefeed. - Changed the
IndexesOf
function toOffsetsOf
. - Changed driver to use the v0.4 protocol (used to use v0.3).
- Fixed geometry tests not properly checking the expected results.
- Fixed bug causing nil pointer panics when using an
Unmarshaler
- Fixed dropped millisecond precision if given value is too old
v0.6.3 - 2015-03-04
v0.6.0 - 1 Feb 2015
There are some major changes to the driver with this release that are not related to the RethinkDB v1.16 release. Please have a read through them:
- Improvements to result decoding by caching reflection calls.
- Finished implementing the
Marshaler
/Unmarshaler
interfaces - Connection pool overhauled. There were a couple of issues with connections in the previous releases so this release replaces the
fatih/pool
package with a connection pool based on thedatabase/sql
connection pool. - Another change is the removal of the prefetching mechanism as the connection+cursor logic was becoming quite complex and causing bugs, hopefully this will be added back in the near future but for now I am focusing my efforts on ensuring the driver is as stable as possible #130 #137
- Due to the above change the API for connecting has changed slightly (The API is now closer to the
database/sql
API.ConnectOpts
changes:MaxActive
renamed toMaxOpen
IdleTimeout
renamed toTimeout
Cursor
s are now only closed automatically when calling eitherAll
orOne
Exec
now takesExecOpts
instead ofRunOpts
. The only difference is thatExec
has theNoReply
field
With that out the way here are the v1.16 changes:
- Added
Range
which generates all numbers from a given range - Added an optional squash argument to the changes command, which lets the server combine multiple changes to the same document (defaults to true)
- Added new admin functions (
Config
,Rebalance
,Reconfigure
,Status
,Wait
) - Added support for
SUCCESS_ATOM_FEED
- Added
MinIndex
+MaxInde
x functions - Added
ToJSON
function - Updated
WriteResponse
type
Since this release has a lot of changes and although I have tested these changes sometimes things fall through the gaps. If you discover any bugs please let me know and I will try to fix them as soon as possible.
v0.5.0 - 6 Oct 2014
- Added geospatial terms (
Circle
,Distance
,Fill
,Geojson
,ToGeojson
,GetIntersecting
,GetNearest
,Includes
,Intersects
,Line
,Point
,Polygon
,PolygonSub
) - Added
UUID
term for generating unique IDs - Added
AtIndex
term, combinesNth
andGetField
- Added the
Geometry
type, see the types package - Updated the
BatchConf
field inRunOpts
, now uses theBatchOpts
type
Internal Changes
- Fixed encoding performance issues, greatly improves writes/second
- Updated
Next
to zero the destination value every time it is called.
v0.4.0
API changes
- Updated the driver to support RethinkDB v1.14 (#116)
- Added the Binary data type
- Added the Binary command which takes a
[]byte
,io.Reader
orbytes.Buffer{}
as an argument. - Added the
BinaryFormat
optional argument toRunOpts
- Added the
GroupFormat
optional argument toRunOpts
- Added the
ArrayLimit
optional argument toRunOpts
- Renamed the
ReturnVals
optional argument toReturnChanges
- Renamed the
Upsert
optional argument toConflict
- Added the
IndexRename
command - Updated
Distinct
to now take theIndex
optional argument (usingDistinctOpts
)
Internal Changes
- Updated to use the new JSON protocol
- Switched the connection pool code to use github.com/fatih/pool
- Added some benchmarks
v0.2 (RethinkDB v.1.12)
- Changed
Connect
to useConnectOpts
instead ofmap[string]interface{}
- Migrated to new
Group
/Ungroup
functions, these replaceGroupedMapReduce
andGroupBy
- Added new aggregators
- Removed base parameter for
Reduce
- Added
Object
function - Added
Upcase
,Downcase
andSplit
string functions - Added
GROUPED_DATA
pseudotype - Fixed query printing