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:

1417 questions
45
votes
3 answers

How to remove a key from a RethinkDB document?

I'm trying to remove a key from a RethinkDB document. My approaches (which didn't work): r.db('db').table('user').replace(function(row){delete row["key"]; return row}) Other approach: r.db('db').table('user').update({key: null}) This one just…
Robert Zaremba
  • 6,780
  • 6
  • 40
  • 71
28
votes
4 answers

Method to replicate sqlite database across multiple servers

I'm developing an application that works distributed, and I have a SQLite database that must be shared between distributed servers. If I'm in serverA, and change sqlite row, this change must be in the other servers instantly, but if a server were…
24
votes
4 answers

In RethinkDB, what is the easiest way to check if a database or a table exists?

One way I know I can do it is by listing throughdbList() and tableList() and then looking for what I want in the results. Is there an easier way? EDIT My goal is to create a table in case it doesn't exist.
André Pena
  • 48,518
  • 37
  • 172
  • 216
24
votes
4 answers

Comparing MongoDB and RethinkDB Bulk Insert Performance

This is my official first question here; I welcome any/all criticism of my post so that I can learn how to be a better SO citizen. I am vetting non-relational DBMS for storing potentially large email opt-out lists, leaning toward either MongoDB or…
njyunis
  • 251
  • 1
  • 3
  • 9
19
votes
1 answer

socket.io vs RethinkDB changefeed

Currently I'm using socket.io without RethinkDB like this: Clients emit events to socket.io, which receives the events, emits to various other clients, and saves to the db for persistence. A new client connecting will get existing data from the db…
user3096484
  • 193
  • 1
  • 4
19
votes
1 answer

How to append an element to an array in rethinkdb

I have this object: { "id": "eb533cd0-fef1-48bf-9fb8-b66261c9171b" , "errors": [ "error1" , "error2" ] } I simply want to append a new error to errors array. I…
Sincere
  • 477
  • 5
  • 17
18
votes
1 answer

how to use RethinkDB with Phoenixframework?

Having just arrived to Elixir/Phoenix I want to use RethinkDB instead of PostgreSQL but I only find documentation/examples on PostgreSQL (which seems to be the default/official database). There is a very good package from Hamiltop (Rethinkdb-elixir)…
Paulo Janeiro
  • 2,891
  • 2
  • 23
  • 42
17
votes
2 answers

How to create unique items in RethinkDB

How to create unique items in RethinkDB? In MongoDb I used ensureIndex for this, eg: userCollection.ensureIndex({email:1},{unique:true},function(err, indexName){
daslicht
  • 747
  • 9
  • 24
16
votes
6 answers

RethinkDB - Updating nested array

I have a survey table that looks like so: { id: Id, date: Date, clients: [{ client_id: Id, contacts: [{ contact_id: Id, score: Number, feedback: String, email: String }] }] } I need to updated the score…
Jacob Turner
  • 1,683
  • 1
  • 9
  • 15
13
votes
3 answers

how do non-ACID RethinkDB or MongoDB maintain secondary indexes for non-equal queries

This is more of 'inner workings' undestanding question: How do noSQL databases that do not support *A*CID (meaning that they cannot update/insert and then rollback data for more than one object in a single transaction) -- update the secondary…
V P
  • 745
  • 9
  • 24
12
votes
1 answer

RethinkDB changefeeds performance: architectural advice?

I am building an application with RethinkDB and I'm about to switch to using changefeeds. But I'm facing an architectural choice and I'd like to get some advice. My application currently loads all user data from several tables on user login (sending…
Jan Rychter
  • 572
  • 4
  • 13
12
votes
1 answer

How to force binding re-evaluate or re-rendering in Aurelia

I am starting with a simple TODO app with Aurelia, RethinkDB & Socket.IO. I seem to have problem with re-rendering or re-evaluating an object that is changed through Socket.IO. So basically, everything works good on the first browser but doesn't get…
ghiscoding
  • 8,803
  • 5
  • 61
  • 99
12
votes
4 answers

How to make a rethinkdb atomic update if document exists, insert otherwise?

How to make a rethinkdb atomic update if document exists, insert otherwise? I want to do something like: var tab = r.db('agflow').table('test'); r.expr([{id: 1, n: 0, x: 11}, {id: 2, n: 0, x: 12}]).forEach(function(row){ var _id = row('id'); …
Robert Zaremba
  • 6,780
  • 6
  • 40
  • 71
11
votes
1 answer

How suitable is opting for RethinkDB instead of traditional SQL for a JSON API?

I am building the back-end for my web app; it would act as an API for the front-end and it will be written in Python (Flask, to be precise). After taking some decisions regarding design and implementation, I got to the database part. And I started…
linkyndy
  • 14,398
  • 14
  • 96
  • 180
10
votes
1 answer

How do I use a Ratchet\Server\IoServer object after run executed?

I want to run a function that iterates through a generator class. The generator functions would run as long as the Ratchet connection is alive. All I need to do is to make this happen after the run method is executed: use…
112233
  • 2,206
  • 2
  • 23
  • 71
1
2 3
94 95