loging to hazelcast management center is throwing NullPointerException - hazelcast

When I log in to Hazelcast management center I get the following exception. Not sure what exactly is causing this issue.
The Management Center is deployed in Weblogic 12c
Hazelcast version: 3.1.3
java.lang.reflect.InvocationTargetException
at sun.reflect.GeneratedMethodAccessor534.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:282)
at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:226)
at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:177)
at com.hazelcast.webmonitor.service.DataService.invokeMethod(DataService.java:108)
at com.hazelcast.webmonitor.service.DataService.getResponse(DataService.java:86)
at com.hazelcast.webmonitor.servlet.MainServlet.doGet(MainServlet.java:80)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:731)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:844)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:242)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:216)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:132)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:338)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:221)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3284)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.__run(WebAppServletContext.java:3254)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:57)
at weblogic.servlet.internal.WebAppServletContext.doSecuredExecute(WebAppServletContext.java:2163)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2089)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2074)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1513)
at weblogic.servlet.provider.ContainerSupportProviderImpl$WlsRequestExecutor.run(ContainerSupportProviderImpl.java:254)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
Caused by: java.lang.NullPointerException
at java.util.LinkedList$ListItr.next(LinkedList.java:891)
at java.util.SubList$1.next(AbstractList.java:707)
at java.util.AbstractCollection.toArray(AbstractCollection.java:141)
at java.util.Collections.sort(Collections.java:216)
at com.hazelcast.webmonitor.service.WarningLogsManager.getSystemWarnings(WarningLogsManager.java:96)
at com.hazelcast.webmonitor.service.DataService.showSystemWarning(DataService.java:717)
... 29 more

So finally this issue got resolved . I added the following preferred packages list to my weblogic.xml file because it was suggested by CAT tool .
<wls:package-name>javax.activation.*</wls:package-name>
<wls:package-name>javax.mail.*</wls:package-name>
<wls:package-name>javax.mail.event.*</wls:package-name>
<wls:package-name>javax.mail.internet.*</wls:package-name>
<wls:package-name>javax.mail.search.*</wls:package-name>
<wls:package-name>javax.mail.util.*</wls:package-name>
<wls:package-name>org.apache.commons.*</wls:package-name>
Removing those fixed the issue.

I just checked the code. The exception doesn't make any sense. Which JVM are you using. And perhaps it is smarter to run on a more lightweight container like jetty,tomcat etc.

Related

Spark 2.3 java.lang.NoSuchMethodError: io.netty.buffer.PooledByteBufAllocator.metric

SPARK 2.3 is throwing following exception. Can anyone please help!! I tried adding the JARs
308 [Driver] ERROR org.apache.spark.deploy.yarn.ApplicationMaster - User class threw exception: java.lang.NoSuchMethodError: io.netty.buffer.PooledByteBufAllocator.metric()Lio/netty/buffer/PooledByteBufAllocatorMetric;
java.lang.NoSuchMethodError: io.netty.buffer.PooledByteBufAllocator.metric()Lio/netty/buffer/PooledByteBufAllocatorMetric;
at org.apache.spark.network.util.NettyMemoryMetrics.registerMetrics(NettyMemoryMetrics.java:80)
at org.apache.spark.network.util.NettyMemoryMetrics.(NettyMemoryMetrics.java:76)
at org.apache.spark.network.client.TransportClientFactory.(TransportClientFactory.java:109)
at org.apache.spark.network.TransportContext.createClientFactory(TransportContext.java:99)
at org.apache.spark.rpc.netty.NettyRpcEnv.(NettyRpcEnv.scala:71)
at org.apache.spark.rpc.netty.NettyRpcEnvFactory.create(NettyRpcEnv.scala:461)
at org.apache.spark.rpc.RpcEnv$.create(RpcEnv.scala:57)
at org.apache.spark.SparkEnv$.create(SparkEnv.scala:249)
at org.apache.spark.SparkEnv$.createDriverEnv(SparkEnv.scala:175)
at org.apache.spark.SparkContext.createSparkEnv(SparkContext.scala:256)
at org.apache.spark.SparkContext.(SparkContext.scala:423)
at org.apache.spark.api.java.JavaSparkContext.(JavaSparkContext.scala:58)
at com.voicebase.etl.HBasePhoenixPerformance2.main(HBasePhoenixPerformance2.java:55)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.spark.deploy.yarn.ApplicationMaster$$anon$4.run(ApplicationMaster.scala:706)
315 [main] ERROR org.apache.spark.deploy.yarn.ApplicationMaster - Uncaught exception:
org.apache.spark.SparkException: Exception thrown in awaitResult:
at org.apache.spark.util.ThreadUtils$.awaitResult(ThreadUtils.scala:205)
at org.apache.spark.deploy.yarn.ApplicationMaster.runDriver(ApplicationMaster.scala:486)
at org.apache.spark.deploy.yarn.ApplicationMaster.org$apache$spark$deploy$yarn$ApplicationMaster$$runImpl(ApplicationMaster.scala:345)
at org.apache.spark.deploy.yarn.ApplicationMaster$$anonfun$run$2.apply$mcV$sp(ApplicationMaster.scala:260)
at org.apache.spark.deploy.yarn.ApplicationMaster$$anonfun$run$2.apply(ApplicationMaster.scala:260)
at org.apache.spark.deploy.yarn.ApplicationMaster$$anonfun$run$2.apply(ApplicationMaster.scala:260)
at org.apache.spark.deploy.yarn.ApplicationMaster$$anon$5.run(ApplicationMaster.scala:800)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:422)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1836)
at org.apache.spark.deploy.yarn.ApplicationMaster.doAsUser(ApplicationMaster.scala:799)
at org.apache.spark.deploy.yarn.ApplicationMaster.run(ApplicationMaster.scala:259)
at org.apache.spark.deploy.yarn.ApplicationMaster$.main(ApplicationMaster.scala:824)
at org.apache.spark.deploy.yarn.ApplicationMaster.main(ApplicationMaster.scala)
Caused by: java.util.concurrent.ExecutionException: Boxed Error
This is because Hadoop binaries compiled with an older version and need us to just replace them. I haven't faced any issues with Hadoop by replacing them.
You need to replace netty-3.6.2.Final.jar and netty-all-4.0.23.Final.jar from path $HADOOP_HOME\share\hadoop with netty-all-4.1.17.Final.jar and netty-3.9.9.Final.jar.
This issue plagues due to mismatch of the version that Hadoop and Spark are compiled on for Netty. So you can follow this.
Similar Issue , solved by manually compiling the Spark by using specific version of Netty
And the other one as recommended by Suhas , by copying the content of SPARK_HOME/jars folder to the various lib folder or only the one in yarn inside HADOOP_HOME/share/hadoop solves the problem also. But it's a dirty fix. So maybe use latest version of both or manually compile them.
An older version of Netty was required by the aws-java-sdk. Deleting all the netty jars and removing the aws-java-sdk from the project solved the problem.
Issue has been resolved by adding the below netty jars in the dependencies,
"io.netty" % "netty-all" % "4.1.68.Final"
"io.netty" % "netty-buffer" % "4.1.68.Final"
And excluding all existing netty jars by adding excludeAll code.
val excludeNettyBufferBinding = ExclusionRule(organization = "io.netty.buffer")
excludeAll(excludeNettyBufferBinding)

groovysh crashes under Java 1.7.0_75 (Windows XP)

Using the latest version of Groovy (as of this writing), 2.4.0, and Windows XP (sp3), I have encountered a familiar but perplexing error:
C:\>groovysh
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.groovy.tools.GroovyStarter.rootLoader(GroovyStarter.java
:106)
at org.codehaus.groovy.tools.GroovyStarter.main(GroovyStarter.java:128)
Caused by: groovy.lang.MissingPropertyException: No such property: leftPadding f
or class: org.codehaus.groovy.tools.shell.util.HelpFormatter
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptByteco
deAdapter.java:51)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.setGroovyObjectProp
erty(ScriptBytecodeAdapter.java:532)
at org.codehaus.groovy.tools.shell.util.HelpFormatter.<init>(HelpFormatt
er.groovy:39)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstruct
orAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingC
onstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstru
ctor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteN
oUnwrapNoCoerce.callConstructor(ConstructorSite.java:102)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstru
ctor(CallSiteArray.java:57)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor
(AbstractCallSite.java:230)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor
(AbstractCallSite.java:234)
at org.codehaus.groovy.tools.shell.Main.main(Main.groovy:68)
... 6 more
I experienced no difficulty using Groovy 2.3.9 so I was wondering if anyone had a constructive suggestion.
Thanks.
Your Error occurs in the HelpFormatter class. The sources can be found via google, i.e. here:
https://github.com/groovy/groovy-core/blob/master/subprojects/groovy-groovysh/src/main/groovy/org/codehaus/groovy/tools/shell/util/HelpFormatter.groovy
As you can see, class HelpFormatter extends org.apache.commons.cli.HelpFormatter
And expects the superclass to have a field leftPadding, but does not find one.
This could be the case if you have a different version of apache commons-cli.jar on your CLASSPATH when running groovysh.
Since I cannot reproduce your problem, this is the most likely cause I can see.
Run
echo %CLASSPATH
in Windows to see the CLASSPATh (I think).

liferay theme is not getting deployed on 6.1.2 GA3

I am trying to deploy my theme which is developed on liferay-plugins-sdk-6.1.0-ce to liferay-portal-6.1.2-ga3-ce.
My liferay is running on jre 1.7 update 51
The following errors are observed in the console..
Listener:89] Registering themes for 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
The liferay-version information is properly updated in liferay-look-and-feel.xml and liferay-plugin-package.properties files(I have set it to 6.1.2)
This might be due to the jre version because, my theme was deployed successfully on liferay running on jre 1.6 update 26
My requirement is I have to deploy my theme on liferay that is running on jre 1.7 update 51
can any one please help me out in resolving this issue!!
You seem to be running into https://support.liferay.com/browse/LPS-37433 - that one is supposed to be fixed in the version you're running, but look at the related issues: There's one called "Final Fix":
Some JDK update has changed the way PNG files are processed and Liferay has an offending png image (you might add your own ones). The easiest way to fix this is to understand the issue and change the relevant PNGs manually to some that can be processed by java.
Unfortunately hunting down the png is a bit harder than necessary. As you're developing your theme, you might want to run Liferay in a debugger and configure a breakpoint on any trigger of the exception you see. Then you'll find the relevant filename if you move up the stack and inspect parameter names in the debugger. Or, try the calendar-dropshadow image that's mentioned in the linked ticket first.
I don't know what is fail of your theme, but here is my 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>
and here the 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+
Please check this Liferay issue: https://issues.liferay.com/browse/LPS-37433.
A workaround to this issue is mentioned here: https://www.liferay.com/community/forums/-/message_boards/view_message/27101897#_19_message_26861049

Scriptella: ResourceException with Jaybird

I'm very newbie with Linux/Java/Scriptella and I'm trying a jdbc connection with scriptella on a Firebird local database, but I'm receiving the following errors:
2-dic-2013 1.03.34 <INFO> Execution Progress.Initializing properties: 1%
2-dic-2013 1.03.34 <GRAVE> Script /home/maurizio/Scrivania/JATROPHA/applicazioni/prova_per_scriptella.etl execution failed.
javax/resource/ResourceException
2-dic-2013 1.03.34 <GRAVE> Scriptella bug report. Submit to issue tracker.
Scriptella version: 1.1
Exception:
scriptella.execution.EtlExecutorException: javax/resource/ResourceException
at scriptella.execution.EtlExecutor.execute(EtlExecutor.java:190)
at scriptella.tools.launcher.EtlLauncher.execute(EtlLauncher.java:276)
at scriptella.tools.launcher.EtlLauncher.launch(EtlLauncher.java:193)
at scriptella.tools.launcher.EtlLauncher.main(EtlLauncher.java:321)
Caused by: java.lang.NoClassDefFoundError: javax/resource/ResourceException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:270)
at scriptella.core.DriverFactory.getDriver(DriverFactory.java:53)
at scriptella.core.ConnectionManager.<init>(ConnectionManager.java:70)
at scriptella.core.Session.<init>(Session.java:51)
at scriptella.execution.EtlExecutor.prepare(EtlExecutor.java:248)
at scriptella.execution.EtlExecutor.execute(EtlExecutor.java:178)
... 3 more
Caused by: java.lang.ClassNotFoundException: javax.resource.ResourceException
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:323)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:268)
... 10 more
I'm using Ubuntu 10.04 Lucid Lynx.
I start scriptella via console in directory /home/maurizio/Scrivania/JATROPHA/applicazioni/ with the command scriptella/scriptella-1.1/bin/scriptella.sh -debug "prova_per_scriptella.etl"
My ETL file prova_per_scriptella.etl contains the following rows:
<!DOCTYPE etl SYSTEM "http://scriptella.javaforge.com/dtd/etl.dtd">
<etl>
<description>Prova connessione Firebird</description>
<connection
id="fb_destination"
driver="org.firebirdsql.jdbc.FBDriver"
url="jdbc:firebirdsql:localhost/3050:/home/maurizio/Scrivania/JATROPHA/db/jatrofa.fdb"
user="user"
password="password"
classpath="/home/maurizio/Scrivania/JATROPHA/applicazioni/jaybird/Jaybird-2.2.3JDK_1.6/jaybird-2.2.3.jar"
/>
</etl>
The env var $_SCRIPTELLA_CP of batch command scriptella/scriptella-1.1/bin/scriptella.sh results in
:/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/commons-jexl.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/commons-logging.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/jaybird-2.2.3.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/jsqlparser-0.8.0.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/scriptella-core.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/scriptella-drivers.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/scriptella-tools.jar:
/home/maurizio/Scrivania/JATROPHA/applicazioni/scriptella/scriptella-1.1/lib/sqlsheet-6.5.jar
Any help would be very appreciated.
Thanks in advance.
You are missing the required dependency connector-api-1.5.jar, or you need to use jaybird-full-2.2.3.jar (which includes both the normal Jaybird and connector-api). See the releasenotes of Jaybird 2.2.3
The error means that you probably miss additional J2EE classes on classpath. Try downloading mini-j2ee.jar from http://www.firebirdsql.org/en/jdbc-driver/ and adding it to classpath attribute in etl.xml:
classpath="/path/to/mini-j2ee.jar:/home/maurizio/Scrivania/JATROPHA/applicazioni/jaybird/Jaybird-2.2.3JDK_1.6/jaybird-2.2.3.jar"

Cassandra Startup java.lang.reflect.InvocationTargetException

What could be the solution for this exception
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.xerial.snappy.SnappyLoader.loadNativeLibrary(SnappyLoader.java:322)
at org.xerial.snappy.SnappyLoader.load(SnappyLoader.java:229)
at org.xerial.snappy.Snappy.<clinit>(Snappy.java:48)
at org.xerial.snappy.SnappyOutputStream.<init>(SnappyOutputStream.java:79)
at org.xerial.snappy.SnappyOutputStream.<init>(SnappyOutputStream.java:66)
at org.apache.cassandra.net.OutboundTcpConnection.connect(OutboundTcpConnection.java:359)
at org.apache.cassandra.net.OutboundTcpConnection.run(OutboundTcpConnection.java:150)
Caused by: java.lang.UnsatisfiedLinkError: /tmp/snappy-1.0.5-libsnappyjava.so: /tmp/snappy-1.0.5-libsnappyjava.so: failed to map segment from shared object: Operation not permitted
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1957)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1882)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1843)
at java.lang.Runtime.load0(Runtime.java:795)
at java.lang.System.load(System.java:1061)
at org.xerial.snappy.SnappyNativeLoader.load(SnappyNativeLoader.java:39)
... 11 more
ERROR 11:46:22,430 Exception in thread Thread[WRITE-/172.20.6.138,5,main]
org.xerial.snappy.SnappyError: [FAILED_TO_LOAD_NATIVE_LIBRARY] null
at org.xerial.snappy.SnappyLoader.load(SnappyLoader.java:239)
at org.xerial.snappy.Snappy.<clinit>(Snappy.java:48)
at org.xerial.snappy.SnappyOutputStream.<init>(SnappyOutputStream.java:79)
at org.xerial.snappy.SnappyOutputStream.<init>(SnappyOutputStream.java:66)
at org.apache.cassandra.net.OutboundTcpConnection.connect(OutboundTcpConnection.java:359)
at org.apache.cassandra.net.OutboundTcpConnection.run(OutboundTcpConnection.java:150)
But the cassandra startup execution is continue. and at the end i am getting exception
java.lang.IllegalStateException: Unable to contact any seeds!
at org.apache.cassandra.service.StorageService.bootstrap(StorageService.java:947)
at org.apache.cassandra.service.StorageService.joinTokenRing(StorageService.java:716)
at org.apache.cassandra.service.StorageService.initServer(StorageService.java:554)
at org.apache.cassandra.service.StorageService.initServer(StorageService.java:451)
at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:347)
at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:446)
at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:489)
Exception encountered during startup: Unable to contact any seeds!
ERROR 11:55:11,732 Exception in thread Thread[StorageServiceShutdownHook,5,main]
java.lang.NullPointerException
at org.apache.cassandra.service.StorageService.stopRPCServer(StorageService.java:321)
at org.apache.cassandra.service.StorageService.shutdownClientServers(StorageService.java:370)
at org.apache.cassandra.service.StorageService.access$000(StorageService.java:88)
at org.apache.cassandra.service.StorageService$1.runMayThrow(StorageService.java:519)
at org.apache.cassandra.utils.WrappedRunnable.run(WrappedRunnable.java:28)
at java.lang.Thread.run(Thread.java:724)
but the seeds nodes are running.
Machine firewall is disabled.
I also tried changing default tmp directory. I tried including JVM_OPTS=-Dorg.xerial.snappy.tempdir=/tmp to cassandra.in.sh file but the problem is remains.
Linux version 2.6.32-358.6.1.el6.x86_64 (mockbuild#c6b9.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Tue Apr 23 19:29:00 UTC 2013
please help me.. thanks in advance.
They mention this error here in the Cassandra JIRA:
https://issues.apache.org/jira/browse/CASSANDRA-4400
I had a similar error with Cassandra 1.2, and I fixed it by replacing the snappy 1.0.5 library with the snappy 1.0.4.1. If that link doesn't work, you should be able to grab that from an earlier version of Cassandra (like 1.1.x).
Basically, remove the snappy-java.1.0.5.jar from your $CASSANDRA_HOME/lib directory, and replace it with snappy-java-1.0.4.1.jar
I found an answer wrote by Erik in
http://mail-archives.apache.org/mod_mbox/cassandra-user/201312.mbox/%3C52C1DEC4.2080904#cj.com%3E
You can add something like this to cassandra-env.sh :
JVM_OPTS="$JVM_OPTS
-Dorg.xerial.snappy.tempdir=/path/that/allows/executables"
I created a tmp folder in /var/lib/cassandra/
so I added
JVM_OPTS="$JVM_OPTS -Dorg.xerial.snappy.tempdir=/var/lib/cassandra/tmp/"
Hope this help somebody

Resources