我正在尝试将我在Liferay-plugins-sdk-6.1.0-ce上开发的主题部署到liferay-portal-6.1.2-ga3-ce。
我的liferay正在运行jre 1.7 update 51
在控制台中观察到以下错误..
听众:89]为xyz-theme
注册主题java.awt.image.RasterFormatException: Incorrect scanline stride: 4
at sun.awt.image.ByteComponentRaster.verify(ByteComponentRaster.java:894)
at sun.awt.image.ByteComponentRaster.<init>(ByteComponentRaster.java:201)
at sun.awt.image.ByteInterleavedRaster.<init>(ByteInterleavedRaster.java:191)
at sun.awt.image.ByteInterleavedRaster.<init>(ByteInterleavedRaster.java:113)
at java.awt.image.Raster.createWritableRaster(Raster.java:980)
at javax.media.jai.RecyclingTileFactory.createTile(RecyclingTileFactory.java:392)
at javax.media.jai.PlanarImage.createWritableRaster(PlanarImage.java:1982)
at javax.media.jai.PointOpImage.computeTile(PointOpImage.java:771)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:904)
at javax.media.jai.OpImage.getTile(OpImage.java:1129)
at javax.media.jai.PointOpImage.computeTile(PointOpImage.java:962)
at com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:904)
at javax.media.jai.OpImage.getTile(OpImage.java:1129)
at javax.media.jai.PlanarImage.copyData(PlanarImage.java:2343)
at javax.media.jai.RenderedOp.copyData(RenderedOp.java:2299)
at javax.media.jai.RenderedImageAdapter.copyData(RenderedImageAdapter.java:163)
at javax.media.jai.PlanarImage.getAsBufferedImage(PlanarImage.java:2525)
at javax.media.jai.PlanarImage.getAsBufferedImage(PlanarImage.java:2546)
at com.liferay.portal.image.ImageToolImpl.getBufferedImage(ImageToolImpl.java:152)
at com.liferay.portal.image.ImageToolImpl.encodeGIF(ImageToolImpl.java:85)
at sun.reflect.GeneratedMethodAccessor229.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja
va:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.liferay.portal.security.lang.DoPrivilegedHandler.doInvoke(DoPrivilegedHandl
er.java:88)
at com.liferay.portal.security.lang.DoPrivilegedHandler.invoke(DoPrivilegedHandler
.java:56)
at com.sun.proxy.$Proxy35.encodeGIF(Unknown Source)
at com.liferay.portal.kernel.image.ImageToolUtil.encodeGIF(ImageToolUtil.java:40)
at com.liferay.portal.image.SpriteProcessorImpl.generate(SpriteProcessorImpl.java:
224)
at sun.reflect.GeneratedMethodAccessor109.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja
va:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.liferay.portal.security.lang.DoPrivilegedHandler.doInvoke(DoPrivilegedHandl
er.java:88)
at com.liferay.portal.security.lang.DoPrivilegedHandler.invoke(DoPrivilegedHandler
.java:56)
at com.sun.proxy.$Proxy36.generate(Unknown Source)
at com.liferay.portal.kernel.image.SpriteProcessorUtil.generate(SpriteProcessorUti
l.java:39)
at com.liferay.portal.service.impl.ThemeLocalServiceImpl._setSpriteImages(ThemeLoc
alServiceImpl.java:785)
at com.liferay.portal.service.impl.ThemeLocalServiceImpl._readThemes(ThemeLocalSer
viceImpl.java:728)
at com.liferay.portal.service.impl.ThemeLocalServiceImpl.init(ThemeLocalServiceImp
l.java:268)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja
va:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:117)
at com.liferay.portal.spring.transaction.DefaultTransactionExecutor.execute(Defaul
tTransactionExecutor.java:62)
at com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(Transaction
Interceptor.java:52)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:113)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvic
e.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:113)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvic
e.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:113)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvic
e.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:113)
at com.liferay.portal.spring.aop.ChainableMethodAdvice.invoke(ChainableMethodAdvic
e.java:56)
at com.liferay.portal.spring.aop.ServiceBeanMethodInvocation.proceed(ServiceBeanMe
thodInvocation.java:113)
at com.liferay.portal.spring.aop.ServiceBeanAopProxy.invoke(ServiceBeanAopProxy.ja
va:218)
at com.liferay.portal.security.pacl.PACLInvocationHandler.doInvoke(PACLInvocationH
andler.java:62)
at com.liferay.portal.security.pacl.PACLInvocationHandler.invoke(PACLInvocationHan
dler.java:51)
at com.sun.proxy.$Proxy188.init(Unknown Source)
at com.liferay.portal.service.ThemeLocalServiceUtil.init(ThemeLocalServiceUtil.jav
a:114)
at com.liferay.portal.deploy.hot.ThemeHotDeployListener.doInvokeDeploy(ThemeHotDep
loyListener.java:92)
at com.liferay.portal.deploy.hot.ThemeHotDeployListener.invokeDeploy(ThemeHotDeplo
yListener.java:46)
at com.liferay.portal.deploy.hot.HotDeployImpl.doFireDeployEvent(HotDeployImpl.jav
a:195)
at com.liferay.portal.deploy.hot.HotDeployImpl.fireDeployEvent(HotDeployImpl.java:
97)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.ja
va:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at com.liferay.portal.security.lang.DoPrivilegedHandler.doInvoke(DoPrivilegedHandl
er.java:88)
at com.liferay.portal.security.lang.DoPrivilegedHandler.invoke(DoPrivilegedHandler
.java:56)
at com.sun.proxy.$Proxy30.fireDeployEvent(Unknown Source)
at com.liferay.portal.kernel.deploy.hot.HotDeployUtil.fireDeployEvent(HotDeployUti
l.java:27)
at com.liferay.portal.kernel.servlet.PluginContextListener.fireDeployEvent(PluginC
ontextListener.java:164)
at com.liferay.portal.kernel.servlet.PluginContextListener.doPortalInit(PluginCont
extListener.java:154)
at com.liferay.portal.kernel.util.BasePortalLifecycle.portalInit(BasePortalLifecyc
le.java:44)
at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil
.java:64)
at com.liferay.portal.kernel.util.PortalLifecycleUtil.register(PortalLifecycleUtil
.java:56)
at com.liferay.portal.kernel.util.BasePortalLifecycle.registerPortalLifecycle(Base
PortalLifecycle.java:54)
at com.liferay.portal.kernel.servlet.PluginContextListener.contextInitialized(Plug
inContextListener.java:116)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:488
7)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:538
1)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.StandardContext.reload(StandardContext.java:3926)
at org.apache.catalina.startup.HostConfig.checkResources(HostConfig.java:1271)
at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1440)
at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:301)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.j
ava:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90
)
at org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:137
4)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChil
dren(ContainerBase.java:1530)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChil
dren(ContainerBase.java:1540)
at org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(Contain
erBase.java:1519)
at java.lang.Thread.run(Thread.java:744)
08:55:09,733 INFO [ContainerBackgroundProcessor[StandardEngine[Catalina]]][ThemeHotDeploy
[ThemeHotDeployListener:107] 0 themes for xyz-theme are available for use
在liferay-look-and-feel.xml和liferay-plugin-package.properties文件中正确更新了liferay-version信息(我已将其设置为6.1.2)
这可能是因为jre版本,因为我的主题在jre 1.6 update 26上运行的liferay上成功部署了
我的要求是我必须在jre 1.7 update 51
上运行的liferay上部署我的主题任何人都可以帮我解决这个问题!!
答案 0 :(得分:1)
你似乎遇到了https://support.liferay.com/browse/LPS-37433 - 应该在你正在运行的版本中修复一个,但是看一下相关的问题:有一个名为“Final Fix”:
某些JDK更新改变了PNG文件的处理方式,Liferay有一个违规的png图像(您可以添加自己的图像)。解决此问题的最简单方法是了解问题并手动将相关PNG更改为可由java处理的PNG。
不幸的是,追捕png有点困难。在开发主题时,您可能希望在调试器中运行Liferay,并在您看到的异常的任何触发器上配置断点。然后,如果向上移动堆栈并检查调试器中的参数名称,您将找到相关的文件名。或者,首先尝试链接票证中提到的calendar-dropshadow图像。
答案 1 :(得分:0)
我不知道您主题的失败,但这是我的liferay-look-and-feel.xml
<?xml version="1.0"?>
<!DOCTYPE look-and-feel PUBLIC "-//Liferay//DTD Look and Feel 6.0.0//EN" "http://www.liferay.com/dtd/liferay-look-and-feel_6_0_0.dtd">
<look-and-feel>
<compatibility>
<version>6.1.1+</version>
</compatibility>
<theme id="MyTheme" name="MyTheme">
</theme>
</look-and-feel>
这里是liferay-plugin-package.properties
name=MyTheme
module-group-id=liferay
module-incremental-version=1
tags=
short-description=
change-log=
page-url=http://mydomain
author=Ani
licenses=open
# 6.1.1 is 6.1.1 CE GA2 | 6.1.20+ is 6.1.2 EE GA2
liferay-versions=6.1.1,6.1.20+
答案 2 :(得分:0)