我目前正在尝试在Worklight v6的新安装上运行Worklight Application Center,该安装在WebSphere Application Server v8和WebSphere Portal v8上运行。这似乎很简单,IBM Installation Manager根本不会抱怨。安装完成后,我甚至可以登录到Application Center。但是,该页面显示HTTP 500错误,并“灰显”所有选项。这也可以防止再次注销。
在WAS日志中,当页面错误输出时,会出现以下错误:
SystemErr R javax.persistence.PersistenceException: Provider error. Provider: org.apache.openjpa.persistence.PersistenceProviderImpl
SystemErr R at javax.persistence.Persistence.createFactory(Persistence.java:175)
SystemErr R at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:111)
SystemErr R at com.ibm.puremeap.resources.data.impl.PureMeapDataJPAImpl.<init>(PureMeapDataJPAImpl.java:211)
SystemErr R at com.ibm.puremeap.resources.data.impl.PureMeapDataJPAImpl.fromDataSource(PureMeapDataJPAImpl.java:135)
SystemErr R at com.ibm.puremeap.resources.data.DataStoreFactory.getJPADBStore(DataStoreFactory.java:45)
SystemErr R at com.ibm.puremeap.resources.data.DataStoreFactory.getDataStore(DataStoreFactory.java:33)
SystemErr R at com.ibm.puremeap.util.DataUtil.getData(DataUtil.java:452)
SystemErr R at com.ibm.puremeap.services.BaseService.<init>(BaseService.java:46)
SystemErr R at com.ibm.puremeap.services.MobileServices.<init>(MobileServices.java:51)
SystemErr R at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
SystemErr R at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:56)
SystemErr R at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:39)
SystemErr R at java.lang.reflect.Constructor.newInstance(Constructor.java:527)
SystemErr R at org.apache.wink.common.internal.lifecycle.CreationUtils.createObject(CreationUtils.java:66)
SystemErr R at org.apache.wink.common.internal.lifecycle.PrototypeObjectFactory.getInstance(PrototypeObjectFactory.java:45)
SystemErr R at org.apache.wink.server.internal.registry.ResourceInstance.getInstance(ResourceInstance.java:80)
SystemErr R at org.apache.wink.server.internal.handlers.InvokeMethodHandler.handleRequest(InvokeMethodHandler.java:48)
SystemErr R at org.apache.wink.server.handlers.AbstractHandler.handleRequest(AbstractHandler.java:33)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.CreateInvocationParametersHandler.handleRequest(CreateInvocationParametersHandler.java:54)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.handlers.AbstractHandler.handleRequest(AbstractHandler.java:34)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.FindResourceMethodHandler.handleSubResourceMethod(FindResourceMethodHandler.java:183)
SystemErr R at org.apache.wink.server.internal.handlers.FindResourceMethodHandler.handleRequest(FindResourceMethodHandler.java:110)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.FindRootResourceHandler.handleRequest(FindRootResourceHandler.java:95)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.HeadMethodHandler.handleRequest(HeadMethodHandler.java:53)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.OptionsMethodHandler.handleRequest(OptionsMethodHandler.java:46)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.handlers.SearchResultHandler.handleRequest(SearchResultHandler.java:33)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.log.ResourceInvocation.handleRequest(ResourceInvocation.java:92)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.internal.log.Requests.handleRequest(Requests.java:76)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:26)
SystemErr R at org.apache.wink.server.handlers.RequestHandlersChain.handle(RequestHandlersChain.java:22)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.doChain(AbstractHandlersChain.java:67)
SystemErr R at org.apache.wink.server.handlers.AbstractHandlersChain.run(AbstractHandlersChain.java:52)
SystemErr R at org.apache.wink.server.internal.RequestProcessor.handleRequestWithoutFaultBarrier(RequestProcessor.java:207)
SystemErr R at org.apache.wink.server.internal.RequestProcessor.handleRequest(RequestProcessor.java:154)
SystemErr R at org.apache.wink.server.internal.servlet.RestServlet.service(RestServlet.java:133)
SystemErr R at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1225)
SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:775)
SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:457)
SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1032)
SystemErr R at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:87)
SystemErr R at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:908)
SystemErr R at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1662)
SystemErr R at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:195)
SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:453)
SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:515)
SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:306)
SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:277)
SystemErr R at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214)
SystemErr R at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113)
SystemErr R at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:166)
SystemErr R at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
SystemErr R at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
SystemErr R at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
SystemErr R at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
SystemErr R at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
SystemErr R at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1691)
SystemErr R Caused by: <openjpa-1.2.2-r422266:898935 nonfatal general error> org.apache.openjpa.util.GeneralException: org.xml.sax.SAXException: wsjar:file:/opt/IBM/WebSphere/PortalServer/wcm/prereq.wcm/wcm/shared/app/ilwwcm-eventlog-jpa.jar!/META-INF/persistence.xml [Location: Line: 3, C: 121]: org.xml.sax.SAXParseException: cvc-complex-type.3.1: Value '2.0' of attribute 'version' of element 'persistence' is not valid with respect to the corresponding attribute use. Attribute 'version' has a fixed value of '1.0'.
SystemErr R at org.apache.openjpa.lib.meta.XMLMetaDataParser.parseNewResource(XMLMetaDataParser.java:379)
SystemErr R at org.apache.openjpa.lib.meta.XMLMetaDataParser.parse(XMLMetaDataParser.java:318)
SystemErr R at org.apache.openjpa.lib.meta.XMLMetaDataParser.parse(XMLMetaDataParser.java:295)
SystemErr R at org.apache.openjpa.lib.meta.XMLMetaDataParser.parse(XMLMetaDataParser.java:268)
SystemErr R at org.apache.openjpa.persistence.PersistenceProductDerivation$ConfigurationParser.parse(PersistenceProductDerivation.java:509)
SystemErr R at org.apache.openjpa.persistence.PersistenceProductDerivation.parseResources(PersistenceProductDerivation.java:359)
SystemErr R at org.apache.openjpa.persistence.PersistenceProductDerivation.load(PersistenceProductDerivation.java:326)
SystemErr R at org.apache.openjpa.persistence.PersistenceProductDerivation.load(PersistenceProductDerivation.java:161)
SystemErr R at org.apache.openjpa.persistence.PersistenceProviderImpl.createEntityManagerFactory(PersistenceProviderImpl.java:83)
SystemErr R at org.apache.openjpa.persistence.PersistenceProviderImpl.createEntityManagerFactory(PersistenceProviderImpl.java:117)
SystemErr R at org.apache.openjpa.persistence.PersistenceProviderImpl.createEntityManagerFactory(PersistenceProviderImpl.java:59)
SystemErr R at javax.persistence.Persistence.createFactory(Persistence.java:171)
SystemErr R ... 85 more
我已经搜索了我能想到的这个错误的所有组合,到目前为止还没有实际似乎适用的解决方案。触发错误的jar“ilwwcm-eventlog-jpa.jar”似乎是Portal的库存库。为了排除故障,我甚至尝试解压缩库存JAR,将引用的xml文件更改为“1.0”而不是“2.0”,重新打包JAR,然后尝试解决。这只会导致WAS在同一文件中的不同XML标记上抛出异常。
有人看过这个,或者对如何修复它有任何想法?
答案 0 :(得分:0)
我的猜测是,Websphere为您提供了错误版本的OpenJPA。 Application Center附带了自己的OpenJPA本地版本。为了消除全局OpenJPA的副作用,建议使用“Parent last”类加载器策略:
进入Websphere Application Server管理控制台:
这通常不是默认值,但你应该使用它。
这应该是默认值并且很好。
为了确定,之后重启Websphere Application Server。
答案 1 :(得分:0)
我遇到了同样的问题。 我想如果我删除ilwwcm-eventlog-jpa.jar文件,它应该修复worklight。我将文件的扩展名从.jar更改为.abc,以便类加载器找不到它。 这确实修复了WorkLight,但却破坏了门户网站的WCM创作portlet。