AWS Lambda Java: Lambda was not able to unzip the file

前端 未结 3 424
耶瑟儿~
耶瑟儿~ 2021-01-21 13:05

I\'m trying to use Java with AWS Lambda. I created a jar file with all dependencies (using maven-assembly-plugin). Upon uploading, I cannot call the lambda. I receive the error

3条回答
  •  后悔当初
    2021-01-21 13:25

    I ran into this because a JAR packed with the Shade plugin generated both the file and directory META-INF\version\9.

    By excluding these files the JAR could be run again. The following is the configuration section for the maven-shade-plugin.

                    
          
            
              *:*
              
                META-INF/*.SF
                META-INF/*.DSA
                META-INF/*.RSA
                META-INF/versions/9
                META-INF/versions/9/*
              
            
          
        
    

提交回复
热议问题