Light Codegen
Why this generator
In the earlier days of light-platform, we only had a Restful framework, and we were leveraging swagger-codegen to generate our projects from Swagger 2.0 specifications. However, there are several issues that we could not resolve.
- swagger-codegen does not support Java 8 and Java 11, so we have to fork it and customize it.
- swagger-codegen does not give your flexibility to customize the project. For example, if Oracle Database is supported.
- swagger-codegen can only support the swagger specification, and we later added GraphQL and Hybrid frameworks
- swagger-codegen is very slow, and it takes several seconds to generate a project. Light-codegen needs several milli-seconds so that we can support code generation from the web.
- swagger-codegen does not support external extension, which means you have to add your generator to the codebase to work.
Given all the drawbacks, we have decided to build our generator. light-codegen is built with Java 8/11 and uses the rocker template engine that compiles the templates to Java class to speed it up. It also uses our IoC service module to enable new generators to be added without touch the source code.
- Specification Best Practices
- Download or build light-codegen
- Swagger 2.0 Generator
- OpenAPI 3.0 Generator
- OpenAPI 3.0 Kotlin Generator
- OpenAPI 3.0 Lambda Generator
- GraphQL Generator
- Hybrid Server Generator
- Hybrid Service Generator
- Eventuate Generator
- DevOps Integration
- Customization
- Rocker Hot Reloading
- Different Dockerfile
- Tutorials