Search code examples
mavenjbossdependencieswildflyjava-ee-7

Is there a link between org.wildfly.bom and the version of the wildfly server used?


I'm currently developing some applications and I'm using wildfly 9.0.2.Final as the application server. Currently I'm using bom version 8.2.2.Final for the following artifacts:

  • jboss-javaee-7.0-with-tools
  • jboss-javaee-7.0-with-hibernate
  • jboss-javaee-7.0-with-security

I've started using these versions while following a tutorial. However I've seen that now wildfly 10 is out and probably some other dependencies also have dependencies. Maybe in the future javaee-8.0 will be available.

Is there some documentation on what the different artifacts include and maybe what should be kept in mind when upgrading the parent bom version?


Solution

  • Your BOM version should match your deployment Wildfly version.

    Assuming you use provided scope for dependencies that are provided by Wildfly, you want to ensure you're using the correct versions. If you use a wrong version, your application might not work as expected or even fail to start, because some API might be deprecated/removed, or because some features might not be available yet.


    Side note: Wildfly BOMs lack some dependencies, so we're using parent as BOM:

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.wildfly</groupId>
                <artifactId>wildfly-parent</artifactId>
                <version>9.0.2.Final</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>