Java EE 및 JBoss WildFly로 응용 프로그램을 만들려고합니다. 필자는 인증을 처리하기 위해 Spring Security를 통합했으며 맞춤형 사용자 상세 서비스를 사용하여 데이터베이스의 사용자 세부 사항을 조회합니다.Jboss Wildfly의 ClassLoading 문제
내 EAO는 EJB 모듈로 작성되었으며 웹 모듈의 userDeailService에서 액세스합니다.
하지만 로그인 할 때 다음 오류가 표시됩니다. 내가 그것을 EJB 모듈 클래스 로더와 웹 모듈 클래스 로더를 모두 같다 읽은 기사에서
java.lang.LinkageError: loader constraint violation: when resolving interface method "com.company.eao.UserEAO.findByUserName(Ljava/lang/String;)Lorg/springframework/security/core/userdetails/UserDetails;" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, com/company/security/UserDetailServiceWrapper, and the class loader (instance of org/jboss/modules/ModuleClassLoader) for the method's defining class, com/company/eao/UserEAO, have different Class objects for the type org/springframework/security/core/userdetails/UserDetails used in the signature
오류가 발생한 UserDetail 클래스 암탉을로드합니다.
WildFly에서 하나의 클래스 로더를 사용하도록 지정하거나이 문제를 해결하는 방법은 무엇입니까?
미리 감사드립니다.