-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Refactor SQL storage layer using ORM #1864
Comments
It'd be nice to get my middleware changes in first :-) (See #1841.) Otherwise, there's going to be quite a lot to change in that patch. |
I think that's a great idea. I'm actually looking at it for quite some time now, but always lacked the time to implement it. I think ent is a great choice, although I don't have a lot of experience with it other than a few simple applications. It's probably the first decent ORM for Go, at least I have terrible experience with basically all other Go ORMs. @al45tair I would assume that this storage driver would actually be a new one, not a rewrite of the existing ones. Do you think that would still affect your PR negatively? |
@sagikazarmark It's not so much that it'll affect it negatively; rather, if this is done first, it'll mean I've got to work out how to extend the new storage driver as well. It's OK, as long as it's clear enough what to do :-) And you're right, if it's a new storage driver, it won't have too much of a negative impact. |
Maybe we could also generate the grpc API code from the ent schema as well /cc @sagikazarmark |
Not a huge fan of the idea. I don't really like binding the storage layer to the API or the transport. |
What's the state of this @nabokihms ? I believe most of the implementation is done, right? |
The only step left is to provide and test the migration. I haven't had time to work on this one. |
Is your feature request related to a problem? Please describe.
Refactoring of SQL level was previously suggested here -
#1831 (comment)
Describe the solution you'd like to see
Back in the days, there weren't fully statically typed convenient ORMs for golang. Now we have such a tool - ent from Facebook. The main advantages are:
Describe alternatives you've considered
Leave SQL storage layer as is.
Additional context
I wonder, is it ok to start working on this one? Ent is lovely, we use it for a couple of projects. @sagikazarmark Have you already started working on this?
Roadmap:
The text was updated successfully, but these errors were encountered: