# wlw-config.xml Configuration File

The wlw-config.xml file allows you to configure runtime parameters of web services, both on the development server and production servers. This file is used by wlwBuild when preparing WebLogic Workshop application EAR files for deployment to a production server.

Note that the values appearing in wlw-config.xml are hardcoded into the deployment EAR and cannot be overridden by other runtime configuration mechanisms. For most cases you should use wlw-runtime-config.xml to configure the runtime information for your Workshop application.

## General Structure

<wlw-config>
<hostname>
<protocol>
<http-port>
<https-port>
<transaction-isolation-level>
<transaction-timeout>
<message-transaction-timeout>
<ejb-concurrency-strategy>
<web-tier-controls>
<class-name>
<component-group URI="" protocol="">
<component URI="" default=boolean>
<service>
<class-name>
<protocol>
<async-dispatch-policy>

## <wlw-config>

The <wlw-config> element is the root element of the wlw-config.xml file.

<wlw-config>
<hostname>
<protocol>
<http-port>
<https-port>
<transaction-isolation-level>
<transaction-timeout>
<message-transaction-timeout>
<ejb-concurrency-strategy>
<web-tier-controls>
<component-group URI="" protocol="">
<service>
<async-dispatch-policy>

### Syntax

    <wlw-config>
    <!--
    Children elements defining the runtime information about the deployed application.
    -->
    </wlw-config>

### Attributes

none.

### Hierarchy

Parents: none.

Children: <hostname>, <protocol>, <http-port>, <https-port>, <transaction-isolation-level>, <transaction-timeout>, <message-transaction-timeout>, <ejb-concurrency-strategy>, <max-beans-in-cache>, <idle-timeout-seconds>, <read-timeout-seconds>, <initial-beans-in-free-pool>, <max-beans-in-free-pool>, <component-group>, <service>.

## <hostname>

The <hostname> element specifies the name of the machine where your application will be deployed. If the value is not set in wlw-config.xml, the value may also be set at runtime in the wlw-runtime-config.xml file, which resides in the server's domain root folder. Also, it may be set at runtime via the server configuration parameter FrontendHost: in the WebLogic Server console navigate to Server --> Protocols --> HTTP --> Advanced Options.

Note: that if you specify the <hostname> in wlw-config.xml, the value will be fixed and it cannot be overridden by other configuration techniques. For this reason it is generally preferable to use the alternative configuation techniques described above.

<wlw-config>
<hostname>

### Syntax

    <hostname> hostnameString </hostname>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <protocol>

The <protocol> element defines the default exposure protocol for your web application. Unless otherwise specified in the <service> element, web resources within the web application will be exposed on the protocol specified here. Possible values are http or https.

<wlw-config>
<protocol>

### Syntax

    <protocol> [HTTP | HTTPS] </protocol>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <http-port>

The <http-port> element specifies which port should be used for HTTP traffic. The range of values is 1 to 65535. If omitted the value is set to 7001.

<wlw-config>
<http-port>

### Syntax

    <http-port> httpPort </http-port>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <https-port>

The <https-port> element specifies which port should be used for https traffic. The range of values is 1 to 65535. If omitted the value is set to 7002.

<wlw-config>
<https-port>

### Syntax

    <https-port> httpsPort </https-port>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <transaction-isolation-level>

The <transaction-isolation-level> tag specifies the transaction isolation level of the EJB that is produced when a web service is compiled. The value of <transaction-isolation-level> will be mapped to the EJB's deployment descriptors at compile time. If no value is specified, then no value is written to the deployment descriptor; this will cause the runtime container to use whichever isolation level the target database (used by the EJB) is configured for. Valid values are

TRANSACTION_READ_COMMITTED

TRANSACTION_READ_UNCOMMITTED

TRANSACTION_REPEATABLE_READ

TRANSACTION_SERIALIZABLE

<wlw-config>
<transaction-isolation-level>

### Syntax

    <transaction-isolation-level>
      [ TRANSACTION_READ_COMMITTED | TRANSACTION_READ_UNCOMMITTED | TRANSACTION_REPEATABLE_READ | TRANSACTION_SERIALIZABLE ]
    </transaction-isolation-level>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <transaction-timeout>

The transaction-timeout element specifies the maximum duration for an EJB's container-initiated transactions. If a transaction lasts longer than transaction-timeout, WebLogic Server rolls back the transaction. Note that this element applies to Workshop web services, since web services are compiled into transactional EJBs. Takes an integer indicating seconds. The default value is 30 seconds.

<wlw-config>
<transaction-timeout>

### Syntax

    <transaction-timeout> timoutSeconds </transaction-timeout>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <message-transaction-timeout>

The message-transaction-timeout element specifies the maximum duration for asynchronous message requests. If a transaction lasts longer than message-transaction-timeout, WebLogic Server rolls back the transaction. Takes an integer indicating seconds. The default value is 30 seconds.

<wlw-config>
<message-transaction-timeout>

### Syntax

    <message-transaction-timeout> timoutSeconds </message-transaction-timeout>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <ejb-concurrency-strategy>

The <ejb-concurrency-strategy> element is used to specify the EJB concurrency strategy of the EJBs that back conversational web services. Valid values are

Exclusive

Database

Optimistic

Default value is Exclusive for non-production builds, and Database for production builds. For clustered environments a value of Database is required. Non-clustered environments may use Exclusive.

WebLogic Workshop requires that method invocations on conversational web services occur serially. Serial access is enforced via record locking on the conversation's database record. When SQL Server or Oracle is used as the persistent store for conversation state, record locking is provided by the SQL statements used internally and <ejb-concurrency-strategy> may be set to Optimistic. When PointBase is used as the conversation store, <ejb-concurrency-strategy> must be Exclusive or race conditions may occur in conversation state access.

Note: if your project contains stateful processes, compilation will fail if you set the <ejb-concurrency-strategy> value to "optimistic". Some examples of stateful processes are: (1) an asynchronous web service or (2) a business process that involves stateful nodes or transactions. For more information on stateful web services and business processes see Default Transactional Behavior in WebLogic Workshop and Building Stateless and Stateful Business Processes

<wlw-config>
<ejb-concurrency-strategy>

### Syntax

    <ejb-concurrency-strategy> [ Exclusive | Database | Optimistic ] </ejb-concurrency-strategy>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

## <web-tier-controls>

Controls code generation for controls referenced from the web tier. Use this element as an optimization to reduce the number of generated EJBs. If the <web-tier-controls> element is empty, then no EJBs will be generated. Note that referenced controls will successfully compile, but will fail at runtime.

<wlw-config>
<web-tier-controls>
<class-name>

### Syntax

    <web-tier-controls>
        <!--
        Child elements listing control classes referenced from the web-tier
        -->
    </web-tier-controls>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: <class-name>.

## <class-name>

Control file class names that are referenced from the web-tier. This element gives the fully qualified class name, including package. No file extension should be included. E.g., <class-name>my.package.name.Foo</class-name>.

<wlw-config>
<web-tier-controls>
<class-name>

### Syntax

    <class-name> JavaClassNameString </class-name>

### Attributes

none.

### Hierarchy

Parents: <web-tier-controls>.

Children: none.

## <component-group>

The <component-group> element is used to group together different versions of a component.

<wlw-config>
<component-group>
<component>

### Syntax

    <component-group>
    <!--
    Child elements listing the different versions of the component
    -->
    </component-group>

### Attributes

Attribute | Description
--- | ---
URI | Required string. Any string indicating part of the URI space.
protocol | Optional string.

### Hierarchy

Parents: <wlw-config>.

Children: <component>.

### Example

     <component-group URI="version/MyWebService.jws">
        <component URI="version/MyWebService3.jws" default="true"/>
        <component URI="version/MyWebService2.jws" />
        <component URI="version/MyWebService1.jws" />
     </component-group>

## <component>

Defines an individual version in a component group.

<wlw-config>
<component-group>
<component>

### Syntax

    <component
        URI="[uriString]"
        default="[boolean]"
    />

### Attributes

Attribute | Description
--- | ---
URI | Required string.
default | Optional boolean.

### Hierarchy

Parents: <component-group>.

Children: none.

### Example

     <component-group URI="version/MyWebService.jws">
        <component URI="version/MyWebService3.jws" default="true"/>
        <component URI="version/MyWebService2.jws" />
        <component URI="version/MyWebService1.jws" />
     </component-group>

## <service>

Defines a web service-protocol mapping. Use the child elements <class-name> and <protocol> elements to specify the transport protocol for individual web resources in a web application.

<wlw-config>
<service>
<class-name>
<protocol>

### Syntax

    <service>
    <!--
    Child elements specifying the transport protocol for individual web resources.
    -->
    </service>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: <class-name>, <protocol>.

### Example

    <service>
        <class-name>HelloWorld</class-name>
        <protocol>http</protocol>
    </service>
    <service>
        <class-name>HelloWorldSecure</class-name>
        <protocol>https</protocol>
    </service>

## <class-name>

The <class-name> element is used in conjunction with the <service> and <protocol> elements to specify the transport protocols of individual web resources. Possible values are the class names of web resources. For example, to specify a web service Foo.jws, use <class-name>Foo</class-name>. Values of the <class-name> element are case sensitive.

<wlw-config>
<service>
<class-name>

### Syntax

    <class-name> JavaClassString </class-name>

### Attributes

none.

### Hierarchy

Parents: <service>.

Children: none.

## <protocol>

Defines an HTML protocol to be used by a given class / web resource. Valid values are either HTTP or HTTPS.

<wlw-config>
<service>
<protocol>

### Syntax

    <protocol> protocolString </protocol>

### Attributes

none.

### Hierarchy

Parents: <service>.

Children: none.

## <async-dispatch-policy>

Provides a mechanism to associate a project’s asynchronous requests with a server-defined dispatch policy. Administrators can then configure separate server resources to handle a project’s synchronous and asynchronous requests. The value provided for this element is used to generate an <async-dispatch-policy> entry in the weblogic-ejb-jar.xml configuration file for the AsyncDispatcher and AsyncErrorDispatcher message-driven beans. Configuration of dispatch policy for synchronous requests is accomplished through elements in the web.xml configuration file.

<wlw-config>
<async-dispatch-policy>

### Syntax

    <async-dispatch-policy> dispatchPolicy </async-dispatch-policy>

### Attributes

none.

### Hierarchy

Parents: <wlw-config>.

Children: none.

### Example

    <async-dispatch-policy>
      weblogic.wlw.async.dispatch
    </async-dispatch-policy>

This fragment in wlw-config.xml will result in the following entry being generated into the weblogic-ejb-jar.xml configuration file for the project’s AysncDispatcher and AsyncErrorHandler message-driven beans:

    <dispatch-policy>weblogic.wlw.async.dispatch</dispatch-policy>

Related Topics

wlwBuild Command

wlw-runtime-config.xml Configuration file