Java's not a terrible option. But it's rarely the best option, especially for Right Now, though it may become the best option later when enough competing concerns have cropped up.
Example: http://spring.io/guides/gs/accessing-data-rest/.
Here you don't even have to write code for controllers or db connections for basic CRUD HATEOAS REST service. Spring takes care of it. The model still needs getters and setters, but you can avoid this with Lombok
Java development today is different.
Spring Boot may be a bit nicer than the most out of the way method I used years ago (now at https://github.com/stoicflame/enunciate/wiki) which did use Spring for some things, but it's really still far away from what dynamic languages and their ecosystems offer.