top of page
Writer's pictureShenthamarai N

An Error that surprised !


This is a REST API developed in Java-SpringBoot.

I had to take over my friends work and i was getting this error.

org.springframework.http.converter.HttpMessageNotWritableException: No converter for [class com.numpyninja.dietician.dto.JwtResponseDTO] with preset Content-Type 'null'


Everything seemed Ok.

When I had to dig into JwtResponseDTO, realized that getter, setters, constructors were missing.

We use lombok to generate these. And my friend missed to add lombok annotations.

Added those and error was gone :-)




missing to add constructor, getter , setter is a common mistake which we should try to avoid.

Happy coding!.

Thank you, leave your comments if any.



208 views

Recent Posts

See All
bottom of page