2016-12-16 1 views
0

간단한 질문입니다. 오래된 jboss 4.2.x GA grails 응용 프로그램 (2.3.10)을 wildfly 10으로 옮기고 있습니다. 나는 내 ejb를 호출하는 데 열중하고 있습니다. 예를 들어grails + EJB3 = EJB 수신기를 처리 할 수 ​​없습니다.

resources.groovy 파일의 간단한 구성 :

jndiBinBaseTemplate(JndiTemplate) { 

    environment = [ 
      "java.naming.factory.initial": "org.jboss.naming.remote.client.InitialContextFactory", 
      "java.naming.provider.url": "http-remoting://127.0.0.1:8080".toString(), 
      "java.naming.security.principal":"test", 
      "java.naming.security.credentials":"test", 
      "jboss.naming.client.ejb.context":true, 
      "java.naming.factory.url.pkgs":"org.jboss.ejb.client.naming" 
    ] 
} 

binbaseStatus(SimpleRemoteStatelessSessionProxyFactoryBean) { 
    businessInterface = "edu.ucdavis.genomics.metabolomics.binbase.bci.server.jmx.StatusJMXFacade" 
    jndiName = "bci/bci-core/StatusJMXFacadeBean!edu.ucdavis.genomics.metabolomics.binbase.bci.server.jmx.StatusJMXFacade" 
    jndiTemplate = ref(jndiBinBaseTemplate) 
} 

항상 다음과 같은 예외가 발생합니다

EJBCLIENT000025: No EJB receiver available for handling [appName:bci, moduleName:bci-core, distinctName:] combination for invocation context [email protected] Stacktrace follows: 
java.lang.IllegalStateException: EJBCLIENT000025: No EJB receiver available for handling [appName:bci, moduleName:bci-core, distinctName:] combination for invocation context [email protected] 
at org.jboss.ejb.client.EJBClientContext.requireEJBReceiver(EJBClientContext.java:798) 
at org.jboss.ejb.client.ReceiverInterceptor.handleInvocation(ReceiverInterceptor.java:128) 
at org.jboss.ejb.client.EJBClientInvocationContext.sendRequest(EJBClientInvocationContext.java:186) 
at org.jboss.ejb.client.EJBInvocationHandler.sendRequestWithPossibleRetries(EJBInvocationHandler.java:255) 
at org.jboss.ejb.client.EJBInvocationHandler.doInvoke(EJBInvocationHandler.java:200) 
at org.jboss.ejb.client.EJBInvocationHandler.doInvoke(EJBInvocationHandler.java:183) 
at org.jboss.ejb.client.EJBInvocationHandler.invoke(EJBInvocationHandler.java:146) 
at minix.BinBaseClusterController$_closure4.doCall(BinBaseClusterController.groovy:29) 
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:565) 
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1360) 
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1331) 
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1331) 
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1331) 
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:477) 
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119) 
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:539) 
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:227) 
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1031) 
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:406) 
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:186) 
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:965) 
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117) 
at org.eclipse.jetty.server.Dispatcher.forward(Dispatcher.java:288) 

사람이 어떻게이없는 어떤 생각을 가지고 있습니까? 원격 ejb의 작업에 대한 나의 arquillian 테스트가 그렇지 않으면 괜찮은 것 같아요.

답변

0

어떤 이유로 든 설명 할 수 없습니다. 이것은 jndi 구성 옵션을 모두 사용하여 수정되었습니다.

ressrouces.groovy :

binbaseProperties (org.springframework.beans.factory.config.MapFactoryBean) { sourceMap =

  "java.naming.factory.initial": "org.jboss.naming.remote.client.InitialContextFactory", 
      "java.naming.provider.url": "http-remoting://${BinBaseConfigReader.getServer()}:8080", 
      "${Context.SECURITY_PRINCIPAL}":"binbase", 
      "${Context.SECURITY_CREDENTIALS}":"binbase", 
      "jboss.naming.client.ejb.context":true, 
      "java.naming.factory.url.pkgs":"org.jboss.ejb.client.naming", 
      "org.jboss.ejb.client.scoped.context": true, 
      "endpoint.name":"client-endpoint", 


      "remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED":false, 
      "remote.connections":"default", 
      "remote.connection.default.connect.options.org.xnio.Options.SASL_POLICY_NOANONYMOUS":false, 
      "remote.connection.default.host":"${BinBaseConfigReader.getServer()}", 
      "remote.connection.default.port":"8080", 
      "remote.connection.default.protocol":"http-remoting", 
      "remote.connection.default.username":"binbase", 
      "remote.connection.default.password":"binbase" 


    ] 

}

resources.xml에

<?xml version="1.0" encoding="UTF-8"?> 
<beans xmlns="http://www.springframework.org/schema/beans" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jee="http://www.springframework.org/schema/jee" 
    xsi:schemaLocation="http://www.springframework.org/schema/beans 
         http://www.springframework.org/schema/beans/spring-beans.xsd http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee.xsd"> 

<jee:remote-slsb environment-ref="binbaseProperties" id="binbaseStatus" 
       jndi-name="ejb:bci/bci-core//StatusJMXFacadeBean!edu.ucdavis.genomics.metabolomics.binbase.bci.server.jmx.StatusJMXFacade" 
       business-interface="edu.ucdavis.genomics.metabolomics.binbase.bci.server.jmx.StatusJMXFacade" 
       lazy-init="true" /> 

remote.connection.default 특성이 제공되지 않으면 서버 측에서 클래스를 찾을 수 없음 오류와이 쓸모없는 오류 메시지와 함께 실패합니다.

관련 문제