BEA Logo BEA WebLogic Enterprise Release 5.1

  Corporate Info  |  News  |  Solutions  |  Products  |  Partners  |  Services  |  Events  |  Download  |  How To Buy

 

   WebLogic Enterprise Doc Home   |   CORBA Programming & Related Topics   |   Previous Topic   |   Next Topic   |   Contents   |   Index

Using Request-Level Interceptors

 

This document describes how programmers can implement request-level interceptors in the BEA WebLogic EnterpriseTM (WLE) system. Using request-level interceptors is an advanced programming feature of the WebLogic Enterprise system.

This document is intended for programmers who want to create secure, scalable, transaction-based server applications. It assumes you are familiar with CORBA and the C++ and Java programming languages.

 

Introduction

Interceptor Architecture

Capabilities and Limitations

Execution Flow

Client-side Execution

Client-side Exception Handling

Target-side Execution

Target-side Exception Handling

The exception_occurred Method

About Short-circuit Behavior

Using Multiple Request-level Interceptors

Multiple Client-side Interceptors

Multiple Target-side Interceptors

Interceptors and Implementation Languages

Interceptors and Meta-operations

 

Developing C++ Interceptors

Step 1: Identify the Interfaces of Your WebLogic Enterprise Applications

Step 2: Write the Interceptor Implementation Code

Starting the Implementation File

Initializing the Interceptor at Run Time

Obtaining the Interface Name from a Request

Identifying Operations in the Request

Implementing the Interceptor's Response Operation

Reading Parameters Out of a Data Input Stream

Exceptions

Step3: Create the Interceptor Header File

Step 4: Build the Interceptor

Step 5: Test the Interceptor

 

Developing Java Interceptors

Step 1: Identify the Interfaces of Your WebLogic Enterprise Applications

Step 2: Write the Interceptor Implementation Code

Starting the Implementation File

Implementing the Interceptor's Constructor

Obtaining the Interface Name from a Request

Identifying Operations in the Request

Implementing the Interceptor's Response Operation

Reading Data Out of a Data Input Stream

Step 3: Build the Interceptor

Step 4: Test the Interceptor

Notes About Implementing Java Interceptors

 

Deploying the Interceptor

Registering an Interceptor

Unregistering an Interceptor

Changing the Order in Which Interceptors are Called

 

PersonQuery Sample Application

How the PersonQuery Sample Application Works

PersonQuery Database

Client Application Command-line Interface

The OMG IDL for the PersonQuery Sample Application

Building and Running the PersonQuery Sample Application

Copying the Files for the PersonQuery Sample Application

Changing the Protection on PersonQuery Application Files

Setting the Environment Variables

Building the Client and Server Applications

Start the PersonQuery Client and Server Applications

Running the PersonQuery Sample Application

Stopping the PersonQuery Sample Application

Building and Running the Java RLI Sample Applications

Copying the Files for the Java PersonQuery Samples

Changing the Protection on PersonQuery Application Files

Setting the Environment Variables

Building the Server Application

Start the PersonQuery Client and Server Applications

Running the PersonQuery Sample Application

Stopping the PersonQuery Sample Application

 

InterceptorSimp Sample Interceptors

How the PersonQuery Sample Interceptors Work

Registering and Running the PersonQuery Interceptors

Registering and Running the C++ Interceptors

Registering and Running the Java Interceptors

Examining the Output of the Interceptors

Unregistering the Interceptors

Unregistering the C++ Interceptors

Unregistering the Java Interceptors

 

InterceptorSec Sample Interceptors

How the PersonQuery Sample Interceptors Work

How the InterceptorSec Target-side Interceptor Works

Using the SecurityCurrent Object

Obtaining the SecurityCurrent Object

Creating the List of User Attributes

Registering and Running the PersonQuery Interceptors

Registering and Running the C++ Interceptors

Registering and Running the Java Interceptors

Examining the Interceptor Output

Unregistering the Interceptors

Unregistering the C++ Interceptors

Unregistering the Java Interceptors

 

InterceptorData Sample Interceptors

InterceptorDataClient Interceptor

InterceptorDataTarget Interceptor

Implementing the InterceptorData Interceptors

Registering and Running the InterceptorData Interceptors

Registering and Running the C++ Interceptors

Registering and Running the Java Interceptors

Examining the Interceptor Output

Unregistering the Interceptors

Unregistering the C++ Interceptors

Unregistering the Java Interceptors

 

Request-Level Interceptor API

Interceptor Hierarchy

Note on Unused Interfaces

Interceptors::Interceptor Interface

C++ Language Mapping

Java Language Mapping

RequestLevelInterceptor::
RequestInterceptor Interface

C++ Language Mapping

Java Language Mapping

RequestLevelInterceptor::
ClientRequestInterceptor Interface

C++ Language Mapping

Java Language Mapping

RequestLevelInterceptor::
TargetRequestInterceptor Interface

C++ Language Mapping

Java Language Mapping

CORBA::DataInputStream Interface

C++ Language Mapping

Java Language Mapping

 

Starter C++ Interceptor Files

Starter Implementation Code

Starter Header File Code

 

Starter Java Implementation File