Using the HTTP Binding Component

Common User Scenarios

    The following common user scenarios convey how components interact with external systems to achieve specific business goals. The first five scenarios apply to design-time operations, and the remaining scenarios apply to runtime operations:

  1. Validating HTTP Extensibility Elements from the WSDL Editor

  2. Adding a SOAP Template to a WSDL Document

  3. Adding an HTTP Template to a WSDL Document

  4. Web Service Client Calling an Operation Using HTTP Basic Authentication

  5. Web Service Implementing an Operation Protected by HTTP Basic Authentication

  6. Web Service Client Calling an Operation Using SSL Authentication

  7. Web Service Implements an Operation Protected by SSL Authentication

Validating HTTP Extensibility Elements from the WSDL Editor

In this example, validation of HTTP Extensibility Elements is invoked from the WSDL Editor. This example assumes that you are working with an existing WSDL document containing HTTP extensibility elements.

Results

The WSDL Validation window appears at the bottom of the editor. In a normal flow case, there is a statement saying no errors were found. In the exception flow case, there is a dialog displaying all of the current errors.

Main Scenario

This scenario is the same for both normal flow and exception flow.

  1. Double-click the WSDL to open the WSDL Editor.

  2. From the WSDL Editor toolbar, click the "Validate XML" button. The Output pane appears at the bottom of the NetBeans IDE.

  3. From the Project Explorer, right-click the WSDL file and select "Validate XML" from the pop-up menu. Validation results are displayed in the Output pane.

Adding a SOAP Template to a WSDL Document

In this example, you use the New WSDL Document wizard to generate SOAP Extensibility elements.

Results

The generated WSDL contains SOAP extensibility elements at the binding level, the binding operation level, the binding operation input level, and the port level. The binding level subtype is set to the binding subtype selected in step 4 of the New WSDL Document wizard.

Main Scenario

  1. A new WSDL document is created by right-clicking the project in the Project Explorer and selecting "New > WSDL Document" from the pop-up menu. The New WSDL Document wizard appears.

  2. Follow steps 1-3 of the wizard to generate a new WSDL document.

  3. From step 4 of the wizard, select "SOAP" as the Binding Type. The available binding subtype options appear in the Binding Subtype field.

    Select an appropriate option:

    • RPC Literal

    • Document Literal

    • RPC Encoded

  4. Click "Finish" to generate the WSDL document.

Adding an HTTP Template to a WSDL Document

In this example, you use the New WSDL Document wizard to generate HTTP extensibility elements.

Results

The generated WSDL contains HTTP extensibility elements at the binding level, the binding operation level, the binding operation input level, and the port level. The binding level subtype is set to the binding subtype selected in step 4 of the New WSDL Document wizard.

Main Scenario

  1. A new WSDL document is created by right-clicking the project in the Project Explorer and selecting "New > WSDL Document" from the pop-up menu. The New WSDL Document wizard appears.

  2. Follow steps 1-3 of the wizard to generate a new WSDL document.

  3. From step 4 of the wizard, select "HTTP" as the Binding Type. The available binding subtype options appear in the Binding Subtype field.

    Select an appropriate option:

    • Post Operation UrlEncoded

    • Post Operation UrlReplacement

    • Get Operation UrlEncoded

    • Get Operation UrlReplacement

  4. Click "Finish" to generate the WSDL document.

Web Service Client Calling an Operation Using HTTP Basic Authentication

In this example, a client invokes a service that requires HTTP Basic Authentication. This example assumes that you are running a deployed BPEL project with a WSDL configured to handle HTTP Basic Authentication. This BPEL project invokes a service protected using HTTP Basic Authentication.

Results

The service processes the expected SOAP Message through HTTP after verifying the security credentials.

Main Scenario

  1. A web service client invokes an in-only abstract operation that is implemented by a BPEL process. The abstract operation has a concrete HTTP SOAP binding, so the client must use SOAP over HTTP protocol to properly invoke the operation.

  2. The BPEL Process, acting as the client, receives the message for the abstract operation and invokes a different in-only abstract operation. This operation has a concrete HTTP SOAP binding that requires HTTP Basic Authentication.

  3. The binding component picks up the normalized message and converts it to a SOAP message.

  4. The binding component pulls the appropriate username and password from the Access Manager or from the WSDL.

  5. The binding component forwards the message and proper security credentials to the service.

Web Service Implementing an Operation Protected by HTTP Basic Authentication

In this example, a user creates a BPEL project in JBI that is protected by HTTP Basic Authentication. This example assumes that you are running a deployed BPEL project with a BPEL process which implements a service that requires HTTP Basic Authentication.

Results

The JBI process receives the expected SOAP Message through HTTP after verifying the security credentials.

Main Scenario

  1. A BPEL Service Engine requires basic authentication for the operation that it implements.

  2. The HTTP Binding Component receives the HTTP message and parses out the HTTP Basic Authentication security information.

  3. The binding component verifies the security information using a known database of user names and passwords from the Access Manager or from the WSDL.

  4. The binding component creates a normalized message and sends it to the Normalized Message Router.

  5. A BPEL process, belonging to a BPEL Service Engine, processes the abstract message and returns a status message of either Done or ERROR.

Web Service Client Calling an Operation Using SSL Authentication

In this example, a client invokes a service that requires SSL Authentication. This example assumes that you are running a deployed BPEL project with a WSDL configured for SSL Authentication. This BPEL project invokes a service that is protected by SSL Authentication.

Results

The service receives the expected SOAP Message through HTTP after verifying the security credentials.

Main Scenario

  1. The BPEL process acts as the client to the service implementation. The abstract operation has a concrete HTTP SOAP binding, so the client must use SOAP over HTTP protocol to properly invoke the operation.

  2. The HTTP Binding Component receives the SOAP message, converts it to a normalized message, and forwards the message to the Normalized Message Router to the awaiting BPEL process.

  3. The BPEL Process, acting as the client, receives the abstract operation message and invokes a different in-only abstract operation. This operation has a concrete HTTP SOAP binding that requires SSL Authentication.

  4. When the client BPEL process invokes the abstract operation, a normalized message is generated and sent to the Normalized Message Router.

  5. The binding component picks up the normalized message and converts it to a SOAP message.

  6. The binding component establishes secure communication with the service provider and forwards the request to them.

Web Service Implements an Operation Protected by SSL Authentication

In this example, a server implements a service that requires SSL Authentication. This example assumes that you have deployed a BPEL project with a BPEL process which implements a service that requires SSL authentication.

Results

The service receives the expected SOAP Message through HTTP after verifying the security credentials.

Main Scenario

  1. A web service client invokes an In-Only abstract operation that is implemented by a BPEL process. This operation has a concrete HTTP SOAP binding, so the client must use HTTP protocol to properly invoke the operation.

  2. The binding component institutes the SSL hand shake and establishes secure communication with the client.

  3. The binding component receives the HTTP message and parses out the SSL Authentication security information.

  4. The binding component verifies the security information using known SSL certificates.

  5. The binding component creates a normalized message and sends it to the Normalized Message Router.

  6. A BPEL process processes the abstract message and returns a status message of either Done or ERROR.