Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/parsonsmatt/write-buffer
If single writes are slowing you down, who you gonna call? WRITE BUFFER!
https://github.com/parsonsmatt/write-buffer
Last synced: 29 days ago
JSON representation
If single writes are slowing you down, who you gonna call? WRITE BUFFER!
- Host: GitHub
- URL: https://github.com/parsonsmatt/write-buffer
- Owner: parsonsmatt
- Created: 2017-02-11T22:17:24.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-05-27T00:04:05.000Z (over 7 years ago)
- Last Synced: 2024-09-17T09:24:35.442Z (about 2 months ago)
- Language: Haskell
- Size: 14.6 KB
- Stars: 2
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# `write-buffer`
A stupid set of libraries for taking advantage of the speedup from bulk saving data.
Suppose you're saving, like, thousands of rows to a database.
If you're saving each row one at a time, then that is kind of terribly slow.
You can get big speedups by saving your rows in bulk.However, that's kinda annoying to do. So this library makes it easier.
The `write-buffer-example` folder has a dumb example of this.
We setup a web server to listen for POST requests of a record we want to save, and we collect up to 1000 of these requests in a queue.
Every second, we save all of the stuff in the queue using a bulk insert.