Questions tagged [rethinkdb]

RethinkDB is a scalable, open-source, distributed database system built to store JSON documents. It features a query language that has useful queries like table joins and group by, a highly parallelized architecture, and web tools for managing clusters.

RethinkDB is a scalable, open-source, distributed database system built to store JSON documents. It features a query language that has useful queries like table joins and group by, a highly parallelized architecture, and web tools for managing clusters.

Programming model:

  • JSON data model and immediate consistency
  • Distributed joins, subqueries, aggregation, atomic updates
  • Hadoop-style map/reduce
  • Secondary, compound, and arbitrarily computed indexes.

Administration:

  • Web and command-line adminstration tools
  • Tools to handle machine failure and network interrupts
  • Multi-datacenter replication and failover

Scalability:

  • Sharding and replication to multiple nodes
  • Automatically parallelized and distributed queries
  • Lock-free operation via MVCC concurrency

Useful Links:

Books:

1436 questions
6
votes
2 answers

Bulk Update in RethinkDB

I'm trying to update multiple documents in RethinkDB, based on some precalculated values in a Hash. i.e. Given a table stats with primary key slug with data like [{slug: 'foo', stats: {}}, {slug:'bar', stats:{}}] and given a Hash with values like…
svs
  • 2,425
  • 1
  • 14
  • 10
6
votes
2 answers

How to update embedded document?

How to update the text of second comment to "new content" { name: 'Me', comments: [{ "author": "Joe S.", "text": "I'm Thirsty" }, { "author": "Adder K.", "text": "old content" }] }
Alex Luya
  • 9,412
  • 15
  • 59
  • 91
5
votes
0 answers

Why is the changefeed sending JSON incompatible with the Python parser?

I set up a changefeed in Python using the following code: feed = r.table("table").changes().run(db) for change in feed: print(change) This crashes on the first update with a UnicodeDecodeError. It turns out RethinkDB appended the sequence…
niwax
  • 187
  • 5
5
votes
0 answers

How to do a Rethink bulk 'upsert' while only setting 'createdDT' on insert (first update)?

Is it possible to do an bulk upsert that behaves such that a particular field (e.g.: createdDT) is only set on first upsert, but not during later upserts of the same record? EDIT Got a crude version working which does a server-side executed loop,…
Geert-Jan
  • 18,623
  • 16
  • 75
  • 137
5
votes
1 answer

RethinkDB nested grouping

I have a RethinkDB table where documents look something like this: [ { "date": Mon Oct 05 2015 19:30:00 GMT+01:00, "category": 1, "name": "Alice" }, { "date": Wed Oct 07 2015 14:00:00 GMT+01:00, "category": 2, "name": "Ben" }, { "date": Mon…
5
votes
1 answer

RethinkDB connection "must be open" but never gets closed

I'm using RethinkDB together with hapi.js in Node.js. My main application passes an open connection to a hapi.js plugin. Using the connection inside the main-script works fine, but running something inside the plugin throws the following…
tobi
  • 1,924
  • 2
  • 20
  • 25
5
votes
2 answers

RethinkDB connect AttributeError

I'm trying to make a wrapper module for the RethinkDB API and I've come across an AttributeError when importing my class(called rethinkdb.py). I'm working in a virtual machine having a shared folder 'Github'. I do this in IPython console: import…
H. Steven
  • 51
  • 3
5
votes
2 answers

RethinkDB JavaScript Date Filter

I'm trying to query only things that are less than a day old... in JS this returns true; Why is rethink not returning true, so also not returning any results? r.db( "db" ).table("table") .filter( function (item) { var now = new…
Eric Hodonsky
  • 5,617
  • 4
  • 26
  • 36
5
votes
3 answers

How to live without transactions?

Most of the popular NoSQL databases (MongoDB, RethinkDB) do not support ACID transactions. They are very popular today within developers of different systems. The problem is: how to guarantee data consistency without transactions? I thought that…
gyzerok
  • 1,338
  • 2
  • 11
  • 26
5
votes
2 answers

How to shut down rethinkdb running on Mac OSX

Note: We love RethinkDB but our current project does not use it so we need to free up resources on our local machine ... We installed RethinkDB using homebrew: brew update && brew install rethinkdb And added the rethinkdb process to our plist as…
nelsonic
  • 31,111
  • 21
  • 89
  • 120
5
votes
2 answers

Rethinkdb atomic operations

Let's say I have a document { id: 1, fruits: [] } fruits here acts as a SET Now I want to atomically add a value to fruits array for document with primary key = 1 OR create such document if it does not exist(i.e. use SetInsert ReQL under…
let4be
  • 1,048
  • 11
  • 30
5
votes
1 answer

Merge an Array of Documents in RethinkDB

Let's say I have a table called bookshelf. I create a bookshelf document that has an array of IDs that references books in another table called books. I am trying to use getAll and merge to combine the documents in a query but I cannot seem to be…
mark
  • 1,953
  • 1
  • 24
  • 47
5
votes
3 answers

Create RethinkDB database from command line

I need to programatically create a RethinkDB database from the command line. However...I have no clue how to do this. I know that I can do this from the web UI or from a client driver, but isn't there a command that does this?
linkyndy
  • 17,038
  • 20
  • 114
  • 194
5
votes
2 answers

Printing the response of a RethinkDB query in a reasonable way

I am participating in the Yelp Dataset Challenge and I'm using RethinkDB to store the JSON documents for each of the different datasets. I have the following script: import rethinkdb as r import json, os RDB_HOST = os.environ.get('RDB_HOST') or…
Arthur Collé
  • 2,541
  • 5
  • 27
  • 39
5
votes
1 answer

How can I migrate my MongoDB to RethinkDB?

How can I migrate my MongoDB collections to RethinkDB tables? I'm not concerned about changing my old Mongo _id's to Rethink id's because they will be ignored in my implementation, and I'm not concerned about them cluttering my data.
bobjones
  • 503
  • 2
  • 15