For the simplest example, I can say that I'm pushing the list of my favorite dishes to everyone who signs up.
r.table('food').changes().run(conn, (err, cursor) => { cursor.each((err, change) => { io.emit('NEW_FAVORITE', change); }) })
Now let me say that I have 500 people who are actively watching me add my favorite products. What would be more effective, 500 people subscribed to 500 changes, each of which had include_initial, or 500 initial requests that were redirected to these people, and then 500 people watched 1 replacement? Bonus points to explain the reasons!
include_initial
, , 500 , , - , , 500 .
RethinkDB , , 500 . , , changefeeds , , changefeed 500 , .
include_initial , . , changefeed, , . include_initial .
( - , 500 A, RethinkDB B. , changefeed , B , , 500 . A B A, . - node A 500 node, RethinkDB node.)
Source: https://habr.com/ru/post/1616984/More articles:Customize pyuic resource import statement? - pyqtApache Cordova: Failed to load the resource: the server responded with a status of 404 (not found) - androidPassing a function to a template object during template initialization in C ++ - c ++How do I map a type from the CLR namespace in XAML from an assembly other than the one where it was declared? - c #Using latex packages in markup MATLAB publish - markupHow to get install.wim from a Windows 10 pro installation file - windowsDownloadManager slowly loading on Android 6 - androidsorting by length with stability in c - cИнициализация Crashlytics и ответов Fabric.io - iosКак удалить элемент в Groovy с помощью XmlSlurper? - xmlAll Articles