Principled Java code generation
See original GitHub issueOverview
The core underlying concept of guardrail seems doable in Java; one challenge would be maintaining the flexibility of the various typeclasses without global registries. Explicit value passing and typechecking responses.
Details
The biggest advantage I see for providing this would be to permit an easier migration path from existing Java services into Scala, by first following best practices isolating the business logic from the web framework and using generated models+encoders/decoders for all communication, then migrating the business logic piecemeal into Scala by using scala-java8-compat
to adapt down to toCompletableFuture
.
Progress
- Encode existing Free algebras with knowledge of which language they are targeting
- Remove all references to scala.meta from everything but the
ScalaLanguage
specification class and the generators - Add a
language
parameter to the argument parser/context - Add a java generators for akka-http clients and servers, using javaparser
- Add a Jackson generator, wire it in to the java-akka stuff according to the docs
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:7 (7 by maintainers)
Top Results From Across the Web
5 Principles of Code Generation from @KathleenDollard
Code should match or exceed human quality: While speed is an awesome goal, quality matters more. All code generation strategies should match or ......
Read more >A Guide to Code Generation
With code generation you get always the code you expect. The generated code is designed according to the same principles, the naming rule...
Read more >Design Principles for Code Generators
7 Design Principles of the OpenModelica Code Generator. 41. 7.1 Introduction . ... Java and C++ backends can be use for code generation....
Read more >Programming Principles | Java Design Patterns
There are certain universal laws and principles in software development that guide architects, programmers, and anyone needing to design software.
Read more >Solid Design Principles In Java Development
A solid design approach is a set of five principles in object-oriented programming that are designed to eliminate code rot and improve value ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Just as an update here, we have full Java support in the core now, and generators for Dropwizard servers and AsyncHttpClient clients. At this point, adding Java akka-http servers and clients is just a matter of deciding on the generated output and writing generators.
Heh, I guess this can be closed.