Specifying Middleware Type 

Purpose

The SessionManager object needs to know which middleware implementation to use with the Java RFC, for it to create the appropriate factory objects.

The SessionManager needs this information for both RFC client and RFC server applications.

The best way to specify the middleware implementation to use, is by specifying middleware type through the Java RFC properties files.

Process Flow

  1. Create the r3_connection.props properties files. Specify one of the following values for the jrfc.middleware.type field in the r3_connection.props properties files
  2. Value

    Meaning

    1

    Use the Orbix implementation

    3

    Use the SAP JNI implementation

    4

    Use custom middleware type: use the implementation of the factory interfaces as specified in the jrfc.props file.

    We recommend that you always use 4 as the value of the jrfc.middleware.type field.

    This value can be used for a custom implementation of the middleware, that is, for a middleware implementation that is not supplied with the Java RFC.

    More importantly, when you use this value, you direct Java RFC to determine the middleware type from the jrfc.props file, rather than from the r3_connection.props file. This is useful when you want to keep the r3_connection.props file as read-only, for the sake of preserving password information file (as we recommend in Setting Up and Starting a Session).

  3. If you use custom middleware type, then also create the jrfc.props properties file.
  4. The SessionManager obtains middleware information from the r3_connection.props file. The SessionManager does so when it is instantiated. The SessionManager also sets SessionInfo (and MiddlewareInfo) with the middleware type from r3_connection.props.
  5. If you specify 4 for the jrfc.middleware.type field, the SessionManager obtains factory information from the jrfc.props file, when it needs it to create factory objects.
  6. The SessionManager re-write the r3_connection.props file (re-writing middleware type

If the r3_connection.props properties file does not exists, then the SessionManager creates it with the middleware type from the SessionInfo object.

The SessionManager does not write into the jrfc.props file.

The following diagram summarizes this process.

 

For the details of the contents of the two properties files, see The Java RFC Properties Files.

See Also

The SessionManager and the SessionInfo Objects, Setting Up and Starting a Session, Using the Properties File to Set Up SessionInfo

Also see the Java RFC HTML Reference documentation for the details of each of the classes mentioned here.