REST API/Web Service is very commmon in any Java/J2EE application. Its an era of microservices. Almost every functionality is being implemented as microservices. We write lot of code to build a REST API/ web services.
Now entire end to end web service code (controller, service, DAO, bean, helper classes and property & Spring bean configuration files) can be generated using this tool. Generated code works with Spring Framework. Java 13 is required to run the generated code.
It generates end to end REST API code from JSON. JSON string is the input entire service code and configuration files are the output.As of now it generates create, update, get and list API/services. It can also gednerate onluy controller and bean classes if user does not want the service and dao classes.Generated code fit with Spring boot and Spring MVC. Generated code can be run directly and invoked from any REST client application.
Click
Here To Watch A Demo On It(https://youtu.be/aoDRH2Cvc4Y).
Generated code can be used in any spring boot or spring MVC project.
Please use the following files for in respective project.
Files Required For Spring Boot
Project: |
Files Required For Spring MVC Project: |
- Read ReamMe_Springboot.txt file.
- Take application.properties
- Take all dependencies to your project pom.xml from
pom_springboot.xml
- Take all DAO properties files
- Take all Java classes
- Take sql files to create the tables in the database
|
- Read ReamMe_Mvc.txt file.
- web.xml and spring-dispatcher.xml to eclipse WEB-INF folder
- Take all dependencies to your project pom.xml from
pom_mvc.xml
- Take all configuration xml files
- Take all DAO properties files
- Take all Java classes
- Take sql files to create the tables in the database
|
How It Works:
It does end to end code generation for 4 types of API/Service. It works
based on the Http request JSON string and some other user inputs like
Api name, base package, module package, sub package name. It parse the
input JSON string. Derive all the entity and its attribute from the JSON
string. Augument audit and lockid column on each entity. Generate CURD
operation code using which uses Spring JDBC Template. It also geneare
bean, controller and service classes. Genearted code is works with
Spring Framework. It hadles following 4 types of APIs / Service:
- Create API/Service
- Modify API/Service
- Get API/Service
- List API/Service