-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
proposal: gen the DB #157
Comments
something similar to https://github.com/infobloxopen/protoc-gen-gorm but for sqlboiler instead of gorm? |
It would be nice for a grapi db plugin. This shouldn't be added in the grapi core to avoid bloats. |
@fi0 yes exactly. github.com/volatiletech/sqlboiler is much faster since it does not use reflection. @l4u makes sense. SQL boiler is a db schema first generator. I think we can gen the schema from the protobufs but not sure right now. any ideas ? |
THis is a really great project. I have been working on something similar, but i think i will swap to yours.
I was wondering if you think using sqlboiler ( github.com/volatiletech/sqlboiler ) to gen the DB makes sense ?
I noticed that you gen the Standard CRUD Methods and so it seems a pretty good idea to then do the same for the DB.
There is always a imbalance, for want of a better word, between what your DB model looks like and what your GRPC model looks like. Hope you know what i mean ?
SO for now, if you think this is a good idea, then the developer has to write code in the middle to get the data from the DB that he / she needs to fulfil the Protobuf API.
In the past i wrote a very large code generator that is quite a bit like this.
In order to help with the "imbalance" we created a mapping between the protobuf and the db tables, to help do more codegen. But i think thats much later..
anyways, eager to hear what your think.
The text was updated successfully, but these errors were encountered: