Martin is an enthusiastic software engineer building and operating microservices in the JVM stack using Kotlin. Currently working for Albert Heijn in the role of DevOps engineer.
Looks good, I would recommend updating Spring Boot to 2.1.0. Besides that, don't use 'Test' in such tutorials. Keep them realistic and use something like "getAll()" or something.
Why don't you use ResponseEntity<>?
And another good improvement would be to explain how a request flows from the browser of the user through the (Rest)Controller to the Service and into the Repository if needed.
Will use proper naming conventions in the next one :D
I could have used response entity as well. Maybe will use that in the next article.
Planning to write one more article for the flow from controller to service to repository. That's the reason I did not include it here. Wanted to separate them out since having them in one article makes the article long and readers may feel its too much information in one article.
Martin is an enthusiastic software engineer building and operating microservices in the JVM stack using Kotlin. Currently working for Albert Heijn in the role of DevOps engineer.
Looks good, I would recommend updating Spring Boot to 2.1.0. Besides that, don't use 'Test' in such tutorials. Keep them realistic and use something like "getAll()" or something.
Why don't you use ResponseEntity<>?
And another good improvement would be to explain how a request flows from the browser of the user through the (Rest)Controller to the Service and into the Repository if needed.
Thank you for the feedback :)
Will use proper naming conventions in the next one :D
I could have used response entity as well. Maybe will use that in the next article.
Planning to write one more article for the flow from controller to service to repository. That's the reason I did not include it here. Wanted to separate them out since having them in one article makes the article long and readers may feel its too much information in one article.
I prefer to use ResponseEntity because it is Spring itself as the tutorial focuses on Spring.
Good luck!