Hi Guys, Welcome to Simple Programming
This is going to be a two part video series where we will see how to configure swagger UI and then we will see how to generate client class(using swagger codegen maven plugin) in spring boot dynamically using a json/yaml file
###Update###
There is an issue in the fetch/all json generation
please use this to fix the same
its not deserialized when the response is List of Employees
we can fix it in two ways
1. from the previous swagger ui example - update the @APIResponse like below
@ApiResponse(code = 200, message = "SUCCESS", response = Employee.class, responseContainer = "List")
and generate the json file and use this json for codegen into resources folder
(or)
2. directly edit the .json file in the resource folder like below (ideally this gets generated from the above)
"summary": "Fetch All Employees",
"operationId": "fetchAllEmployeesUsingGET",
"produces": [
"*/*"
],
"responses": {
"200": {
"description": "SUCCESS",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/Employee"
}
}
},
#swagger #springboot #codegen #swaggerui
Auf dieser Seite können Sie das Online-Video Spring Boot - with Swagger UI | Simple Programming mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Simple Programming 08 Juni 2020 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 37,672 Mal angesehen und es wurde von 330 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!