You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Another Serverpod user here...) The query DSL is hardcoded for generating Postgres-style SQL, and it would take a lot of work to make it work for an entirely different database type like MongoDB. however, the SerializableModel subclasses are very easy to convert to and from JSON, so you could use the MongoDB API directly with those classes. It would be a very simple fit. Then you could just use the MongoDB API directly.
You would need to change your Dockerfile to start a MongoDB instance. And all the Google Cloud Terraform scripts assume that you'll be using Serverpod with Postgres (Cloud SQL in Google terms), so if you wanted to run on Google Cloud, you'd have to do a fair bit of work to modify these scripts too. (Google Cloud doesn't have a MongoDB service, that I have seen, so you'd have to just run your own instance on Compute Engine.)
Activity
lukehutch commentedon Jul 28, 2024
(Another Serverpod user here...) The query DSL is hardcoded for generating Postgres-style SQL, and it would take a lot of work to make it work for an entirely different database type like MongoDB. however, the
SerializableModelsubclasses are very easy to convert to and from JSON, so you could use the MongoDB API directly with those classes. It would be a very simple fit. Then you could just use the MongoDB API directly.You would need to change your Dockerfile to start a MongoDB instance. And all the Google Cloud Terraform scripts assume that you'll be using Serverpod with Postgres (Cloud SQL in Google terms), so if you wanted to run on Google Cloud, you'd have to do a fair bit of work to modify these scripts too. (Google Cloud doesn't have a MongoDB service, that I have seen, so you'd have to just run your own instance on Compute Engine.)
SandPod commentedon Aug 5, 2024
That is a great suggestion for a workaround @lukehutch!
I'm closing this as a duplication of #14 but will post your suggested workaround in that issue as well.