Mercurial > libervia-backend
view doc/libervia-cli/pubsub_node_schema.rst @ 3539:60d3861e5996
bridge (dbus): use Tx DBus for backend part of D-Bus bridge:
Due to recent SQLAlchemy integration, Libervia is now using AsyncIO loop exclusively as
main loop, thus GLib's one can't be used anymore (event if it could be in a separate
thread).
Furthermore Python-DBus is known to have design flaws mentioned even in the official
documentation.
Tx DBus is now used to replace Python-DBus, but only for the backend for now, as it will
need some work on the frontend before we can get completely rid of it.
author | Goffi <goffi@goffi.org> |
---|---|
date | Thu, 03 Jun 2021 15:21:43 +0200 |
parents | c80a0f864b5d |
children | 267e4987b58b |
line wrap: on
line source
.. _libervia-cli_pubsub_node_schema: ========================================= pubsub/node/schema: nodes schema handling ========================================= ``node schema`` is an experimental feature to associate a data form with a PubSub node, and reject items not following this form. This feature is currently only available with SàT PubSub. Those commands can only be used by an owner of the node. set === Set the schema of a node. The raw schema is written directly as positional argument. example ------- Set the schema for tickets node using the file ``tickets_schema.xml`` from ``$HOME`` directory. Shell substition is used here to put the content of the file in the positional argument:: $ li pubsub node schema set -n org.salut-a-toi.tickets:0 -s pubsub.example.org "$(<~/test_schema.xml)" edit ==== Edit the schema of a node using your local editor (the one set in ``$EDITOR``). If you don't change anything or publish an empty schema, the edition will be cancelled. :ref:`draft_common` commands can be used. example ------- Edit the tickets node schema:: $ li pubsub node schema edit -n org.salut-a-toi.tickets:0 -s pubsub.example.org example ------- get === Retrieve schema of a node. example ------- Get schema of tickets and save it to a file named ``tickets_schema.xml`` in ``$HOME`` directory:: $ li pubsub node schema get -n org.salut-a-toi.tickets:0 -s pubsub.example.org > ~/tickets_schema.xml