我在Jboss EAP 6.2上安装了cicseci.rar。此资源适配器已从中下载 http://www-01.ibm.com/support/docview.wss?uid=swg24008817#sthash.3k4M8smo.dpuf
然而,在运行我的简单代码时,我收到此错误 -
Exception Logged by: com.ibm.connector2.cics.ECIInteraction
com.ibm.connector2.cics.CICSUserInputException: CTG9628E
InteractionSpec passed to execute() not of type ECIInteractionSpec
at com.ibm.connector2.cics.ECIInteraction.execute(Unknown Source)
at com.sample.checkstate.CICSPing.getIt(CICSPing.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
at com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$TypeOutInvoker._dispatch(AbstractResourceMethodDispat
at com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
at com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302)
at com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108)
at com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
at com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542)
at com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419)
at com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409)
at com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409)
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:558)
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:733)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149)
at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920)
at java.lang.Thread.run(Thread.java:662)
有没有人对此有任何见解?
答案 0 :(得分:1)
我遇到了同样的问题,经过多次研究,我发现ECIInteractionSpec类出现在2个罐子里--cicsj2ee.jar和ctgclient.jar。虽然ctgclient是部署cicseci.rar的一部分,但cicsj2ee不是。因此,在运行时,jboss服务器会尝试在ECIInteraction中映射ctgclient的类。这实际上应该来自cicsj2ee。
解决方案是创建一个模块并在那里包含所有与ctg相关的jar -
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.1" name="org.cics">
<resources>
<!-- Modules -->
<resource-root path="cicseci.jar" />
<resource-root path="cicsframe.jar"/>
<resource-root path="cicsj2ee.jar" />
<resource-root path="ctgclient.jar" />
<resource-root path="ctgserver.jar" />
</resources>
<dependencies>
<module name="javax.api" />
<module name="javax.resource.api"/>
</dependencies>
</module>
这应该作为模块加载器给出cics rar部署。您可以将其作为jboss-deployment-structure.xml的一部分包含在内,也可以作为standalone.xml中的全局模块包含在内。这解决了我的问题。希望它也能帮到你。