Class Configuration

java.lang.Object
org.jboss.as.jpa.config.Configuration

public class Configuration extends Object
configuration properties that may appear in persistence.xml
Author:
Scott Marlow
  • Field Details

    • PROVIDER_MODULE

      public static final String PROVIDER_MODULE
      name of the AS module that contains the persistence provider
      See Also:
    • PROVIDER_MODULE_HIBERNATE

      public static final String PROVIDER_MODULE_HIBERNATE
      Hibernate main module (default) persistence provider
      See Also:
    • PROVIDER_MODULE_HIBERNATE4_1

      public static final String PROVIDER_MODULE_HIBERNATE4_1
      Hibernate 4.1.x persistence provider, note that Hibernate 4.1.x is expected to be in the 4.1 slot
      See Also:
    • PROVIDER_MODULE_HIBERNATE_OGM

      public static final String PROVIDER_MODULE_HIBERNATE_OGM
      Hibernate OGM persistence provider
      See Also:
    • PROVIDER_MODULE_DATANUCLEUS

      public static final String PROVIDER_MODULE_DATANUCLEUS
      See Also:
    • PROVIDER_MODULE_DATANUCLEUS_GAE

      public static final String PROVIDER_MODULE_DATANUCLEUS_GAE
      See Also:
    • PROVIDER_MODULE_OPENJPA

      public static final String PROVIDER_MODULE_OPENJPA
      See Also:
    • PROVIDER_MODULE_DEFAULT

      public static final String PROVIDER_MODULE_DEFAULT
      default if no PROVIDER_MODULE is specified.
      See Also:
    • PROVIDER_CLASS_HIBERNATE4_1

      public static final String PROVIDER_CLASS_HIBERNATE4_1
      Hibernate 4.1.x persistence provider class
      See Also:
    • PROVIDER_CLASS_HIBERNATE

      public static final String PROVIDER_CLASS_HIBERNATE
      Hibernate 4.3.x persistence provider class
      See Also:
    • PROVIDER_CLASS_HIBERNATE_OGM

      public static final String PROVIDER_CLASS_HIBERNATE_OGM
      Hibernate OGM persistence provider class
      See Also:
    • PROVIDER_CLASS_DATANUCLEUS

      public static final String PROVIDER_CLASS_DATANUCLEUS
      DataNucleus provider
      See Also:
    • PROVIDER_CLASS_DATANUCLEUS_GAE

      public static final String PROVIDER_CLASS_DATANUCLEUS_GAE
      DataNucleus provider GAE
      See Also:
    • PROVIDER_CLASS_OPENJPA

      public static final String PROVIDER_CLASS_OPENJPA
      See Also:
    • PROVIDER_CLASS_DEFAULT

      public static final String PROVIDER_CLASS_DEFAULT
      default provider class
      See Also:
    • PROVIDER_MODULE_APPLICATION_SUPPLIED

      public static final String PROVIDER_MODULE_APPLICATION_SUPPLIED
      if the PROVIDER_MODULE is this value, it is expected that the application has its own provider in the deployment.
      See Also:
    • ADAPTER_MODULE_OPENJPA

      public static final String ADAPTER_MODULE_OPENJPA
      See Also:
    • ADAPTER_MODULE

      public static final String ADAPTER_MODULE
      name of the AS module that contains the persistence provider adapter
      See Also:
    • JPA_CONTAINER_MANAGED

      public static final String JPA_CONTAINER_MANAGED
      defaults to true, if changed to false (in the persistence.xml), the Jakarta Persistence container will not start the persistence unit service.
      See Also:
    • JPA_DEFAULT_PERSISTENCE_UNIT

      public static final String JPA_DEFAULT_PERSISTENCE_UNIT
      See Also:
    • JPA_CONTAINER_CLASS_TRANSFORMER

      public static final String JPA_CONTAINER_CLASS_TRANSFORMER
      defaults to true, if false, persistence unit will not support jakarta.persistence.spi.ClassTransformer Interface which means no application class rewriting
      See Also:
    • JPA_ALLOW_TWO_PHASE_BOOTSTRAP

      public static final String JPA_ALLOW_TWO_PHASE_BOOTSTRAP
      set to false to force a single phase persistence unit bootstrap to be used (default is true which uses two phases to start the persistence unit).
      See Also:
    • ADAPTER_CLASS

      public static final String ADAPTER_CLASS
      name of the persistence provider adapter class
      See Also:
    • ALLOWJOINEDUNSYNCPC

      public static final String ALLOWJOINEDUNSYNCPC
      See Also:
    • SKIPMIXEDSYNCTYPECHECKING

      public static final String SKIPMIXEDSYNCTYPECHECKING
      See Also:
    • HIBERNATE_SEARCH_MODULE

      public static final String HIBERNATE_SEARCH_MODULE
      name of the Hibernate Search module name configuration setting in persistence unit definition
      See Also:
    • HIBERNATE_SEARCH_INTEGRATOR_ADAPTOR_MODULE_NAME

      public static final String HIBERNATE_SEARCH_INTEGRATOR_ADAPTOR_MODULE_NAME
      name of the Hibernate Search integrator adaptor module
      See Also:
    • HIBERNATE_SEARCH_MODULE_MAPPER_ORM

      public static final String HIBERNATE_SEARCH_MODULE_MAPPER_ORM
      name of the Hibernate Search module providing the ORM mapper
      See Also:
    • HIBERNATE_SEARCH_MODULE_MAPPER_ORM_OUTBOXPOLLING

      public static final String HIBERNATE_SEARCH_MODULE_MAPPER_ORM_OUTBOXPOLLING
      name of the Hibernate Search module providing the outbox-polling coordination strategy
      See Also:
    • HIBERNATE_SEARCH_MODULE_BACKEND_LUCENE

      public static final String HIBERNATE_SEARCH_MODULE_BACKEND_LUCENE
      name of the Hibernate Search module providing the Lucene backend
      See Also:
    • HIBERNATE_SEARCH_MODULE_BACKEND_ELASTICSEARCH

      public static final String HIBERNATE_SEARCH_MODULE_BACKEND_ELASTICSEARCH
      name of the Hibernate Search module providing the Elasticsearch backend
      See Also:
    • HIBERNATE_SEARCH_BACKEND_TYPE

      public static final String HIBERNATE_SEARCH_BACKEND_TYPE
      name of the Hibernate Search configuration property allowing to set the backend type
      See Also:
    • HIBERNATE_SEARCH_BACKEND_TYPE_VALUE_LUCENE

      public static final String HIBERNATE_SEARCH_BACKEND_TYPE_VALUE_LUCENE
      The value of the HIBERNATE_SEARCH_BACKEND_TYPE property that identifies the use of a Lucene backend.
      See Also:
    • HIBERNATE_SEARCH_BACKEND_TYPE_VALUE_ELASTICSEARCH

      public static final String HIBERNATE_SEARCH_BACKEND_TYPE_VALUE_ELASTICSEARCH
      The value of the HIBERNATE_SEARCH_BACKEND_TYPE property that identifies the use of an Elasticsearch backend.
      See Also:
    • HIBERNATE_SEARCH_COORDINATION_STRATEGY

      public static final String HIBERNATE_SEARCH_COORDINATION_STRATEGY
      Name of the Hibernate Search configuration property allowing to set the coordination strategy
      See Also:
    • HIBERNATE_SEARCH_COORDINATION_STRATEGY_VALUE_OUTBOX_POLLING

      public static final String HIBERNATE_SEARCH_COORDINATION_STRATEGY_VALUE_OUTBOX_POLLING
      The value of the HIBERNATE_SEARCH_COORDINATION_STRATEGY property that identifies the use of an Elasticsearch backend.
      See Also:
  • Constructor Details

    • Configuration

      public Configuration()
  • Method Details

    • getProviderModuleNameFromProviderClassName

      public static String getProviderModuleNameFromProviderClassName(String providerClassName)
      Get the provider module name for the specified provider class.
      Parameters:
      providerClassName - the PU class name
      Returns:
      provider module name or null if not known
    • needClassFileTransformer

      public static boolean needClassFileTransformer(PersistenceUnitMetadata pu)
      Determine if class file transformer is needed for the specified persistence unit for all persistence providers, the transformer is assumed to be needed unless the application indicates otherwise.
      Parameters:
      pu - the PU
      Returns:
      true if class file transformer support is needed for pu
    • getProviderAdapterModuleNameFromProviderClassName

      public static String getProviderAdapterModuleNameFromProviderClassName(String providerClassName)
    • getDefaultProviderModuleName

      public static String getDefaultProviderModuleName()
    • allowTwoPhaseBootstrap

      public static boolean allowTwoPhaseBootstrap(PersistenceUnitMetadata pu)
      Determine if two phase persistence unit start is allowed
      Parameters:
      pu -
      Returns:
    • allowApplicationDefinedDatasource

      public static boolean allowApplicationDefinedDatasource(PersistenceUnitMetadata pu)
      Determine if persistence unit can use application defined DataSource (e.g. DataSourceDefinition or resource ref).
      Parameters:
      pu -
      Returns:
      true if application defined DataSource can be used, false (default) if not.
    • allowDefaultDataSourceUse

      public static boolean allowDefaultDataSourceUse(PersistenceUnitMetadata pu)
      Determine if the default data-source should be used
      Parameters:
      pu -
      Returns:
      true if the default data-source should be used
    • deferEntityDetachUntilClose

      public static boolean deferEntityDetachUntilClose(Map<String,Object> properties)
      Return true if detaching of managed entities should be deferred until the entity manager is closed. Note: only applies to transaction scoped entity managers used without an active Jakarta Transactions transaction.
      Parameters:
      properties -
      Returns:
    • skipQueryDetach

      public static boolean skipQueryDetach(Map<String,Object> properties)
      Return true if detaching of query results (entities) should be deferred until the entity manager is closed. Note: only applies to transaction scoped entity managers used without an active Jakarta Transactions transaction.
      Parameters:
      properties -
      Returns:
    • getScopedPersistenceUnitName

      public static String getScopedPersistenceUnitName(PersistenceUnitMetadata pu)
    • skipMixedSynchronizationTypeCheck

      public static boolean skipMixedSynchronizationTypeCheck(jakarta.persistence.EntityManagerFactory emf, Map targetEntityManagerProperties)
      Allow the mixed synchronization checking to be skipped for backward compatibility with WildFly 10.1.0
      Parameters:
      emf -
      targetEntityManagerProperties -
      Returns:
    • allowJoinedUnsyncPersistenceContext

      public static boolean allowJoinedUnsyncPersistenceContext(jakarta.persistence.EntityManagerFactory emf, Map targetEntityManagerProperties)
      Allow an unsynchronized persistence context that is joined to the transaction, be treated the same as a synchronized persistence context, with respect to the checking for mixed unsync/sync types.
      Parameters:
      emf -
      targetEntityManagerProperties -
      Returns: