An SDK for the TracimDaemon project
Project description
TracimDaemonSDK
A python port for the TracimDaemonSDK, an SDK for the TracimDaemon project
Usage
(WIP)
See source, below and TracimDaemonSDK for usage.
Protocol (for developers of another language)
Communication
Client and daemons communicate with the DaemonEvent format, i.e. JSON data following this format:
{
"type": "event_type",
"path": "/path/to/client/socket",
"data": {}
}
(See above DaemonEvent section for details about each field)
Registering / unregistering a client
When registering / unregistering a client a DaemonEvent must be sent on the daemon socket.
{
"type": "client_add",
"path": "/path/to/client/socket",
"data": {
"path": "/path/to/client/socket",
"pid": "999"
}
}
To register a client, the client must send the message to the daemon socket, with the type field set to client_add.
To unregister a client, the client must send the message to the daemon socket, with the type field set to client_delete.
In both, additional info, defined as follows, is required:
{
"path": "/path/to/client/socket",
"pid": "999"
}
With pid being the PID of the client process.
Receiving events
Once registered, the client will receive DaemonEvents from the daemon.
(See above DaemonEvent section for details about types and data)
Ack and Keep-Alive
Ack
The daemon will send a DaemonAck upon receiving any managed events not expecting a response, otherwise the
expected response is sent. As for now, a DaemonPong for a DaemonPing and a DaemonAccountInfo for a DaemonClientAdd
The daemon expects no DaemonAck on its messages.
Keep-Alive
The daemon will periodically (once every minute) send a DaemonPing event, clients have a minute to respond with DaemonPong,
If not, it will unregister un-responding clients at the next ping.
It is possible to test the daemon responsiveness by sending it DaemonPing events. It will respond with a DaemonPong as soon as possible.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tracim_daemon_sdk-1.0.1.tar.gz.
File metadata
- Download URL: tracim_daemon_sdk-1.0.1.tar.gz
- Upload date:
- Size: 6.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
55f32fbff1d5ff6df123760cd7e8c705d706d813d7896688b9fa65c7395346cb
|
|
| MD5 |
4c2bca8c887ad8ec709ef2edbe5abe0e
|
|
| BLAKE2b-256 |
19a5c41121ca9f10434e65ab0949deff7e39f1646645d794c014b9cf4e6291bb
|
File details
Details for the file tracim_daemon_sdk-1.0.1-py3-none-any.whl.
File metadata
- Download URL: tracim_daemon_sdk-1.0.1-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2a2c1988af5d5ee97fa7eca01c313ee7e1f3d0911af9c92077c696d44e866cbc
|
|
| MD5 |
e91873fc80f3abc8887c211e3a295458
|
|
| BLAKE2b-256 |
213f16d4c4cafdbaf28512654fa8e6e3df22f5d6097e5021519c103162378651
|