我们有一个依赖项(JAR),它确实包含一个清单文件,该文件在其Class-Path
条目中引用了其他JAR。应用程序不需要这些引用的其他JAR,因此不会作为依赖项添加。
当应用程序启动时,tomcat 会尝试解析该类路径条目,最终在日志中出现大量错误。喜欢:
The Class-Path manifest attribute in /Users/me/.m2/repository/org/bytedeco/javacpp-presets/openblas/0.3.3-1.4.3/openblas-0.3.3-1.4.3.jar referenced one or more files that do not exist: file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/openblas/0.3.3-1.4.3/javacpp.jar
The Class-Path manifest attribute in /Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-platform-2019.0-1.4.3.jar referenced one or more files that do not exist: file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-linux-x86.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-linux-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-macosx-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-windows-x86.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-windows-x86_64.jar
The Class-Path manifest attribute in /Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl/2019.0-1.4.3/mkl-2019.0-1.4.3.jar referenced one or more files that do not exist: file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl/2019.0-1.4.3/javacpp.jar
The Class-Path manifest attribute in /Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-dnn-platform/0.16-1.4.3/mkl-dnn-platform-0.16-1.4.3.jar referenced one or more files that do not exist: file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-dnn-platform/0.16-1.4.3/mkl-dnn.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-dnn-platform/0.16-1.4.3/mkl-dnn-linux-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-dnn-platform/0.16-1.4.3/mkl-dnn-macosx-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-dnn-platform/0.16-1.4.3/mkl-dnn-windows-x86_64.jar
The Class-Path manifest attribute in /Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-platform-2019.0-1.4.3.jar referenced one or more files that do not exist: file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-linux-x86.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-linux-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-macosx-x86_64.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-windows-x86.jar,file:/Users/me/.m2/repository/org/bytedeco/javacpp-presets/mkl-platform/2019.0-1.4.3/mkl-windows-x86_64.jar
...
WARNING: Failed to scan [file:/Users/domi/.m2/repository/org/bytedeco/javacpp-presets/hdf5-platform/1.10.3-1.4.3/hdf5.jar] from classloader hierarchy
java.io.IOException: java.lang.reflect.InvocationTargetException
at org.apache.tomcat.util.compat.Jre9Compat.jarFileNewInstance(Jre9Compat.java:212)
at org.apache.tomcat.util.scan.JarFileUrlJar.<init>(JarFileUrlJar.java:65)
at org.apache.tomcat.util.scan.JarFactory.newInstance(JarFactory.java:49)
at org.apache.tomcat.util.scan.StandardJarScanner.process(StandardJarScanner.java:374)
at org.apache.tomcat.util.scan.StandardJarScanner.processURLs(StandardJarScanner.java:309)
...
Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.GeneratedConstructorAccessor78.newInstance(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at org.apache.tomcat.util.compat.Jre9Compat.jarFileNewInstance(Jre9Compat.java:209)
... 49 more
Caused by: java.nio.file.NoSuchFileException: /Users/domi/.m2/repository/org/bytedeco/javacpp-presets/hdf5-platform/1.10.3-1.4.3/hdf5.jar
at java.base/sun.nio.fs.UnixException.translateToIOException(UnixException.java:92)
at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111)
at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116)
at java.base/sun.nio.fs.UnixFileAttributeViews$Basic.readAttributes(UnixFileAttributeViews.java:55)
at java.base/sun.nio.fs.UnixFileSystemProvider.readAttributes(UnixFileSystemProvider.java:145)
at java.base/java.nio.file.Files.readAttributes(Files.java:1763)
at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1222)
at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:726)
...
如这里所述,Tomcat已经实现了一个开关来禁用清单的扫描,以防止出现此问题:https://bz.apache.org/bugzilla/show_bug.cgi?id=59961
在正常的tomcat安装中,我们可以这样做(https://tomcat.apache.org/tomcat-8.0-doc/config/jar-scanner.html):
<Context>
...
<JarScanner scanManifest="false"/>
</Context>
如何使用Spring靴禁用雄猫清单扫描?
你可以喜欢底部
@Bean
public TomcatServletWebServerFactory tomcatFactory() {
return new TomcatServletWebServerFactory() {
@Override
protected void postProcessContext(Context context) {
((StandardJarScanner) context.getJarScanner()).setScanManifest(false);
}};
}
我无法理解从phonegap发送ajax请求时,如果没有使用tomcat处理请求,则返回403错误。如果使用码头嵌入工作冷却。 我的控制器 如何在tomcat中完整记录请求,或者如何从spring修复它。在简单的rest中,客户机工作很酷。 获取返回 主机10.0.0.42:8080连接保持活动接受/x请求-使用com。柠檬酸。planReview用户代理Mozilla/5.0(Linux;U;A
我把Spring靴和飞道一起用。我将FlyWay依赖项添加到我的Gradle构建文件中,如下所示: 我还添加了带有初始迁移文件的文件夹。迁移按预期进行。但现在我想使用任务进行清理。但是,当我运行这个时,我得到一个错误,说任务找不到。我用Spring靴还有别的办法吗?
我在日志中收到一些警告,像这样: 在一个独立的tomcat中,我可以创建一个: 如何禁用清单文件的JarScanner(https://tomcat.apache.org/tomcat-8.0-doc/config/jar-scanner.html)在使用Spring Boot的java配置类中。
任何人都可以向我展示或指出一个不使用Spring引导 gradle 插件的Spring引导 gradle 项目。 我正在寻找一个类似springbootstarterwebhelloworld的例子,它不使用gradle插件。 我无法想象插件是一个需求,但搜索示例似乎都依赖于gradle插件,这在我的环境中不是一个选项,不,我也不能切换到maven。 理想情况下,gradle构建将通过添加以下内容
一定有一些方法来使用执行器的endpoint,但我不能电线他们。 我有一个JavaConfig类,如下所示 但此配置在部署过程中引发错误。 没有Spring Boot应用程序,这种布线可以完成吗?
问题内容: 是否可以使用CSS禁用表单字段?我当然知道禁用的属性,但是可以在CSS规则中指定此属性吗?就像是 - 我问的原因是,我有一个应用程序,其中表单字段是自动生成的,并且字段是根据某些规则(以Javascript运行)隐藏/显示的。现在,我想扩展它以支持禁用/启用字段,但是规则的编写方式可以直接操纵表单字段的样式属性。因此,现在我必须扩展规则引擎以更改属性以及表单字段的样式,这在某种程度上似