Guide to Building Business Processes

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

Running and Testing Your Business Process

BEA Workshop for WebLogic Platform provides a browser-based interface with which you can test the functionality of your business process. Using this Test View interface, you play the role of the client, invoking the business process’s methods and viewing the responses.

This step describes how to test a business process you have created in BEA Workshop for WebLogic Platform using the Test Browser tool. It includes the following topics:

 


Using the Test Browser

To Launch the Test Browser
  1. On the Package Explorer pane, click the business process (Process.java file) you want to test.Your business process is displayed in the Design view.
  2. If the Server view is not visible in BEA WorkSpace Studio menu, choose Window > Show View > Other > Server > Servers, and click Ok. A Server view is displayed.
  3. On the Package Explorer pane, select and right-click the business process (Process.java file) you want to test.
  4. Click Run As, and Run On Server.
  5. In the Define a New Server dialog box, select either a Choose an existing server option or Manually define a new server (if there is no server defined), and click Next.
  6. In the BEA WebLogic Server v10.0 dialog box, to manually define a server, click Browse, and select the samples integration domain directory from the product installation directory available at BEA_HOME\wlserver_10.0\samples\domains\integration, where BEA_HOME represents the directory in which you installed WebLogic Platform. Click Finish.
  7. The samples domain integration server is started, and the application is deployed on it. When WebLogic Server is running, the following indicator is visible in the Servers view (see Figure 18-1).
  8. Figure 18-1 Server Status

    Server Status

  9. After the application is deployed, the Test Browser is displayed.
  10. The Workshop Test Browser contains the following tabs:

Overview

This tab displays public information about your business process. Code in this area is generated automatically and 2-way editing is fully supported in the Process Language. Changes you make here will appear in the Design view.

The Overview tab displays public information about the web service, including:

Console

This tab displays private information about your business process, such as how services are implemented on the back end, and with what version of BEA Workshop for WebLogic Platform it was created. It also displays information about log settings, such as how many log messages to keep and the number of characters after which log entries are truncated.

Test Form

This tab provides a simple test environment for the public methods of your business process. You can provide parameters for a method and examine its return value. You can also track and test the different parts of a conversation.

Test SOAP

This tab shows the XML data that is being sent to your business process when you test its XML methods. You can use this page to examine and modify the XML data that is passed to a method of your business process.

Message Broker

This tab provide a space for you to publish messages to channels available in channel files in your application. It allows you to test your process interactions with asynchronous events and simulate Timer, Email, File, JMS, and other event generators.

Process Graph

This tab allows you to view an interactive or printable graph of the deployed process type. The graphical view represents your business process and its interactions with clients and resources, such as databases, JMS queues, file systems. It shows the path taken thus far by the business process and provides additional information about the state of each node in the process. If your browser is not already configured with the SVG plug-in when you click this tab, BEA Workshop for WebLogic Platform will offer to download and install it for you.

For specific information about how to use the Test Form, Message Broker, and Process Graph tabs, see To Test the Public Methods of Your Business Process, To Test a Message Broker Channel, and To View a Process Graph.

WARNING: As you use the Test Browser, take care to not run very large or data intensive business processes. Doing so may cause the Test Browser to fail.

Testing the Public Methods of Your Business Process

To Test the Public Methods of Your Business Process
  1. Launch the Workshop Test Browser. (To learn more, see To Launch the Test Browser).
  2. Click Test Form tab.
  3. You can enter data that your business process can receive as part of a client request directly on the Test Form page. Alternatively, you can browse your file system and upload a file which contains your test data.

  4. If your client operation accepts input, enter the required information in to the field or fields. To upload a file to test data, click Browse beside the xml requestXML (file value) field to open the file browser, then select the file that contains the test data you want to use.
  5. Note: An input xml file URI with space is not supported in the Test Form.

    You can also enter the test data by entering (copy/paste) the content of a file into the field.

  6. Click the button labeled with your business process’s method name to invoke the method with the values you entered. The Test Form page refreshes to display a summary of your request parameters and your business process’s response:
    • Under Service Request, a summary of the data that was sent by the client (you) when the method was called, including the values of method parameters, is displayed.
    • For business processes that involve multiple communications with clients, or communications with resources such as other Web services, the Message Log on the left side of the Test Form page displays an entry for each call to a method or callback so that you can view the data for each. Click any log entry to see the details of that interaction.
    • Business Processes participate in conversations with clients. The Test Browser displays the instance ID in the Message Log. Select the instance ID or Server Status to access continue and finish methods in that conversation.
  7. When the business process finishes, a message similar to the following is displayed in the Message Log:
  8. Instance instanceID is Completed.

    In the preceding line, instanceID represents the ID generated when the first method in your business process was called.

  9. Click the Test SOAP tab.
  10. The Test SOAP tab displays the XML data that is being sent to your business process when you test its methods in the soap body field. You can use this page to examine and modify the XML data that is passed to a method of your business process.

  11. Click the button with the name of your method to start a new conversation.The Test Form page refreshes to display a summary of your request parameters and your business process's response.
  12. When the business process finishes, a message similar to the following is displayed in the Message Log:

    Instance instanceID is Completed.

    In the preceding line, instanceID represents the ID generated when the first method in your business process was called.

Testing a Message Broker Channel

To Test a Message Broker Channel
  1. Launch the Workshop Test Browser. (To learn more, see To Launch the Test Browser).
  2. Click Test Form and enter test data that can be used for to test the public methods that are published on your channel. To learn more, see To Test the Public Methods of Your Business Process .
  3. Click the Message Broker tab.
  4. The Message Broker test tab is displayed with details of the conversation routed through your channel. The conversation id is displayed in the message log. Click any of the methods displayed in your message log to view details on the right side of the window about the external services communications (callbacks and responses).

Viewing the Process Graph

The Process Graph tab of the Workshop Test Browser provides a SVG graph of your process as it is running. The graph represents your business process and its interactions with clients and resources, such as databases, JMS queues, and file systems.

The interactive instance graph is a fully expanded version of the view provided in the Design View. The interactive process graph requires Adobe SVG Viewer Version 3.0 or Java Batik SVG Viewer (for more information, see Requirement for the Interactive Graph). The first time you open the Process Graph tab, you will be asked if you would like to accept the Software License Agreement for the Adobe Viewer :

This viewer is not available for some configurations that the WebLogic Platform 10.2 supports. For details, please see Process Monitoring.

For detailed information about the operating systems and browsers WebLogic Platform supports, see BEA WebLogic Platform Supported Configurations.

To View a Process Graph
  1. Launch the Workshop Test Browser. (To learn more, see To Launch the Test Browser.)
  2. Click the Process Graph tab.
  3. The SVG Viewer displays the interactive view. The Process Graph Visual cues are provided to indicate node status as described in the following table:

    Table 18-1 Mode Details
    If the node . . .
    And the tracking level is . . .
    The node appears . . .
    Has been visited
    Full or Node
    Normal
    Minimum
    Normal
    Is currently executing
    Full or Node
    Highlighted
    Minimum
    Highlighted
    Has not been visited
    Full or Node
    Dimmed
    Minimum
    Normal

    To learn about business process tracking levels, see “Viewing and Changing Process Details” in Process Configuration.

    The top panel of the Process Graph tab displays selected process properties. To learn more about the properties displayed, see “Viewing Process Instance Details” in Process Instance Monitoring.

  4. Do any of the following:
    • To display node status, click the node. The node name, type, and description are displayed in the Node Info panel. If the tracking level is set to Full, the start time, elapsed time, finish time, and completed visits are also displayed. If the tracking level is set to Node or Minimum, this additional information is not available.
    • To scroll the view, press and hold down the Alt key. The cursor changes to a hand Server Status tool. Click and drag to scroll the process graph vertically or horizontally.
    • To zoom in, press and hold down the Ctrl key. The cursor changes to a zoom in Server Status tool. Click to zoom in.
    • To zoom out, press and hold down the Ctrl+Shift keys. The cursor changes to a zoom out Server Status tool. Click to zoom out.
    • To change to a printable view, click Print View. The process graph is displayed as a PDF.

 


Understanding the Service URL

In the Test browser, a URL is displayed in the upper-right corner of the Test Form tab. The URL you see when you launch Test View for your business process should be similar to the following URL:

http://localhost:7051/samples/myBusinessProcess.jpd

In the preceding line:


  Back to Top       Previous  Next