Configuring component properties  Chapter 5: Defining Component Interfaces

Chapter 4: Defining Components

Running components externally

Running a component externally protects the server process from application problems such as memory leaks or segmentation violations. Stateless components of any type can run externally, with full access to server-side features such as cached connections. When you mark a component to run externally, EAServer runs it in a separate server process. You can identify which external server runs the component, and assign groups of related components to run in the same external server. EAServer starts the external server when required, and restarts the server if it stops responding.

NoteEAServer 4.x provides a different model to run C++ components externally, with limited support for use of server-side APIs. “Running C++ components externally” describes this model. The previous C++ external execution model is supported for backward compatibility.


Configuring components to run externally

Components must be stateless to execute externally. That is, the Stateless option must be selected on the Instances tab in the Component Properties dialog box; if using jagtool or an external configuration file, the property com.sybase.jaguar.component.stateless must be true.

To configure a component for external execution, configure the settings listed in Table 4-3, on the Instances tab in the EAServer Manager Component Properties dialog box.

Table 4-3: Instances tab component properties for external execution

Setting

Specifies

External Server

If selected, the component executes externally in the specified server; the default external server name is DefaultExternal.

External Server/Name

The name of the external server that hosts the component—see “Configuring servers to host external components”.

If using jagtool or an external configuration file, set the property com.sybase.jaguar.component.external.servername.

Request Timeout

How long, in seconds, to wait for a response from the external server before returning an error to the client and restarting the external server. A value of 0 indicates infinity (no timeout). The default value is set in the server properties for the server where the component is installed—see “Configuring servers to host external components”.

If using jagtool or an external configuration file, set the Request Timeout property com.sybase.jaguar.component.external.request.timeout.

If the Automatic Failover option is selected on the Transactions tab (com.sybase.jaguar.component.auto.failover is true), EAServer retries requests that fail due to timeout, one retry only.

Server Start Timeout

How long, in seconds, to wait for the external server to start if it is not already running. EAServer returns an error to the client if the external server does not start in the specified time. The default value is set in the server properties for the server where the component is installed—see “Configuring servers to host external components”.

If using jagtool or an external configuration file, set the property com.sybase.jaguar.component.external.serverstart.timeout.


Configuring servers to host external components

The server that runs external components can be configured like any other server using EAServer Manager or jagtool. The external server must run on the same machine as the server that your application clients connect to. Do not manually start the external server; the primary server starts the external server automatically if it is not running when a request arrives.

When you specify an external server name for the component in EAServer Manager, EAServer Manager automatically installs the package that contains the component to the specified server if the server exists and the package is not already installed.

You can configure the properties in Table 4-4 on Components tab of the Server Properties dialog box for the server where the component is installed. These properties set the default timeouts for communication with servers that host external components. These properties can be overridden for individual components.

Table 4-4: Server properties for external component execution

Setting

Specifies

External Server Request Timeout

How long, in seconds, to wait for a response from the external server before returning an error to the client. If not set, the default is 60 seconds. If you specify the component External Request Timeout setting, it overrides this setting.

If using jagtool or an external configuration file, set the property com.sybase.jaguar.server.external.request.timeout.

External Server Start Timeout

How long, in seconds, to wait for the external server to start if it is not already running. EAServer returns an error to the client if the external server does not start in the specified time. If not set, the default is 60 seconds. If you specify the component External Server Start Timeout setting, it overrides this setting.

If using jagtool or an external configuration file, set the property com.sybase.jaguar.server.external.serverstart.timeout.





Copyright © 2005. Sybase Inc. All rights reserved. Chapter 5: Defining Component Interfaces