-
Notifications
You must be signed in to change notification settings - Fork 18
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
Generic derivation of schemas #48
Comments
@vil1, Had a discussion with @GrafBlutwurst about the gist code you shared in the issue for understanding. I will modify this gist code to align with latest schema encoding and raise a PR to take it forward. |
@sasiharan that's great news! FTR, the mentioned gist is here Please note that it might be easier to first work on #47 and then use that work to solve this issue (that is, the stuff around the Also, I'd prefer we use scalaz-deriving for this instead of shapeless for our generic derivation mechanisms. I'm not yet knowledgeable with it to be able to give you any guidance, but I intend to learn more about it soon (and I can also bring in people who know it well). |
Don't worry too much about #44 though, it might take a while to be solved. And if it ever has an impact on your work, I'll take care of it as much as possible. |
Building upon #47, it seems rather obvious that we should be able to automatically derive the schema of any ADT at compile time (as a matter of fact, this gist achieves just that, using shapeless).
Like to #47, this should be provided in the
generic
(sbt) module, with no impact on the existing API for constructing schemas.Also, if #34 gets merged before this issue is solved, words must be added in the documentations to stress out the fact that such fully automatic derivation should be used with caution, for it somehow defeats the purpose of having schemas as runtime values (in scenarios where schema evolution is a needed feature, it OK to fully derive schemas at compile time, as long as the application stores the derived schema somewhere at runtime).
The text was updated successfully, but these errors were encountered: