Showing posts with label errors in java. Show all posts
Showing posts with label errors in java. Show all posts

October 21, 2020

java.lang.ClassNotFoundException: javax.xml.bind.DatatypeConverter [ Solution ]

java.lang.NoClassDefFoundError: javax/xml/bind/DatatypeConverter
at io.jsonwebtoken.impl.Base64Codec.decode(Base64Codec.java:26) ~[jjwt-0.9.1.jar:0.9.1]
at io.jsonwebtoken.impl.DefaultJwtBuilder.signWith(DefaultJwtBuilder.java:99) ~[jjwt-0.9.1.jar:0.9.1]
at com.cfed.config.JwtTokenUtil.doGenerateToken(JwtTokenUtil.java:71) ~[classes/:na]
at com.cfed.config.JwtTokenUtil.generateToken(JwtTokenUtil.java:59) ~[classes/:na]
at com.cfed.controller.JWTAuthenticationController.createAuthenticationToken(JWTAuthenticationController.java:43) ~[classes/:na]

Solution


Change your execution environment version to lower than java 9

Java Removed JAXB API from higher version than java 9.

November 03, 2012

Exceptions in java

Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener



org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mailService' defined in ServletContext resource [/WEB-INF/landview-mail.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'mailSender' of bean class [com.mapview.landview.service.impl.MailServiceImpl]: Bean property 'mailSender' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?



solution : you have forget to create getter and setter method in java class for id specified in xml as bean.



http://javabelazy.blogspot.in/

Facebook comments