使用Jetty 9.2的META-INF/versions/9/*和Elasticsearch 6.2.2+上的字节码扫描错误 [英] Bytecode Scanning error on META-INF/versions/9/* and Elasticsearch 6.2.2+ with Jetty 9.2

查看:370
本文介绍了使用Jetty 9.2的META-INF/versions/9/*和Elasticsearch 6.2.2+上的字节码扫描错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以最新版本的Elasticsearch(6.1.1以上)在Superdev模式下运行GWT应用程序会产生以下错误(请参见下文). 显然,此问题与过时的Jetty版本有关. 有谁知道如何在GWT中替换Jetty或在IntelliJ中更改配置以使用其他服务器?我认为,GWT文档中的说明编写得很差.当然,理想情况下,当然,我希望有一种方法可以直接在GWT中更改Jetty,以便所有项目都可以使用更新的版本,而不是使用自己的服务器配置每个项目.

Running GWT app in the Superdev mode with the latest versions of Elasticsearch (above 6.1.1) creates the following error (see below). It is clear that the issue has to do with the outdated version of Jetty. Does anyone know how to replace Jetty in GWT or change the configuration in IntelliJ to use a different server? The instructions in GWT documentation are, in my opinion, poorly written. Ideally, of course, I wish there was a way to change Jetty directly in GWT so that all projects can use the updated version instead of configuring each project with its own server.

2018-06-20 16:17:13.923:INFO:oejs.Server:main: jetty-9.2.z-SNAPSHOT
Starting Jetty on port 8888
   [WARN] Failed startup of context c.g.g.d.s.j.WebAppContextWithReload@39f6694a{/,file:/Users/../Library/Caches/IntelliJIdea2018.1/gwt/....86a74491/....92536ba7/run/www/,STARTING}{/Users/../Library/Caches/IntelliJIdea2018.1/gwt/....86a74491/....92536ba7/run/www}
MultiException[java.lang.RuntimeException: Error scanning entry META-INF/versions/9/org/elasticsearch/core/internal/io/Streams.class from jar file:/Users/../Library/Caches/IntelliJIdea2018.1/gwt/.86a74491/.92536ba7/run/www/WEB-INF/lib/elasticsearch-core-6.3.0.jar, java.lang.RuntimeException: Error scanning entry META-INF/versions/9/org/elasticsearch/monitor/jvm/JvmPid.class from jar file:/Users/../Library/Caches/IntelliJIdea2018.1/gwt/...86a74491/.92536ba7/run/www/WEB-INF/lib/elasticsearch-6.3.0.jar]
    at org.eclipse.jetty.annotations.AnnotationConfiguration.scanForAnnotations(AnnotationConfiguration.java:536)
    at org.eclipse.jetty.annotations.AnnotationConfiguration.configure(AnnotationConfiguration.java:447)
    at org.eclipse.jetty.webapp.WebAppContext.configure(WebAppContext.java:479)

推荐答案

您有一个 JEP238 MultiRelease Jar文件在您的类路径中.

You have a JEP238 MultiRelease Jar File in your classpath.

META-INF/versions/9/前缀条目为证据.

JEP238是Java 9引入的一个概念.

JEP238 is a concept introduced with Java 9.

直到Jetty 9.4.9.v20180320(于2018年3月)才引入对字节码扫描期间处理JEP238 MultiRelease JAR文件的Jetty支持.

Jetty support for handling JEP238 MultiRelease JAR Files during bytecode scanning wasn't introduced until the Jetty 9.4.9.v20180320 (in March of 2018).

如果您需要使用Jetty 9.2.x,则不必使用JEP238 MultiRelease JAR文件.

If you need to stay with Jetty 9.2.x then you'll have to not use JEP238 MultiRelease JAR Files.

如果必须使用JEP238 MultiRelease JAR文件,则必须至少升级到Jetty 9.4.9.v20180320.

If you must use JEP238 MultiRelease JAR Files, then you must upgrade to at least Jetty 9.4.9.v20180320.

这篇关于使用Jetty 9.2的META-INF/versions/9/*和Elasticsearch 6.2.2+上的字节码扫描错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆