com.atlassian.confluence.content.render.xhtml.migration.exceptions.UnknownMacroMigrationException: The macro 'next_previous_link3' is unknown.

Configuring bps.xml

Users can change the default BPEL-specific configurations by editing the bps.xml file using the information given below.

File Details

  • File Name: bps.xml
  • Location: $PRODUCT_HOME\repository\conf
  • Purpose: To configure important aspects of the business process server such as data sources, the threads, BPEL extensions, process cleanup scheduling etc. Using ths file, you can change the default configurations according to your specific business requirements.

XML Elements

Given below are the main XML elements of bps.xml.

<tns:WSO2BPS>
     <tns:DataBaseConfig>
           <tns:DataSource>
                  <tns:JNDI>
           <tns:ProcessDehydration>
                  <tns:MaxAge>
           <tns:TransactionFactory>
           <tns:EventListeners>
                  <tns:listener>
           <tns:MexInterceptors>
                  <tns:interceptor>
           <tns:ExtensionBundles>
                  <tns:runtimes>
                        <tns:runtime>
                  <tns:filters>
                        <tns:filter>
           <tns:OpenJPAConfig>
                  <tns:property>
           <tns:MexTimeOut>
           <tns:ExternalServiceTimeOut>
           <tns:MultithreadedHttpConnectionManagerConfig>
                  <tns:maxConnectionsPerHost>
                  <tns:maxTotalConnections>
           <tns:Schedules>
                  <tns:Schedule>
                        <tns:cleanup>
                              <tns:filter>
           <tns:SyncWithRegistry>
           <tns:InMemoryInstanceTimeToLive>
           <tns:ODESchedulerThreadPoolSize>
		   <tns:UseDistributedLock>



<tns:WSO2BPS>

XML Syntax

<tns:WSO2BPS>

Description

The root element of bps.xml which does not have attributes defined. Each of its child elements and their configurations are described below.

Mandatory/OptionalMandatory

^ Back to Top


<tns:DataBaseConfig>

XML Syntax<tns:DataBaseConfig>
Description

Using the DataBaseConfig element you can configure the data sources used by the business process server for storing process/instance data. Check each of its sub elements for details of each configuration.

Mandatory/Optional 

^ Back to Top


<tns:DataSource>

XML Syntax<tns:DataSource name="">
         <tns:JNDI contextFactory="" providerURL=""/>
</tns:DataSource>
Description

Database Configuration for WSO2 BPS BPEL Engine's Persistence Storage

Mandatory/OptionalOptional
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'name' attribute of <tns:DataSource> elementShould have the data source name defined for the business process server.

This name is typically specified in <BPS_HOME>/repository/conf/datasources.properties file. 

stringnonenonemandatoryN/A
'contextFactory' attribute is of the <tns:JNDI> sub elementDefines the JNDI context factory of the Data Source.stringnonenonemandatoryN/A
'providerURL' attribute is of the <tns:JNDI> sub elementDefines the JNDI provider url.stringnonenonemandatoryN/A
Sample Implementations
<tns:DataSource name="bpsds">
      <tns:JNDI contextFactory="com.sun.jndi.rmi.registry.RegistryContextFactory" providerURL="rmi://localhost:2199"/>
   </tns:DataSource>

^ Back to Top


<tns:ProcessDehydration>

XML Syntax

<tns:ProcessDehydration maxCount="" value="">

        <tns:MaxAge value="0"/>

DescriptionOne technique to reduce memory utilization of BPS engine is process hydration and dehydration.
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'maxCount' attribute of the <tns:ProcessDehydration> elementset the maximum deployed process count can exist in memory at a particular timeintnonenonemandatory 
'value' attribute of the <tns:ProcessDehydration> elementenable or disable dehydration of processes.booleannone
  • True:
  • False:
mandatory 
'value' attribute of the <tns:MaxAge> elementset the maximum age of a process before it is dehydrated. should be declared in milliseconds.intnonenonemandatory 
Sample Implementations
<tns:ProcessDehydration maxCount="100" value="true">
 <tns:MaxAgevalue="300000"/>
</tns:ProcessDehydration>

^ Back to Top


<tns:TransactionFactory>

XML Syntax<tns:TransactionFactory class=""/>
Descriptionspecify an external or custom transaction factory class to take care of transactions
Mandatory/Optionaloptional
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
classname of the classstringnonenonemandatory 
Sample Implementations
<tns:TransactionFactory class="class name"/>

^ Back to Top


<tns:EventListeners>

XML Syntax

<tns:EventListeners>
        <tns:listener class=""/>
</tns:EventListeners> 

DescriptionBPS lets you register your own event listeners to analyse all produced events and do whatever you want to do with them. To create a listener, you just need to implement the org.apache.ode.bpel.iapi.BpelEventListener interface.
Mandatory/OptionalOptional
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'class' attribute of the <tns:listener> elementname of the custom event listener classstringnonenonemandatory 
Sample Implementations
<tns:EventListeners>
 <tns:listenerclass="org.wso2.bps.samples.eventlistener.CustomEventListener"/>
</tns:EventListeners>

^ Back to Top


<tns:MexInterceptors>

XML Syntax<tns:MexInterceptors>
        <tns:interceptor class=""/>
DescriptionMessage Exchange Interceptors can be used to pull out data as well as to manipulate them by enabling interception of parntner/server invocations. MEX interceptors can be used in four different situations.
  • When the BPEL server is invoked, before any attempt to route the message exchange to a process.
  • When the BPEL server is invoked, after the message exchange has been routed to the process.
  • When the BPEL server is invoked, after the message exchange has been routed to the process and it has been determined that a new instance needs to be created.
  • When a partner link is invoked.
Mandatory/OptionalOptional
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'class' attribute of the <tns:interceptor> elementname of the class.You need to implement MessageExchangeInterceptor interface to implement a custom message exchange interceptorstringnonenonemandatory 
Sample Implementations
<tns:MexInterceptors>
   <tns:interceptor class="class name"/>
</tns:MexInterceptors>

^ Back to Top


<tns:ExtensionBundles>

XML Syntax

<tns:ExtensionBundles>
<tns:runtimes>
<tns:runtime class="org.wso2.bps.SampleExtensionRuntime"/>
</tns:runtimes>
<tns:filters>
<tns:filter class="org.wso2.bps.SampleCorrelationFilter"/>
</tns:filters>
</tns:ExtensionBundles>

Description<specify the purpose of this element> For configuration details and samples, refer to each of its sub elements.
Mandatory/Optional optional

^ Back to Top


<tns:runtimes>

XML Syntax <tns:runtimes>
<tns:runtime class=""/>
</tns:runtimes>
Description 
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'class' attribute of the <tns:runtime> element      
Sample Implementations
<tns:runtimes>
  <tns:runtime class="org.wso2.bps.SampleExtensionRuntime"/>
</tns:runtimes>

^ Back to Top


<tns:filters>

XML Syntax <tns:filters>
<tns:filter class=""/>
</tns:filters>
Description 
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'class' attribute of the <tns:runtime> element      
Sample Implementations
<tns:filters>
 <tns:filter class="org.wso2.bps.SampleCorrelationFilter"/>
</tns:filters>

^ Back to Top


<tns:OpenJPAConfig>

XML Syntax<tns:OpenJPAConfig>
        <tns:property name="" value=""/>
Description 
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'name' attribute of the <tns:property> element      
'value' attribute of the <tns:property> element   
  • True:
  • False:
  
Sample Implementations
 

^ Back to Top


<tns:MexTimeOut>

XML Syntax<tns:MexTimeOut value=""/>
DescriptionMessage exchange timeout
Mandatory/Optional optional
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
valueMessage exchange timeout value in millisecondsint120000nonemandatory 
Sample Implementations
<tns:MexTimeOut value="120000"/>

^ Back to Top


<tns:ExternalServiceTimeOut>

XML Syntax

<tns:ExternalServiceTimeOut value=""/>

DescriptionExternal Service invocation timeout
Mandatory/Optionalmandatory

 

List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
valueExternal Service invocation timeout valueint60000nonemandatory 
Sample Implementations
<tns:ExternalServiceTimeOut value="60000"/>

^ Back to Top


<tns:MultithreadedHttpConnectionManagerConfig>

XML Syntax

<tns:MultithreadedHttpConnectionManagerConfig>
        <tns:maxConnectionsPerHost value=""/>
        <tns:maxTotalConnections value=""/>

Description 
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'value' attribute of the <tns:maxConnectionsPerHost> element      
'value' attribute of the <tns:maxTotalConnections> element      
Sample Implementations

 

^ Back to Top


<tns:Schedules>

XML Syntax

<tns:Schedules>
        <tns:Schedule when="">
            <tns:cleanup>
                <tns:filter></tns:filter>
            </tns:cleanup>
        </tns:Schedule>
</tns:Schedules>

DescriptionProcess instance cleanup feature in WSO2 Business Process Server allows to configure periodic process instance cleanup tasks based on various process instance properties to remove process instance data from WSO2 BPS persistence storage. Refer - http://www.quartz-scheduler.org/docs/tutorials/crontrigger.html to declare cron expression formats.
Mandatory/Optional 
List of Attributes
Attribute NameDescriptionTypeDefault ValueFixed ValuesMandatory/OptionalNotes
'when' attribute of the <tns:Schedule> element      
Sample Implementations

1. Following sample configuration schedules a cleanup task at 5:11 PM every day to clean completed process instances.

<tns:Schedules>
    <tns:Schedule when="0 11 17 * * ?">
        <tns:cleanup>
             <tns:filter><![CDATA[status=completed]]></tns:filter>
        </tns:cleanup>
    </tns:Schedule>
</tns:Schedules>

^ Back to Top


<tns:SyncWithRegistry>

XML Syntax

<tns:SyncWithRegistry>

Description

By default all the BPEL packages are read from the file system. If you need to Synchronize the file system BPEL repository, set the <tns:SyncWithRegistry> element to true. This checks the timestamp of the BPEL packages in the file system against the BPEL packages in the registry. If they do not match then the BPEL package in the registry is copied to the file system.

Mandatory/Optional 
Sample Implementations
 

^ Back to Top


<tns:InMemoryInstanceTimeToLive>

XML Syntax

<tns:InMemoryInstanceTimeToLive>

Description

The property 'InMemoryInstanceTimeToLive' can be used to limit the time-to-live of in-memory instances. This setting is useful to avoid memory leaks related to in-memory processes that may get 'stuck' during execution and never terminate (time should be specified in milliseconds).

Mandatory/Optional 
Sample Implementations
 <tns:InMemoryInstanceTimeToLive>600000</tns:InMemoryInstanceTimeToLive>

^ Back to Top


<tns:ODESchedulerThreadPoolSize>

XML Syntax

<tns:ODESchedulerThreadPoolSize>0</tns:ODESchedulerThreadPoolSize>

Description

Configure this property to control the number of threads in the ode scheduler thread pool. This value should always be smaller than the maximum number of db connections configured for the bps persistance store data source. If you are using both human tasks and bpel with b4p extension activity configure this values to be less than half of maxActive database connections number.

ThreadPoolSize < maxActive Connections => Only using BPEL processes

ThreadPoolSize < (maxActive Connections) / 2 => Using both BPEL processes and Human Tasks

Always try to provide as much database connections as possible to BPS.

Mandatory/Optional Mandatory

 

Sample Implementations
 <tns:ODESchedulerThreadPoolSize>50</tns:ODESchedulerThreadPoolSize>

^ Back to Top


<tns:UseDistributedLock

XML Syntax

<tns:UseDistributedLock>true</tns:UseDistributedLock>

Description

This property is used to enable hazelcast based synchronization mechanism to prevent instance state from being concurrently modified from multiple bps nodes.

Mandatory/Optional Mandatory if clustering is enabled

 

Sample Implementations
<tns:UseDistributedLock>true</tns:UseDistributedLock>
com.atlassian.confluence.content.render.xhtml.migration.exceptions.UnknownMacroMigrationException: The macro 'next_previous_links2' is unknown.