Using Retrieve Resources

This activity is normally used in conjunction with an HTTP Receiver process starter and a Send HTTP Response activity. The HTTP Receiver process starter can receive an HTTP request and pass it along to the Retrieve Resources activity. When a request is made to retrieve a WSDL file for a process definition that has a SOAP Event Source process starter, Retrieve Resources creates a WSDL file dynamically. This file contains the concrete service definition of the specified ActiveMatrix BusinessWorks process definition. The WSDL file or other requested resources are then placed into the output for this activity.

You can then pass the output of the Retrieve Resources activity to the Send HTTP Response activity to send the response back to the requestor.

Process definition using the Retrieve Resources activity illustrates a process definition using the Retrieve Resources activity.

Figure 108: Process definition using the Retrieve Resources activity

Note: The HTTP Receiver process starter can be configured to use the HTTPS protocol for SSL communication when retrieving resources. For more information, see HTTP Receiver.

When sending the HTTP response, set the Headers/Content-Type item on the Input tab to the appropriate type for the type of resource retrieved. Use "text/xml" when this activity is used to retrieve a WSDL file. For more information on the format of the URL for the HTTP request for retrieving resources, see Format of URLs for HTTP Requests .

For more information about binding the HTTP request to this activity’s input and binding this activity’s output to an HTTP response, see the descriptions of the Input and Output tabs for this activity.

If you want to test a process definition containing this activity, you must load the process definition containing this activity along with the process definition containing the SOAP Event Source process starter into the test window. For more information about loading multiple process definitions when testing, see TIBCO ActiveMatrix BusinessWorks™ Process Design.

Format of URLs for HTTP Requests

To use the Retrieve Resources activity, the HTTP request must have one of the following forms:

  • http://<host>:<port>/<path>/<resourceName>?wsdl

  • http://<host>:<port>/<path>/<resourceName>

  • http://<host>:<port>/inspection.wsil

Option

Description

<host>

Host name of the machine that is listening for the HTTP request.

<port>

Port is the port number on the machine for incoming HTTP requests. This is specified on the Configuration tab of the HTTP Receiver process starer.

<path>

The location of the resource in the ActiveMatrix BusinessWorks project tree.

Note: Any special characters in the path or resource name (such as &, =, or space) are mangled in the generated WSDL file. It is a good idea to avoid special characters in the folder and resource names.

<resourceName>

The name of the resource to retrieve.

If you are retrieving a WSDL file for a process definition, use the name of the process definition followed by ?wsdl.

If you are retrieving other resources (such as XSD files, images, and so on), specify the name of the resource, such as mySchema.xsd, myProcess.process, or myImage.gif.

Note: Use resourceName.serviceagent to reference a Receive Partner Notification resource

inspection.wsil

Used to retrieve a Web Services Inspection Language (WSIL) file containing a list of all configured web services. Any process definitions with SOAP Event Source process starters in the project get contained in the WSIL file.

Examples

The following is an HTTP request that retrieves the WSDL file for the process named GetPurchaseOrder stored in the folder Purchasing:

http://purch:8877/Purchasing/GetPurchaseOrder?wsdl

The following is an HTTP request that retrieves a WSIL file containing all process definitions with SOAP Event Source process starters:

http://purch:8877/inspection.wsil

The following is an HTTP request that retrieves the PurchaseOrder.xsd file:

http://purch:8877/Purchasing/Schemas/PurchaseOrder.xsd

The following is an HTTP request that retrieves the WSDL file for the Service resource named BuyerService :

http://server:8877/BuyerService.serviceagent?wsdl