[ https://issues.apache.org/jira/browse/EAGLE-329?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hao Chen updated EAGLE-329: --------------------------- Description: h1. Problems 1) Jersey conflict with Java8: https://java.net/jira/browse/JERSEY-2429 {code} Caused by: java.lang.ArrayIndexOutOfBoundsException: 52264 at org.objectweb.asm.ClassReader.readClass(Unknown Source) ~[asm-3.1.jar:3.1] at org.objectweb.asm.ClassReader.accept(Unknown Source) ~[asm-3.1.jar:3.1] at org.objectweb.asm.ClassReader.accept(Unknown Source) ~[asm-3.1.jar:3.1] at com.sun.jersey.spi.scanning.AnnotationScannerListener.onProcess(AnnotationScannerListener.java:136) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner$1.f(FileSchemeScanner.java:86) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.util.Closing.f(Closing.java:71) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:83) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scan(FileSchemeScanner.java:71) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:225) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:141) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.ScanningResourceConfig.init(ScanningResourceConfig.java:80) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.PackagesResourceConfig.init(PackagesResourceConfig.java:104) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.PackagesResourceConfig.<init>(PackagesResourceConfig.java:78) ~[jersey-server-1.17.1.jar:1.17.1] {code} *Solution*: resolve with jersey-1.19.1 2) asm library conflict: Exception in thread "eXtcos managed thread 1" java.lang.ArrayIndexOutOfBoundsException: 256 {code} Exception in thread "eXtcos managed thread 1" java.lang.ArrayIndexOutOfBoundsException: 256 at org.objectweb.asm.ClassReader.readClass(Unknown Source) at org.objectweb.asm.ClassReader.accept(Unknown Source) at org.objectweb.asm.ClassReader.accept(Unknown Source) at net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:339) at net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:309) at net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:98) at net.sf.extcos.internal.URLResource.isClass(URLResource.java:131) at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) at net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) at net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) at java.lang.Thread.run(Thread.java:745) {code} *Solution*: Resolve by excluding unnecessary `asm` dependencies 3) extcos scanner exception under java8 (asm 3/4.x support up to java 7 bytecode, while asm 5 support java8), unfortunately, seems latest version of extcos is 0.4b which support 4.0 only. {code} Exception in thread "eXtcos managed thread 1" java.lang.IllegalArgumentException at org.objectweb.asm.ClassReader.<init>(Unknown Source) at org.objectweb.asm.ClassReader.<init>(Unknown Source) at net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:362) at net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:333) at net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:93) at net.sf.extcos.internal.URLResource.isClass(URLResource.java:126) at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) at net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) at net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) at java.lang.Thread.run(Thread.java:745) {code} *Solution*: {code} <dependency> <groupId>net.sf.extcos</groupId> <artifactId>extcos</artifactId> <exclusions> <exclusion> <groupId>org.ow2.asm</groupId> <artifactId>asm-all</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>org.ow2.asm</groupId> <artifactId>asm-all</artifactId> <version>5.0</version> </dependency> {code} h1. Root Cause * *asm is incompatible among asm-3.0,asm-4.0,asm-5.0*: the version of eagle before apache-eagle-v0.5 uses jersey v1.8 which requires asm-3.0, while eagle query engine requires asm-4.0 but storm requires asm-5.0. * *asm-3.0 and asm-4.0 is incompatible with jdk 8, but asm-5.0 does. * eagle query engine depends on *net.sf.extcos:extcos:0.4b" which support up to asm-4.0 * jersey 1.8 is not compatible with java 8, but jersey 1.9 is. h1. Final Solution to support Java 8. * Upgrade to jersey 1.9 * Exclude all asm dependencies and explicitly depend on only version "org.ow2.asm:asm-all:5.0". was: 1) Jersey conflict with Java8: https://java.net/jira/browse/JERSEY-2429 {code} Caused by: java.lang.ArrayIndexOutOfBoundsException: 52264 at org.objectweb.asm.ClassReader.readClass(Unknown Source) ~[asm-3.1.jar:3.1] at org.objectweb.asm.ClassReader.accept(Unknown Source) ~[asm-3.1.jar:3.1] at org.objectweb.asm.ClassReader.accept(Unknown Source) ~[asm-3.1.jar:3.1] at com.sun.jersey.spi.scanning.AnnotationScannerListener.onProcess(AnnotationScannerListener.java:136) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner$1.f(FileSchemeScanner.java:86) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.util.Closing.f(Closing.java:71) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:83) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scan(FileSchemeScanner.java:71) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:225) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:141) ~[jersey-core-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.ScanningResourceConfig.init(ScanningResourceConfig.java:80) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.PackagesResourceConfig.init(PackagesResourceConfig.java:104) ~[jersey-server-1.17.1.jar:1.17.1] at com.sun.jersey.api.core.PackagesResourceConfig.<init>(PackagesResourceConfig.java:78) ~[jersey-server-1.17.1.jar:1.17.1] {code} *Solution*: resolve with jersey-1.19.1 2) asm library conflict: Exception in thread "eXtcos managed thread 1" java.lang.ArrayIndexOutOfBoundsException: 256 {code} Exception in thread "eXtcos managed thread 1" java.lang.ArrayIndexOutOfBoundsException: 256 at org.objectweb.asm.ClassReader.readClass(Unknown Source) at org.objectweb.asm.ClassReader.accept(Unknown Source) at org.objectweb.asm.ClassReader.accept(Unknown Source) at net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:339) at net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:309) at net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:98) at net.sf.extcos.internal.URLResource.isClass(URLResource.java:131) at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) at net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) at net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) at java.lang.Thread.run(Thread.java:745) {code} *Solution*: Resolve by excluding unnecessary `asm` dependencies 3) extcos scanner exception under java8 (asm 3/4.x support up to java 7 bytecode, while asm 5 support java8), unfortunately, seems latest version of extcos is 0.4b which support 4.0 only. {code} Exception in thread "eXtcos managed thread 1" java.lang.IllegalArgumentException at org.objectweb.asm.ClassReader.<init>(Unknown Source) at org.objectweb.asm.ClassReader.<init>(Unknown Source) at net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:362) at net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:333) at net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:93) at net.sf.extcos.internal.URLResource.isClass(URLResource.java:126) at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) at net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) at net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) at java.lang.Thread.run(Thread.java:745) {code} *Solution*: {code} <dependency> <groupId>net.sf.extcos</groupId> <artifactId>extcos</artifactId> <exclusions> <exclusion> <groupId>org.ow2.asm</groupId> <artifactId>asm-all</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>org.ow2.asm</groupId> <artifactId>asm-all</artifactId> <version>5.0</version> </dependency> {code} > Dependency incompatibility bug among jersey, asm and extcos > ----------------------------------------------------------- > > Key: EAGLE-329 > URL: https://issues.apache.org/jira/browse/EAGLE-329 > Project: Eagle > Issue Type: Bug > Affects Versions: v0.5.0 > Reporter: Hao Chen > Assignee: Hao Chen > Labels: eagle-webservice > Fix For: v0.5.0 > > > h1. Problems > 1) Jersey conflict with Java8: https://java.net/jira/browse/JERSEY-2429 > {code} > Caused by: java.lang.ArrayIndexOutOfBoundsException: 52264 > at org.objectweb.asm.ClassReader.readClass(Unknown Source) > ~[asm-3.1.jar:3.1] > at org.objectweb.asm.ClassReader.accept(Unknown Source) > ~[asm-3.1.jar:3.1] > at org.objectweb.asm.ClassReader.accept(Unknown Source) > ~[asm-3.1.jar:3.1] > at > com.sun.jersey.spi.scanning.AnnotationScannerListener.onProcess(AnnotationScannerListener.java:136) > ~[jersey-server-1.17.1.jar:1.17.1] > at > com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner$1.f(FileSchemeScanner.java:86) > ~[jersey-core-1.17.1.jar:1.17.1] > at com.sun.jersey.core.util.Closing.f(Closing.java:71) > ~[jersey-core-1.17.1.jar:1.17.1] > at > com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:83) > ~[jersey-core-1.17.1.jar:1.17.1] > at > com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scan(FileSchemeScanner.java:71) > ~[jersey-core-1.17.1.jar:1.17.1] > at > com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:225) > ~[jersey-core-1.17.1.jar:1.17.1] > at > com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:141) > ~[jersey-core-1.17.1.jar:1.17.1] > at > com.sun.jersey.api.core.ScanningResourceConfig.init(ScanningResourceConfig.java:80) > ~[jersey-server-1.17.1.jar:1.17.1] > at > com.sun.jersey.api.core.PackagesResourceConfig.init(PackagesResourceConfig.java:104) > ~[jersey-server-1.17.1.jar:1.17.1] > at > com.sun.jersey.api.core.PackagesResourceConfig.<init>(PackagesResourceConfig.java:78) > ~[jersey-server-1.17.1.jar:1.17.1] > {code} > *Solution*: resolve with jersey-1.19.1 > 2) asm library conflict: Exception in thread "eXtcos managed thread 1" > java.lang.ArrayIndexOutOfBoundsException: 256 > {code} > Exception in thread "eXtcos managed thread 1" > java.lang.ArrayIndexOutOfBoundsException: 256 > at org.objectweb.asm.ClassReader.readClass(Unknown Source) > at org.objectweb.asm.ClassReader.accept(Unknown Source) > at org.objectweb.asm.ClassReader.accept(Unknown Source) > at > net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:339) > at > net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:309) > at > net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:98) > at net.sf.extcos.internal.URLResource.isClass(URLResource.java:131) > at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) > at > net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) > at > net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) > at java.lang.Thread.run(Thread.java:745) > {code} > *Solution*: Resolve by excluding unnecessary `asm` dependencies > 3) extcos scanner exception under java8 (asm 3/4.x support up to java 7 > bytecode, while asm 5 support java8), unfortunately, seems latest version of > extcos is 0.4b which support 4.0 only. > {code} > Exception in thread "eXtcos managed thread 1" > java.lang.IllegalArgumentException > at org.objectweb.asm.ClassReader.<init>(Unknown Source) > at org.objectweb.asm.ClassReader.<init>(Unknown Source) > at > net.sf.extcos.internal.JavaResourceAccessor.readClassData(JavaResourceAccessor.java:362) > at > net.sf.extcos.internal.JavaResourceAccessor.setResourceUrl(JavaResourceAccessor.java:333) > at > net.sf.extcos.internal.URLResource.getResourceAccessor(URLResource.java:93) > at net.sf.extcos.internal.URLResource.isClass(URLResource.java:126) > at net.sf.extcos.internal.RootFilter.filter(RootFilter.java:22) > at > net.sf.extcos.internal.AbstractChainedFilter.filter(AbstractChainedFilter.java:89) > at > net.sf.extcos.internal.ThreadingFilterInterceptor$1.run(ThreadingFilterInterceptor.java:48) > at java.lang.Thread.run(Thread.java:745) > {code} > *Solution*: > {code} > <dependency> > <groupId>net.sf.extcos</groupId> > <artifactId>extcos</artifactId> > <exclusions> > <exclusion> > <groupId>org.ow2.asm</groupId> > <artifactId>asm-all</artifactId> > </exclusion> > </exclusions> > </dependency> > <dependency> > <groupId>org.ow2.asm</groupId> > <artifactId>asm-all</artifactId> > <version>5.0</version> > </dependency> > {code} > h1. Root Cause > * *asm is incompatible among asm-3.0,asm-4.0,asm-5.0*: the version of eagle > before apache-eagle-v0.5 uses jersey v1.8 which requires asm-3.0, while eagle > query engine requires asm-4.0 but storm requires asm-5.0. > * *asm-3.0 and asm-4.0 is incompatible with jdk 8, but asm-5.0 does. > * eagle query engine depends on *net.sf.extcos:extcos:0.4b" which support up > to asm-4.0 > * jersey 1.8 is not compatible with java 8, but jersey 1.9 is. > h1. Final Solution to support Java 8. > * Upgrade to jersey 1.9 > * Exclude all asm dependencies and explicitly depend on only version > "org.ow2.asm:asm-all:5.0". -- This message was sent by Atlassian JIRA (v6.3.4#6332)