How does JVM deal with duplicate JARs of different versions

后端 未结 2 1476
别跟我提以往
别跟我提以往 2021-01-17 22:42

When there were duplicate JARs with different versions, the behavior was very inconsistent. Does anyone know how the JVM deals with duplicates?

2条回答
  •  有刺的猬
    2021-01-17 23:25

    The classloader searches the classpath in order, and uses the first matching class it finds.

提交回复
热议问题