WSO2 Enterprise Integrator 6.0.0 unable to find snappy-java jar
Asked Answered
A

2

6

Following the quick start guide in https://docs.wso2.com/display/EI600/Quick+Start+Guide

Since I am using Windows, I have downloaded snappy-java and put into \wso2\analytics\lib but the exception as below still occurs when starting the EI analytics

Exception in thread "dag-scheduler-event-loop" java.lang.NoClassDefFoundError: org/xerial/snappy/SnappyInputStream
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:348)
    at org.apache.spark.util.Utils$.classForName(Utils.scala:175)
    at org.apache.spark.io.CompressionCodec$.createCodec(CompressionCodec.scala:71)
    at org.apache.spark.io.CompressionCodec$.createCodec(CompressionCodec.scala:65)
    at org.apache.spark.broadcast.TorrentBroadcast.org$apache$spark$broadcast$TorrentBroadcast$$setConf(TorrentBroadcast.scala:73)
    at org.apache.spark.broadcast.TorrentBroadcast.<init>(TorrentBroadcast.scala:80)
    at org.apache.spark.broadcast.TorrentBroadcastFactory.newBroadcast(TorrentBroadcastFactory.scala:34)
    at org.apache.spark.broadcast.BroadcastManager.newBroadcast(BroadcastManager.scala:63)
    at org.apache.spark.SparkContext.broadcast(SparkContext.scala:1326)
    at org.apache.spark.scheduler.DAGScheduler.submitMissingTasks(DAGScheduler.scala:1006)
    at org.apache.spark.scheduler.DAGScheduler.org$apache$spark$scheduler$DAGScheduler$$submitStage(DAGScheduler.scala:921)
    at org.apache.spark.scheduler.DAGScheduler.handleJobSubmitted(DAGScheduler.scala:861)
    at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.doOnReceive(DAGScheduler.scala:1607)
    at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1599)
    at org.apache.spark.scheduler.DAGSchedulerEventProcessLoop.onReceive(DAGScheduler.scala:1588)
    at org.apache.spark.util.EventLoop$$anon$1.run(EventLoop.scala:48)
Caused by: java.lang.ClassNotFoundException: org.xerial.snappy.SnappyInputStream cannot be found by spark-core_2.10_1.6.2.wso2v1
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 17 more

I am suspecting the guide is placing the jar at incorrect path, in previous version ESB 5.0.0, the path is in \repository\components\lib as given by https://docs.wso2.com/display/ESB500/Quick+Start+Guide

Aurelio answered 27/2, 2017 at 2:54 Comment(4)
Which is your EI_HOME? In my case the Quick Start Guide has worked fine: I think that the path <EI_HOME>\wso2\analytics\lib is correct. The error is to find elsewhere.Fiasco
what is the snappy java version you put?Firearm
@MarcoS. My EI_HOME is at C:\wso2\wso2ei-6.0.0 and thus i put the snappy-java -1.1.1.7.jar at C:\wso2\wso2ei-6.0.0\wso2\analytics\lib I have to create the lib folder manually, that happens to you too?Aurelio
EI_HOME\lib resolve the problem. The path <EI_HOME>\wso2\analytics\lib is for old version of Analytics. Thanks to @melodyLFiasco
L
4

The right path is EI_HOME\lib . When you see "starting polling event receivers" and the error does not appear,it works. Then you can go on. :)

Luiseluiza answered 14/3, 2017 at 16:22 Comment(0)
F
0

Try putting this version of snappy-java to lib.

http://mvnrepository.com/artifact/org.xerial.snappy/snappy-java/1.1.1.7

Make sure you remove the old version from both lib and dropins directories.

Firearm answered 27/2, 2017 at 8:53 Comment(1)
try adding it to repository/components/lib/Firearm

© 2022 - 2024 — McMap. All rights reserved.