Modifying the configuration of an OSGi composition unit

You can modify the configuration information for a composition unit that contains an enterprise OSGi application. An OSGi composition unit consists of an EBA asset, (optionally) one or more composite bundle extensions, and configuration information for running the asset and composite bundle extensions in a business-level application. The configuration information can include HTTP session management, context roots, virtual hosts, security roles, run-as roles, and web application or Blueprint resource reference bindings for your OSGi application.

Before you begin

You can modify the configuration of an OSGi composition unit by using the administrative console as described in this topic, or by using wsadmin commands as described in Modifying the configuration of an OSGi composition unit using wsadmin commands.

About this task

An OSGi composition unit consists of an EBA asset, (optionally) one or more composite bundle extensions, and some or all of the following configuration information:
  • Mappings from the composition unit to a target application server, web server or cluster.
  • Configuration of the application's session manager, context roots or virtual hosts.
  • Bindings to any associated web applications or blueprint resource references.
  • Mappings from security roles to particular users or groups.

You first specify the configuration of an EBA asset or composite bundle extension when you add it to a composition unit. If bundles in the asset or composite bundle extension are subsequently changed, or if you need to remap resources, you can update the configuration. For example, if you update a bundle in an EBA asset, or replace a composite bundle extension, you might introduce a resource that requires additional configuration, such as a new or changed Blueprint resource reference, or security role mapping.

This topic describes the specific task of modifying the configuration of an OSGi composition unit. The more generalized task of modifying the configuration of any composition unit is described in Updating business-level applications.

Procedure

  1. Start the administrative console.
  2. Navigate to Applications > Application Types > Business-level applications > application_name > composition_unit_name.

    The Composition unit settings panel is displayed.

  3. Under the Additional Properties section, click any of the following options then modify the settings as required.
    • Session management

      Configure HTTP session management for the web application bundles. For more information, see Configuring session management by level.

      The Session management option is only visible if the OSGi application uses web application bundles.

    • Map context roots

      Select a web application bundle (WAB) from the list, then enter the context root for the WAB. For example, /sample. For more information, see Context root for web application bundles [Settings].

      The Map context roots option is only visible if the application uses web application bundles.

    • Virtual hosts

      The list of available WABs in this asset is displayed. For each WAB, you can change the associated virtual host by selecting a different one from the list. If you specify an existing virtual host in the ibm-web-bnd.xml or .xmi file for a given WAB, the specified virtual host is set by default. Otherwise, the default virtual host setting is default_host. For more information, see Virtual hosts for web application bundles [Settings].

      The Virtual hosts option is only visible if the application uses web application bundles.

    • Security role to user/group mapping

      Change the security mapping as needed. For more information, see Security role to user or group mapping [Settings].

      The Security role to user/group mapping option is only visible if the application uses security roles.

    • Map RunAs roles to users

      You can map a specified user identity and password to a RunAs role. This enables you to specify application-specific privileges for individual users, so that they can run specific tasks using another user identity. For more information, see Map RunAs roles to users [Collection].

      The Map RunAs roles to users option is only visible if the application uses RunAs roles.

    • Bind Blueprint resource references

      The list of available Blueprint resource references in this asset is displayed. For each reference, you can optionally select an authentication alias from the list. Default authentication aliases (from ibm-eba-bnd.xml files) are offered only if they exist on every target server or cluster. For more information, see Blueprint resource reference bindings [Settings].

      The Bind Blueprint resource references option is only visible if the bundle includes Blueprint resource reference declarations.

    • Web module message destination and resource environment reference bindings

      The list of available web application message destination and resource environment references in this asset is displayed. That is, resources of type message-destination-ref (message destination reference) or resource-env-ref (resource environment reference), as defined in the Java specification JSR-250: Common Annotations for the Java Platform. For each reference, specify the JNDI name under which the resource is known in the runtime environment. For more information, see Web module message destination and resource environment reference bindings [Settings].

      The Web module message destination and resource environment reference bindings option is only visible if the bundle includes a web application.

    • Web module resource reference bindings

      The list of available web application resource references in this asset is displayed. That is, resources of type resource-ref (resource reference), as defined in the Java specification JSR-250: Common Annotations for the Java Platform. For each reference, specify the JNDI name under which the resource is known in the runtime environment. Optionally, set authentication properties and extended data source custom properties, which affect how the resource is accessed at run time. To specify the JNDI name mapping, either type the JNDI name into the box, or click Browse... then select the resource reference from the list of available resources. To modify the authentication method or set extended data source custom properties, select a single reference then click Modify Resource Authentication Method... or Extended Properties.... For more information, see Web module resource reference bindings [Settings].

      The Web module resource reference bindings option is only visible if the bundle includes a web application.

  4. Save your changes to the master configuration.

Results

When you save the changes to the composition unit, the associated business-level application is updated to use the new configuration. If the business-level application is running, the bundle and configuration updates are applied immediately. If possible (that is, depending on the nature of the updates) the system applies the updates without restarting the application. If you update a bundle that provides only OSGi services to the rest of the application, then only that bundle is restarted. If you update a bundle that provides one or more packages to other bundles, then those bundles and any bundles to which they provide packages are restarted. If, however, a new package or service dependency is added, or an existing package or service dependency is removed, then the application is restarted; a newly added package and service can come from a newly-provisioned bundle, or from a bundle that has already been provisioned. Messages relating to any restart operations are written to the WebSphere Application Server SystemOut.log file.

Task topic

Terms of use | Feedback


Timestamp icon Last updated: Tuesday, 20 September 2011
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=matt&product=was-base-dist&topic=ta_admin_mod_acu

Copyright IBM Corporation 2009, 2011. All Rights Reserved.
This information center is powered by Eclipse technology. (http://www.eclipse.org)