Using the AquaLogic Service Bus Console

     Previous  Next    Open TOC in new window    View as PDF - New Window  Get Adobe Reader - New Window
Content starts here

XQuery Transformations

This section includes the following topics:

Overview of XQuery Transformations

Transformation maps describe the mapping between two data types. AquaLogic Service Bus supports data mapping using either XQuery or the eXtensible Stylesheet Language Transformation (XSLT) standard. XSLT maps describe XML-to-XML mappings, whereas XQuery maps can describe XML-to-XML, XML to non-XML, and non-XML to XML mappings.

XQuery transformation is the primary XML transformation tool provided in BEA AquaLogic Service Bus. BEA provides the BEA XQuery Mapper tool to help you create XQuery transformations (.xq files). The XQuery Mapper is a plug-in within the Eclipse development environment. Therefore, to use the XQuery Mapper, Eclipse must be installed and launched.

Eclipse and the XQuery Mapper are provided as part of the AquaLogic Platform installation. However, when using the XQuery Mapper with AquaLogic Service Bus, the XQuery Mapper must be invoked separately. To learn more, see "Launching the XQuery Mapper" in Transforming Data Using XQuery in Transforming Data Using the XQuery Mapper.

You can use XQuery transformations when you edit XQuery expressions in the Message Flow of proxy services. You can select the XQ transformation option to execute a specific XQuery transformation when you edit an XQuery expression on the XQuery Expression Editor page.

In the Message Flow of proxy services, you can assign XQuery expressions to message context variables, assign if then else actions based on the Boolean result of an XQuery expression, insert the result of an XQuery expression at an identified place relative to an XPath expression, specify the message context that you want to log through XQuery expressions on context variables, and so on. To learn more, see Overview of Message Flow, Adding an Action, and Using the Inline XQuery Expression Editor.

The following table lists the XQuery transformation pages you can access from the Resource Browser and Project Explorer modules. The tasks and help topics associated with each are provided.

Table 9-1 XQuery Transformation Pages, Tasks and Help Topics
Page
Associated Tasks
Help Topics
Summary of XQueries
View a list of XQuery transformations. The XQuery name is displayed.
Filter the list of XQuery transformations
Delete an XQuery transformation
Create a New XQuery
Add a new XQuery transformation
XQuery Transformation Details
View details of an XQuery transformation
Edit details of an XQuery transformation

Listing and Locating XQuery Transformations

The Summary of XQueries page allows you to view a list of XQuery transformations. XQuery transformations describe the mappings between two data types. To learn more, see Overview of XQuery Transformations.

To List and Locate XQuery Transformations
  1. From the left navigation pane, select XQueries from under Resource Browser. The Summary of XQueries page is displayed, which displays the following information for each XQuery transformation. For a more detailed description of the properties, see Viewing and Changing XQuery Transformation Details.
  2. Table 9-2 XQuery Transformation Details
    Property
    Description
    XQuery Name
    The name assigned to the XQuery transformation. The name is a link to the XQuery Transformation Details page. To learn more, see Viewing and Changing XQuery Transformation Details.
    Path
    The path is the project name and the name of the folder in which the XQuery transformation resides. It is a link to the project or folder that contains this resource. To learn more, see Viewing Project Details or Viewing Folder Details.
    Actions
    Click the Launch Test Console icon to invoke the Test Console, which you use to validate and test the design of your services and transformations. For XQuery transformations, you can use the Test Console whether you are inside or outside a session. To learn more, see Testing Transformations.
    Options
    Click the Delete icon to delete a specific XQuery transformation. To learn more, see Deleting an XQuery Transformation.

  3. To locate a specific transformation, do one of the following:
    • Filter by transformation name. In the Name and Path fields, enter the name and path of the search target, then click Search. The path is the project name and the name of the folder in which the XQuery transformation resides. The transformations matching the search criteria are displayed.
    • Resort the list. Ascending and descending arrow buttons indicate sortable columns—in this case, the XQuery Name and Path columns. Click the button to change the sort order.
    • Scroll through the pages. Use the controls in the lower right corner. Go to a page by selecting the page number or by using the arrow buttons to go to the next, previous, first, or last page.
    • Note: Click View All to display all XQuery transformations.

Related Topics

Adding an XQuery Transformation

Adding an XQuery Transformation

The Create a New XQuery page allows you to add a new XQuery transformation. XQuery transformations describe the mapping between two data types. To learn more, see Overview of XQuery Transformations.

To add a new XQuery transformation, do one of the following:

Note: XQuery transformation is the primary XML transformation tool provided in BEA AquaLogic Service Bus. BEA provides the BEA XQuery Mapper tool to help you create XQuery transformations (.xq files). The XQuery Mapper is a plug-in within the Eclipse development environment. Therefore, to use the XQuery Mapper, Eclipse must be installed and launched. Eclipse and the XQuery Mapper are provided as part of the AquaLogic Platform installation. However, when using the XQuery Mapper with AquaLogic Service Bus, the XQuery Mapper must be invoked separately. To learn more, see "Launching the XQuery Mapper" in Transforming Data Using XQuery in Transforming Data Using the XQuery Mapper.
To Add a New XQuery Transformation
  1. If you have not already done so, from the left navigation pane, under Change Center, click Create to create a new session for making changes to the current configuration. To learn more, see Using the Change Center.
  2. From the left navigation pane, select Project Explorer. The Project View page is displayed.
  3. Select the project to which you want to add the XQuery transformation. You can add an XQuery transformation directly to the project, or you can add it to a selected folder that resides in the project.
  4. Note: Click the name of a folder to select it. The Folder View page is displayed.
  5. From the Project View or Folder View page, in the Create Resource field, select XQuery from under Transformation. The Create a New XQuery page is displayed.
  6. In the Resource Name field, enter a unique name for this XQuery transformation. This is a required field.
  7. In the Resource Description field, enter a description for the XQuery transformation.
  8. In the XQuery field, do one of the following:
    • Enter text for the new XQuery transformation.
    • Click Browse to locate and import an existing XQuery transformation.
    • Copy and paste text from an existing XQuery transformation into this field.
    • Note: This is a required field.
  9. Do one of the following:
    • To save the XQuery transformation, click Save. The XQuery transformation is created.
    • The Project View or Folder View page is displayed. The new XQuery transformation is included in the list of resources.

    • To disregard changes, click Cancel.
Note: The new XQuery transformation is saved in the current session. When you have finished making changes to this configuration, from the left navigation pane, click Activate under Change Center. The session ends and the configuration is deployed to run time. Alternatively, click Discard at any time during the session to delete the changes you have made so far in the current session.

Related Topics

Listing and Locating XQuery Transformations

Viewing and Changing XQuery Transformation Details

Deleting an XQuery Transformation

Creating a Resource

Viewing and Changing XQuery Transformation Details

The XQuery Transformation Details page allows you to view and change details of an XQuery transformation. XQuery transformations describe the mapping between two data types. To learn more, see Overview of XQuery Transformations.

To View and Change XQuery Transformation Details
  1. Locate the XQuery transformation. To learn more, see Listing and Locating XQuery Transformations.
  2. Click the XQuery transformation name. The XQuery Transformation Details page displays the following information.
  3. Table 9-3 XQuery Transformation Resource Details
    Property
    Description
    Resource Name
    The name assigned to this XQuery transformation
    Last Modified By
    The user who created this XQuery transformation or imported it into the configuration.
    Last Modified On
    The date and time that the user created this XQuery transformation or imported it into the configuration.
    References
    The number of objects that this XQuery transformation references. If such references exist, click the link to view a list of the objects. To learn more, see Viewing References.
    Referenced by
    The number of objects that reference this XQuery transformation. If such references exist, click the link to view a list of the objects. For example, if you assigned this XQuery transformation to a variable in the Message Flow of a specific proxy service, the proxy service is listed as a reference when you click the link.To learn more, see Viewing References.
    Description
    A description of this XQuery transformation, if one exists.
    XQuery
    The full text of the XQuery transformation
    XQuery Variables
    The XQuery variables selected for this XQuery transformation

  4. If you have not already done so, from the left navigation pane, under Change Center, click Create to create a new session or click Edit to enter an existing session to make changes to the current configuration. To learn more, see Using the Change Center.
  5. To make a change to the fields, click Edit. See Adding an XQuery Transformation for a description of the fields.
  6. Note: You cannot change the Resource Name field.
  7. Do one of the following:
    • To update the XQuery transformation, click Save. The XQuery transformation is updated.
    • The Summary of XQueries page is displayed.

    • To disregard changes, click Cancel.
Note: The updated XQuery transformation is saved in the current session. When you have finished making changes to this configuration, from the left navigation pane, click Activate under Change Center. The session ends and the configuration is deployed to run time. Alternatively, click Discard at any time during the session to delete the changes you have made so far in the current session.

Related Topics

Deleting an XQuery Transformation

Deleting an XQuery Transformation

The Summary of XQueries page allows you to delete XQuery transformations. XQuery transformations describe the mapping between two data types. To learn more, see Overview of XQuery Transformations.

Note: You cannot delete a resource if it is referenced by other resources in AquaLogic Service Bus. Instead of the Delete icon, a Delete icon with a red X is displayed for these resources.
To Delete an XQuery Transformation
  1. If you have not already done so, from the left navigation pane, under Change Center, click Create to create a new session for making changes to the current configuration. To learn more, see Using the Change Center.
  2. From the left navigation pane, select XQuery Transformations from under Resource Browser. The Summary of XQueries page is displayed.
  3. In the Options field of the XQuery Transformation you want to delete, click the Delete icon.
  4. The XQuery transformation is removed from the list.

    Note: If necessary, you can undo the deletion of this resource. To learn more, see Undoing a Task.

    The XQuery transformation is deleted in the current session. When you have finished making changes to this configuration, from the left navigation pane, click Activate under Change Center. The session ends and the configuration is deployed to run time. Alternatively, click Discard at any time during the session to delete the changes you have made so far in the current session.

Related Topics

Listing and Locating XQuery Transformations

Adding an XQuery Transformation

Viewing and Changing XQuery Transformation Details


  Back to Top       Previous  Next