Sunday, March 4, 2018

java.lang.ClassCastException: $ProxyXX cannot be cast to xxx

When a system using EJB encountered a ClassCastException: $ProxyXX...
this could be due to same mappedName in the same system.

@Stateless(name = "MyBusinessObject", mappedName = "MyBusinessObject")

Therefore, when the system encountered the above exception,
the developer needs to check whether the class throwing the above exception mappedName also used in other class.


Done!!

LinkWithin

Related Posts Plugin for WordPress, Blogger...