anchor.diff:                          </outputDirectory>
                       </artifactItem>
   
  +                    <!-- Download and unpack Hibernate Search modules -->
  +                    <artifactItem>
  +                        <groupId>org.hibernate</groupId>
  +                        <artifactId>hibernate-search-modules</artifactId>
  +                        <version>{hibernate-search-version}</version>
  +                        <classifier>{hibernate-wildfly-classifier}</classifier>
  +                        <type>zip</type>
  +                        <overWrite>false</overWrite>
  +                        <outputDirectory>
  +                            ${project.build.directory}/wildfly-{wildfly-version}/modules
  +                        </outputDirectory>
  +                    </artifactItem>
  +
                       <!-- Download and unpack Hibernate OGM modules -->
                       <artifactItem>
                           <groupId>org.hibernate.ogm</groupId>
  
positive.code: 
  WildFly will by default attempt to guess which Persistence Provider you need by having a look at the `provider` section of the `persistence.xml`.
  
  ==== Enabling both the Hibernate Search and Hibernate OGM modules
  
  A compatible Hibernate Search module is included in WildFly 10, and Hibernate Search is activated automatically if you're indexing any entity.
  
  When using WildFly several of the technologies it includes are automatically enabled.
  For example Hibernate ORM is made available to your applications if your `persistence.xml` defines a persistence unit using Hibernate as persistence provider
  (or is not specifying any provider, as Hibernate is the default one).
  
  Similarly, Hibernate Search is automatically activated and made available on the user's application classpath if and when the application server detects the need for it.
  This is the default behaviour, but you are in control and can override this all; see the https://docs.jboss.org/author/display/WFLY10/JPA+Reference+Guide[WildFly JPA Reference Guide]
  for a full list of properties you can explicitly set.
  Among these you fill find properties to control and override which modules are activated.
  
  Hibernate OGM however is currently not included in WildFly, so you have to enable it explicitly.
  
  Optionally you could download a different version of the Hibernate Search modules, provided it is compatible with the Hibernate OGM version you plan to use.
  For example you might want to download a more recent micro version of what is included in WildFly 10 at the time of publishing this documentation.
  
  The Hibernate Search documentation explains the details of downloading and deploying a custom version:
  https://docs.jboss.org/hibernate/search/{hibernate-search-major-minor-version}/reference/en-US/html_single/#_update_and_activate_latest_hibernate_search_version_in_wildfly[Update and activate latest Hibernate Search version in WildFly].
  
  This approach might require you to make changes to the XML definitions of the Hibernate OGM modules to change the references to the Hibernate Search slot
  to the slot version that you plan to use.
  
  ==== Using the Hibernate OGM modules with Infinispan
  
  The Infinispan project also provides custom modules for WildFly 10.
  
negative.code: Dependencies: org.hibernate.ogm:{hibernate-ogm-module-slot} services, org.hibernate.ogm.<%DATASTORE%>:{hibernate-ogm-module-slot} services
  ----
  
  Include dependencies using jboss-deployment-structure.xml::
  This is a JBoss-specific descriptor.
  Add a `WEB-INF/jboss-deployment-structure.xml` in your archive with the following content (replace _<%DATASTORE%>_ with the right value for your chosen datastore):
  
  