I have a spring boot app (which has a parent pom) and generally manages plenty of dependencies in terms of their version.
If I add this to my pom.xml
<dependency>
<groupId>com.amazonaws</groupId>
<artifactId>aws-java-sdk-dynamodb</artifactId>
</dependency>
And list the dependencies it indicates that version is not the latest:
./mvnw dependency:list | grep dynamo
[INFO] com.amazonaws:aws-java-sdk-dynamodb:jar:1.11.125:compile
At time of writing the latest version is 1.11.838
, my current version is many months "out of date".
My IDE usually does a good job of showing me when a dependency is being "managed" e.g. by a parent pom. But in this case it doesn't indicate that this is the case.
My thinking is perhaps a transitive dependency is influencing this, but I'd like a more empirical way to find out.
Of course I could just add an explicit version element to the dependency or add an explicit dependency management element for this dependency. But my question is more academic in nature, I want to understand why maven determines that this is the right version to resolve.
Ideally what I'm trying to learn is what tooling or processes exist to "debug" this, e.g. a particular maven plugin which might help show how a version was resolved.
The result of: mvn dependency:tree | grep -i dynamo | wc -l
is 1
. Which (I think) indicates that it's not appearing multiple times in transitive dependencies.