I add sprig dependency to my maven pom.
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring</artifactId>
<version>2.5.6.SEC01</version>
</dependency>
I "run" maven to download all dependencies. In spring pom file (from local .m2 repository) I can see many dependencies (about 20)
.....
</开发者_开发问答organization>
<dependencies>
<!-- External Dependencies -->
<dependency>
<groupId>aopalliance</groupId>
<artifactId>aopalliance</artifactId>
<version>1.0</version>
<optional>true</optional>
</dependency>
<dependency>
<groupId>asm</groupId>
<artifactId>asm</artifactId>
<version>2.2.3</version>
<optional>true</optional>
</dependency>
.....
But when I collect all libs by Assebly plugin or list all of them using "dependencies" task, I see that maven "use" only spring and commons-lang. No any others.
I just want to know whats happens or what I am doing wrong? Why maven do not "add" all dependencies from spring pom?
These dependencies are marked as optional (<optional>true</optional>
) in the pom. Hence they do not get included.
精彩评论