Want to improve as a dev?

I send a short email every workday about Spring topics, API development and improving as a dev. The current series is about building a Kanban API with Spring.

Let's Build an API Together - Part 21

25.01.2018 by Jens in API Series | APIs | Newsletter

Yesterday we updated the endpoints in the API and today I was going to implement it in RAML and let the generator we use to create the Spring MVC code. However, I had another problem with the generator again as it wasn’t generating the createTask method anymore because I put the boardId in the path. Besides that, the code started to get messy with no added benefit anymore.

I tried a workaround and added an endpoint /tasks with a POST for creating a new task. It did generate the createTask Method again. Nonetheless, it was six controllers already for our simple application. It started to become messy and even experimenting with the generators naming scheme didn’t make it any better. Which made me reconsider the generator approach.

The generator did lose.

I still think it can be beneficial for a project with different constraint. So it is out, and I will be implementing the Controller by hand.

Did you follow along with the generator too? How did it go?


comments powered by Disqus