Remote-procedure Call


Remote-procedure calls (RPC) allow communication between different systems. Each system operates as an independent, autonomous device unable to share access to internal processes directly or natively.

As with Inter-process Communication in that different processes have different address spaces that cannot be easily shared, processes running inside different systems cannot access each other; they need RPC to communicate.

Legato's Low-level Messaging API and API Files provide RPC services without all the coding, packing/unpacking, and network communication handling that come with using other methods directly.

Legato has built-in RPC features. The language-independent, function-call-oriented RPC approach is automatically handled with the ifgen tool and the buildTools.

By default, each system runs as an independent, autonomous device. When an system is constructed, all the RPC services it needs are declared. At runtime, the Supervisor and the Service Directory enforce that only those approved RPC services are accessed by remote systems.

Client-side network-interfaces are "bound" to server-side network-interfaces through a combination of system definition files and set-up configuration data. This allows reconfiguration of systems into new systems just by re-routing bindings, without having to modify the client or server software. Bindings make code more reusable. For example, if an app controls an LED, but the LED is connected to a different GPIO pin on different target devices, that same app can be used on both devices, with its LED control interface bound to different GPIO pin control services in each device.

Using language-independent RPC makes applications inherently more reusable, creates opportunities for function isolation in different systems, and automatically creates potential debugging trace points.

Legato RPC - Getting Start with RPC
Hello RPC - Sample RPC Application

Related information

API Files
Definition Files
Platform Services