ipc-rpc-overview.md 1.2 KB
Newer Older
A
Annie_wang 已提交
1
# IPC & RPC Overview
M
mamingshuai 已提交
2 3


A
Annie_wang 已提交
4
## Basic Concepts
M
mamingshuai 已提交
5

A
Annie_wang 已提交
6 7 8 9 10
Inter-process communication (IPC) and remote procedure call (RPC) are used to implement cross-process communication. IPC uses the Binder driver to implement inter-process communication within a device, whereas RPC uses the intelligent software bus driver to implement inter-process communication across devices. 

IPC and RPC generally use the client-server model for communication. The client (service requester) obtains the proxy of the server (service provider) and uses this proxy to read and write data. The server registers system abilities (SAs) with the system ability manager (SAMgr), which manages the SAs and provides interfaces for clients. To interact with an SA, the client must obtain the proxy of the SA from SAMgr. 

In OpenHarmony documents, proxy represents the service requester, and stub represents the service provider.
M
mamingshuai 已提交
11

12

A
Annie_wang 已提交
13
## Constraints
M
mamingshuai 已提交
14

A
Annie_wang 已提交
15 16 17
- The data transmitted for inter-process communication within a device cannot exceed 1 MB. If more data needs to be transmitted, use the anonymous shared memory.

- The cross-device proxy object cannot be passed to the device hosting the stub object pointed by this proxy object.
M
mamingshuai 已提交
18

A
Annie_wang 已提交
19 20 21

## Related Modules

Q
ql 已提交
22
[Distributed Scheduler](https://gitee.com/openharmony/ability_dmsfwk)