- Usage
- Settings
- Modules
- Admin
- ???
- Client
- ???
- Admin
- Introspection
- ???
- Receive
- ???
- Route
- ???
- Send
- ???
- Validate
- ???
While the C
library provides a well-known interface for C/C++ programming and several other programming languages, it is not the only solution.
The interface between C
static library and the Zefina service is well documented, allowing other languages to interact with the Zefina service.
For an application to communicate with Zefina, the application must do the following:
- Register with Zefina
- Provide an Endpoint Configuration
- Read data from the Event Unix Domain Socket
- Read/Write data from/to the Data Unix Domain Socket
The difference between a Zefina Client and a Zefina Application is that a Zefina Client uses the Zefina Library, which handles all of the details documented here. A correctly implemented application will behave the same as a client. One will take more work and both are equally valid.
Registration
Command | Meaning |
---|---|
0x01 | Registration Open |
0x02 | Registration Close |
Zefina has a well-known Unix Domain Socket (or POSIX Pipe) for applications to use for registration.
The application must create two Unix Domain Sockets, one for Data and one for Events.
The application will then create a Zefina Registration Request using code 0x01.
Zefina Codes
Zefina Codes are a CBOR array. The first element of the array is the Code. The second element of the array ore the arguments for the Code. (An empty array is valid.) Any elements after the second element depends on the code.
0x01 - Registration Request
Array Index | Description |
---|---|
0 | Data Descriptor |
1 | Event Descriptor |
0x02 - Close Connection
Empty Array