35 Using the SB Transport

This chapter provides an overview of the SB transport and describes how to use and configure it in your services. The SB transports integrates Oracle products with Service Bus using RMI

This chapter includes the following sections:

35.1 Introduction to the SB Transport

The SB transport allows Oracle products to synchronously invoke an Service Bus proxy service using RMI. The inbound transport allows clients to access SB proxy services using RMI. The outbound transport allows the invocation of SB proxy services using RMI. By default, accessing all services using T3 protocol, IIOP, HTTP, T3s, IIOPS, or HTTPS depends on the configuration of the target server. For more information, see "Configure Default Network Connections" in the Oracle WebLogic Server Administration Console Online Help.

35.1.1 SB Transport Features

The SB transport supports the following:

  • Propagation of the transaction context. The transaction that originated in the client Service Bus servers can optionally be propagated to the SB proxy service.

  • Propagation of the security context. By default, the security context associated with the SB client thread is used to invoke the SB proxy services. This may require enabling domain trust between domains. See "Important Information Regarding Cross-Domain Security Support" in Administering Security for Oracle WebLogic Server.

  • Invocation of SB proxy services, with custom identities, by the outbound endpoint using a service account.

  • Specification of time out value for non-transactional invocations. The client request returns when Service Bus does not respond to the request within the specified interval.

  • Association of a dispatch-policy for both request and response connections. For more information, see "Using Work Managers to Optimize Scheduled Work" in Administering Server Environments for Oracle WebLogic Server.

  • Optimization of RMI call and call-by-reference when routing to a SB business service without a JNDI provider.

  • The following service types:

    • WSDL service

    • Any SOAP service

    • Any XML service

  • The following messaging patterns:

    • Request (one-way) and request-response for the inbound transport.

      For a Service Bus client, the messaging pattern is inherited from the pipeline of the SB outbound transport by default.

      For a non-Service Bus client the default messaging pattern is request-response.

    • Request and request-response for the outbound transport environment values. For more information on the environment values the SB supports, see SB Transport Environment Values.

  • The following default values for the Quality of Service (QoS):

    • Exactly-Once for non-Service Bus clients.

    • Best-Effort for Service Bus clients.

    You can also set the QoS of a service using routing options in the pipeline. For more information, see Quality of Service..

35.2 SB Transport Error Handling

You can configure business service URIs to be taken offline when communication errors occur. When you configure the operational settings for the business service, you can enable the business service endpoint URIs to be taken offline after the specified retry interval. For more information, see "Monitoring and Managing Endpoint URIs for Business Services" in Administering Oracle Service Bus.

When a connection error occurs while invoking a SB proxy service, the SB transport provider generates the BEA-380002 error code. A connection error can occur due to any of the following reasons:

  • The target proxy service does not exist.

  • The JNDI provider settings are incorrect.

  • Any remote or naming exception occurs during RMI invocation.

    A naming exception of the type javax.naming.NamingSecurityException typically occurs when the identity used during the invocation is not recognized by the target server. When this occurs, the request returns a generic runtime error, which is not treated as a connection error.

  • An external service returns a SOAP payload with a fault code.

    When there is an error handler in place to handle the fault code, the transaction is not marked for rollback. If there is no error handler, the transaction is marked for rollback.

When an error occurs and there is an error handler in place that catches the fault and sends back a fault response (using the With Error option for the Reply action), the error is considered an application error and the transaction is not marked for rollback. In all other error cases, the transaction is marked for rollback.

SOAP faults returned by SB proxy servers are treated as application errors.

35.3 UDDI and the SB Transport

You can import and publish services to the UDDI registry. For more information, see Working with UDDI Registries..

35.3.1 Publishing a Service

When you publish a proxy service to a UDDI registry, the URI associated with the published service has the following format:

sb://host:port/service_name

where host:port refers to the host name and listening port of the server hosting the proxy service that is being published.

If the Use SSL option is enabled for the proxy service that is being published, the URI associated with the published service has the following format:

sbs://host:port/service_name

If the proxy service that is being published is running on a cluster, host:port is the Cluster Address setting in the Cluster section of the config.xml file. This value can either be a single host name and port number that is used to connect to any WebLogic Server in the cluster or it can be a comma-separated list of the host name and listener ports of the Managed Servers in the Service Bus cluster. For more information, see "WebLogic JNDI" in Developing JNDI Applications for Oracle WebLogic Server.

For more information, see Publishing Proxy Services to a UDDI Registry..

35.3.2 Importing a Service

When you import a service from the UDDI registry, the SB transport provider matches the sbscheme and host:port information from the service URI property with a JNDI provider registered on the Service Bus server using the appropriate protocol based on sbscheme. Sbscheme is the URI scheme of the SB transport-based service and can be either sb or sbs.

If sbscheme is sb, the transport provider looks for the JNDI provider using T3, T3S, IIOP, IIOPS, HTTP, or HTTPS protocol (in this order). If sbscheme is sbs, the transport provider looks for the JNDI provider using T3S protocol, IIOPS, then HTTPS (in this order). The JNDI provider that matches the service URI property is used to generate the endpoint URI of the business service that is imported to Service Bus.

If there is no matching JNDI provider, the import fails unless the imported URI is a local URI and the scheme is not sb, the default context is used. This implies that there is no JNDI provider specified for the service and it is considered co-located with the server.

For example, if the service URI property value is:

sbs://remote_oracle_service_bus_host:7002/myservice

the generated URI of the business service imported to Service Bus would be:

sb://my_jndi_provider/myservice

where, my_jndi_provider is a JNDI provider resource registered on the Service Bus server with a t3s://remote_oracle_service_bus_host:7002 URL.

For more information, see Working with UDDI Registries.

35.4 SB Transport Configuration Reference

This section describes the environment values and properties you can configure for business and proxy services using the SB transport. It also describes the JNDI provider and error handling for the SB transport.

35.4.1 SB Transport Environment Values

Table 35-1 describes the environment values supported by the SB transport. The values you specify for these variables override the properties configured for specific SB-based business or proxy services.

Table 35-1 SB Transport Environment Variables

Environment Value Use this value to …

Timeout (category: operational)

Specifies the time out value (in seconds) for the business service.

Service account (category: security)

A Service Bus service account resource to use for JNDI context security to access the Oracle BPEL Process Manager delivery service. Use this to update the user credentials associated with an SB-based business service.

Use SSL (category: security)

Specifies whether to expose the service through a secure protocol for a proxy server. For more information, see Configuring Proxy Services to Use the SB Transport.

35.4.2 Configuring Proxy Services to Use the SB Transport

A Service Bus client connects with the Service Bus server using the JNDI context and the proxy service URI. The security context of the client is used to invoke the proxy service. The default QoS is Exactly-once. Optionally, the client can change the QoS, set a request time out value, and specify a desired messaging pattern. The message is received by the inbound SB transport and processed through the pipeline.

Table 35-2 describes the properties you use to configure an SB-based proxy service. Specify the endpoint URL for the endpoint as the proxy service name. For instructions on creating a proxy service, see Creating and Configuring Proxy Services.

Table 35-2 SB Transport Properties for Proxy Services

Property Description

Dispatch Policy

Select the instance of WebLogic Server Work Manager that you want to use for the dispatch policy for this endpoint. The default Work Manager is used if no other Work Manager exists.

For information about Work Managers, see:

Use SSL

Select this option to expose the service through a secure protocol. Although this implies that the client should use the SSL protocol to access the SB proxy service, this does not prevent the client from accessing the service through unsecure protocols. In addition, the endpoint URI associated with the service would be sbs instead of sb for the following:

  • When you export a secure service through UDDI and preserve security and policy configuration details during import.

  • In the effective WSDL file.

Note: A proxy service is not bound to any particular protocol. It is the responsibility of the Oracle WebLogic Server administrator to enable SSL, IIOP, or HTTP tunneling whenever it is necessary.

This flag only affects the URI scheme of the service when it is exported or the JNDI provider selection for the business service URI when it is imported from UDDI. It does not prevent a client from accessing the service using a non-secured protocol.

35.4.3 Configuring Business Services to Use the SB Transport

SB business services can send messages only to SB proxy services. A JNDI provider, which is specified in the endpoint URI of the business service, performs a JNDI lookup on the remote Service Bus server. The client user credentials or the user credentials defined in the service account associated with the business service are used to invoke the proxy service. Optionally, a time out value and a custom dispatch policy can be associated with the business service. The QoS of the service can also be set by using the routing options.

Specify the endpoint URI for the service using the following format:

sb://jndi_provider_name/service_name

Where:

  • jndi_provider_name is the name of the JNDI provider, which points to the corresponding Service Bus JNDI provider resource. This is optional. When omitted, the default context is used. This implies that the service and the Service Bus server are located on the same machine. When the call is co-located, serialization is skipped during service invocation. For more information, see JNDI Providers.

  • service name is a target service and corresponds to the remote proxy service URI.

The following table describes the properties you use to configure an SB-based business service. For more information, see Creating and Configuring Business Services.

Table 35-3 SB Transport Properties for Business Services

Property Description

Dispatch Policy

Select the instance of WebLogic Server Work Manager that you want to use for the dispatch policy for this endpoint. The default Work Manager is used if no other Work Manager exists.

For information about Work Managers, see:

Time out

Enter the duration, in seconds, after which the business service times out and returns a runtime error.

The specified time out value is not applied when:

  • QoS of the service endpoint is Exactly-Once.

  • The specified value is a negative value.

  • The time out value is overridden in the optional Timeout custom header of the outbound request in the message flow. For information, see Adding Transport Header Actions in the Console.

Service Account

Specify the user credentials that should be used for invoking the remote proxy service. If no service account is specified, the user credentials of the inbound proxy service (the inbound client) of this business service are used for security context propagation. For more information, see Working with Service Accounts.

35.4.3.1 JNDI Providers

A JNDI provider points to the Service Bus server where the service is deployed to retrieve the RMI stubs corresponding to the SB proxy service. The JNDI provider has a high performance caching mechanism for remote connections and EJB stubs. T3, IIOP, HTTP, T3s, IIOPS, or HTTPS transport protocols can be used by JNDI provider. The preferred communication protocol from Service Bus to an Oracle WebLogic Server domain is T3 or T3S. If messages need to go through a fire wall, you can use HTTP tunneling by using an HTTP provider url in the context and by enabling HTTP tunneling on the Oracle WebLogic Server server.

Note:

It is the responsibility of the administrator to ensure that the protocol supported by the JNDI provider is on the remote Service Bus server.

When you create a business service, you can associate it with a JNDI provider. For more information, see Working with JNDI Provider Resources.