Remote Model

The NPS system does not control the life cycle of the remote AE processes. If the NPS system is used to launch the AE, it is launched daemon-style and disassociated from the NPS system process tree. A remote AE may have a life cycle that ranges from less than a subset of a query up to indefinite, as with a long running daemon. A remote AE processes many SQL function calls simultaneously unless an instance exists per session or dataslice and the AE is invoked only once per SQL statement.

Connecting to a Remote AE

A SQL function must connect to a running instance of a remote AE. It is required that a running instance exists on each SPU, on the host, or on both. There may be more than one instance of the same AE executable running on each machine at the same time.

If more than one instance is running, then a remote AE must have a name; that is, it must be addressable. There must also be a way to tell the NPS system to connect to a specific instance of a running remote AE for a given SQL function. Each running remote AE per operating system instance must have a unique address. In addition the address must be unique per SPU and unique on the host. However, an AE running on different SPUs may have the same address; for the same application (this is typically the case). The remote AE functionality exposes the two kinds of connections between the Netezza system and an AE: data and notification. The data connection is how data flows between an SQL function and an AE. In the case of a local AE, this is the only visible connection. The notification connection is explicitly visible in a remote AE. The primary purpose is to notify a running AE that it has a new data connection to service. It can also be used to ping the remote AE to determine if it is still running, or to request that the remote AE shut down or stop.