Troubleshooting

If everything works fine, we don't have to worry about troubleshooting. However, most of the time this is not the case. A Maven build could fail for many reasons—some are under your control, while others are beyond your control. Knowing proper troubleshooting tips helps you pinpoint the exact problem. The following sections list out some of the commonly used troubleshooting tips. We will expand the list as we proceed in this book.

Enabling Maven debug-level logs

Once Maven debug level logging is enabled, it will print all the actions it takes during the build process. To enable debug level logging, use the following command:

$ mvn clean install –X

Building dependency tree

If you find any issues with any dependencies in your Maven ...

Get Mastering Apache Maven 3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.