有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java Gradle归档包含超过65535个条目

我正在集成hadoop2。5.0用于运行mapreduce作业和spring-boot-1.2.7发行版,并在包含此版本时出错
1) 存档包含超过65535个条目

我的gradle jar依赖

jar{
from configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }

2) 在罐子里放zip64

  jar{
    zip64=true
    from configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }

我的文件无效或损坏
3) 在添加shadowJar时,我遇到了一个错误

shadowJar{
   zip64=true
}

无法读取组织上的字节。springframework。靴子加载器。ExecutableArchiveLauncher
我应该如何从所有依赖项中创建一个罐子


共 (1) 个答案

  1. # 1 楼答案

    这个问题已经在评论中得到了回答,以下是提问者自己提供的相关文章:

    Thanks a lot solved the problem using http://stackoverflow.com/questions/10405970/… and http://github.com/spring-projects/spring-boot/issues/1310 I added hbase and hadoop as provided.I removed zip64 from jar{}

    快速浏览一下SO答案的关键部分是:

    currently the best solution is to declare your own provided configuration, that will included compile-only dependencies and add to to your compile classpath

    github似乎与此重叠,再加上关键细节:

    I added the following in my jar task of all the sub projects and got my jars spared. bootRepackage.enabled = false