'What are the BOOT-INF and META-INF directories in a Spring-Boot JAR?

When I open a jar package, there shows the BOOT-INF and META-INF folders, what's the function of them?

's th



Solution 1:[1]

The META-INF folder is the home for the MANIFEST.MF file. This file contains meta data about the contents of the JAR. For example, there is an entry called Main-Class that specifies the name of the Java class with the static main() for executable JAR files.

for more details

BOOT-INF : Spring Boot applications load from the BOOT-INF folder. Therefore the application classes must be placed in a nested BOOT-INF/classes directory. Dependencies should be placed in a nested BOOT-INF/lib directory.

more about Spring Boot packaging

Solution 2:[2]

This is a single jar Spring Boot application.

In addition to the META-INF files for the loader (as in any other jar file) the application itself is placed under BOOT-INF.

Note that such a jar cannot be used as a traditional jar any more.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Janos Vinceller
Solution 2