Maven Bill Of Materials Artifact
The Payara Platform consists of many artifacts and it depends on lots of APIs as well as their implementations. Having matching versions of these dependencies will prevent classloading issues at runtime. To this effect, the Payara Platform’s Bill Of Materials (BOM) artifact collects all of these versions for the following categories:
-
Payara Platform Distribution artifacts
-
Payara Platform Client libraries
-
Jakarta EE, Eclipse Microprofile and OSGi APIs
-
Arquillian Container Adapters
-
Implementations and libraries included in Payara Server (see the list below)
Quick Start
To make use of the BOM, you need to list the artifact in dependencyManagement
section of your project in scope import
. Some of the artifacts are Payara-specific patch versions which are available in our repository payara-artifacts.
Add following snippet to your Maven project:
<dependencyManagement>
<dependencies>
<dependency>
<groupId>fish.payara.api</groupId>
<artifactId>payara-bom</artifactId>
<version>6.2022.1.alpha4</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<!-- Some of the referenced APIs in POM are Payara's patched versions.
These are published in following repo: -->
<repositories>
<repository>
<id>payara-patched-externals</id>
<name>Payara Patched Externals</name>
<url>https://nexus.payara.fish/repository/payara-artifacts/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
An example application utilizing the BOM can be seen in repository Payara Examples/. See the ecosystem/payara-bom/bom-import/ subproject for more details.
BOM Contents
The following is a summary of all dependencies included in the BOM, grouped by category.
Payara Platform Distributions
Distribution artifacts do not define a Maven scope and are therefore imported in compile
scope.
Artifact | Example usage | Note |
---|---|---|
Payara Server |
|
Also available are |
Payara Micro |
|
|
Payara Embedded |
|
Also available |
EJB HTTP Client |
|
|
Appclient |
|
|
Payara Public API |
|
Standard APIs
Standard APIs are defined in provided
scope, as they already include classes that are present in the server’s runtime.
Artifact | Example usage | Note |
---|---|---|
Jakarta EE |
|
Also available |
Eclipse Microprofile |
|
Individual APIs are also declared. |
OSGi |
|
Also available are |
Test Frameworks and Other Tools
Arquillian is the recommended way to run integration tests written for Payara Server. Payara Platform provides multiple connectors fitting the deployment scenarios. These artifacts are declared in scope test
.
Payara Server includes the H2 database, so their matching versions are also declared, but in their default scope.
Artifact | Example usage |
---|---|
Arquillian container - Remote |
|
Arquillian container - Embedded |
|
Arquillian container - Managed |
|
Arquillian container - Payara Micro |
|
H2 Database |
|
Libraries and API implementations
This is a non-exhaustive list of dependencies. By default all are declared in their respective default scopes, but it is more correct to use them with scope provided
if they are already present in the server’s internal modules.
Artifact | Example usage | Note |
---|---|---|
Jersey |
|
Example: JAX-RS clients in tests. All artifacts of the Jersey BOM are imported. |
Hibernate Validator |
|
|
EclipseLink - JPA Metamodel generator |
|
The only dependency that is |
EclipseLink |
|
|
Hazelcast |
|
The |
Jackson |
|
All artifacts of the Jackson BOM are imported. |
Yasson |
|
|
Tyrus |
|