3 ms·
Why NoSQL?
by thecodemonkey 6y ago
Why NoSQL?
- pier25 6y agoBecause generally speaking SQL databases don't work well with serverless and are a pain to distribute geographically.
- gregjor 6y agoHuh. A lot of us use serverless relational databases now, if by “serverless” you mean “runs on a remote server someone else manages.” AWS RDS, for example. A pain to distribute geographically? What do you think big enterprises and banks use? Oracle or Mongo? If by “a pain” you mean “not free” then you’re right. Depends on how valuable your data is and how much you care about integrity.
- pier25 6y agoNo, by serverless I mean cloud functions. Also I’m not a big enterprise nor a bank.
- gregjor 6y agoDistributing geographically generally comes up in large-scale systems. My point is that relational databases already support that. I know what cloud functions are. How do they not work with relational databases, any more than they don’t work with some NoSQL tool? Unless your cloud functions embed the database they’re using a remote service, right?
- pier25 6y agoBecause on peak traffic you could have thousands of cloud functions running, each with its own connection to the database. Typically SQL databases are much more strict on the number of concurrent connections as these consume more memory than on NoSql databases. Edit: IIRC I read that each connection to Postgres consumes 10MB or RAM.
- amitlan 6y agoPostgres core hackers are working to ease the limit on max allowable concurrent connections, for example: https://www.postgresql.org/message-id/flat/20200301083601.ews6hz5dduc3w2se%40alap3.anarazel.de https://www.postgresql.org/message-id/flat/20200301083601.ew... Maybe the proposal above by itself isn't enough, but it's going to solve some of the many problems that put a restriction on max allowable connections in the first place. For example, I am not sure if there is anything in there to reduce the baseline per connection memory consumption, but maybe that will come up as the next problem to solve and will hopefully be solved sooner than later.
- 72deluxe 6y agoCould someone educate me on what you mean by "cloud functions" ? I do not understand the concept of "serverless". To me, data has "live" somewhere. When one computer is storing that and serving it, it is by definition a server. Is there something I've missed??