Maven build is packaging unneeded jars into our application

Solution Verified - Updated -

Issue

  • We're building our JBoss application through maven. It looks like all dependencies are being included in the application though. We don't want that as some dependencies at run time will be provided by JDK or JBoss layer libraries. How can we prevent a dependency from being bundled in the application by maven?

Environment

  • Maven

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content