yumapro
24.10-3
YumaPro SDK
|
YANG Push dynamic subscriptions are supported. More...
Macros | |
#define | AGT_PUSH_FL_CREATE bit0 |
These bits match the change-type definition in RFC 8641 They represent the inverse of the excluded-change. More... | |
#define | AGT_PUSH_FL_DELETE bit1 |
PUSH delete operation. | |
#define | AGT_PUSH_FL_INSERT bit2 |
PUSH insert operation. | |
#define | AGT_PUSH_FL_MOVE bit3 |
PUSH move operation. | |
#define | AGT_PUSH_FL_REPLACE bit4 |
PUSH replace operation. | |
#define | AGT_PUSH_DEF_INCLUDED_CHANGES 0x1f |
the excluded-changeds leaf-list set is stored as an inverted uint8 bitset | |
#define | AGT_PUSH_SET_CREATE_FLAG(F) (F) |= AGT_PUSH_FL_CREATE |
Set the PUSH Create flag. | |
#define | AGT_PUSH_GET_CREATE_FLAG(F) ((F) & AGT_PUSH_FL_CREATE) |
Get the PUSH Create flag. | |
#define | AGT_PUSH_SET_DELETE_FLAG(F) (F) |= AGT_PUSH_FL_DELETE |
Set the PUSH Delete flag. | |
#define | AGT_PUSH_GET_DELETE_FLAG(F) ((F) & AGT_PUSH_FL_DELETE) |
Get the PUSH Delete flag. | |
#define | AGT_PUSH_SET_INSERT_FLAG(F) (F) |= AGT_PUSH_FL_INSERT |
Set the PUSH Delete flag. | |
#define | AGT_PUSH_GET_INSERT_FLAG(F) ((F) & AGT_PUSH_FL_INSERT) |
Get the PUSH Insert flag. | |
#define | AGT_PUSH_SET_MOVE_FLAG(F) (F) |= AGT_PUSH_FL_MOVE |
Set the PUSH Move flag. | |
#define | AGT_PUSH_GET_MOVE_FLAG(F) ((F) & AGT_PUSH_FL_MOVE) |
Get the PUSH Move flag. | |
#define | AGT_PUSH_SET_REPLACE_FLAG(F) (F) |= AGT_PUSH_FL_REPLACE |
Set the PUSH Replace flag. | |
#define | AGT_PUSH_GET_REPLACE_FLAG(F) ((F) & AGT_PUSH_FL_REPLACE) |
Get the PUSH Replace flag. | |
Enumerations | |
enum | agt_push_dserr_t { AGT_PUSH_DSERR_NONE , AGT_PUSH_DSERR_DATASTORE , AGT_PUSH_DSERR_FILTER_REF , AGT_PUSH_DSERR_SUBTREE_FILTER , AGT_PUSH_DSERR_XPATH_FILTER , AGT_PUSH_DSERR_STOP_TIME , AGT_PUSH_DSERR_ENCODING , AGT_PUSH_DSERR_PERIODIC , AGT_PUSH_DSERR_PERIOD , AGT_PUSH_DSERR_ANCHOR_TIME , AGT_PUSH_DSERR_ON_CHANGE , AGT_PUSH_DSERR_DAMPENING_PERIOD , AGT_PUSH_DSERR_SYNC_ON_START , AGT_PUSH_DSERR_EXCLUDED_CHANGE , AGT_PUSH_DSERR_ID } |
datastore error parameter numbers Used internally to identify error objects for <rpc-error> More... | |
Functions | |
status_t | agt_push_init (obj_template_t *update_obj, obj_template_t *change_obj) |
Initialize the PUSH modules. More... | |
status_t | agt_push_init2 (void) |
PUSH init phase 2. More... | |
void | agt_push_cleanup (void) |
Cleanup the PUSH Module. More... | |
status_t | agt_push_establish_subscription (ses_cb_t *scb, ncx_nmda_ds_t datastore_id, const xmlChar *selection_filter_ref, const val_value_t *datastore_subtree_filter, const val_value_t *datastore_xpath_filter, const xmlChar *stop_time, val_value_t *encoding, boolean periodic, uint32 period, const xmlChar *anchor_time, boolean on_change, uint32 dampening_period, boolean sync_on_start, uint32 included_changes, agt_not_subid_t *subid, agt_push_dserr_t *errnum) |
Set the YANG-Push datastore parameters and start a YANG push subscription. More... | |
status_t | agt_push_modify_subscription (ses_cb_t *scb, agt_not_subid_t cur_subid, ncx_nmda_ds_t datastore_id, const xmlChar *selection_filter_ref, const val_value_t *datastore_subtree_filter, const val_value_t *datastore_xpath_filter, const xmlChar *stop_time, boolean periodic, uint32 period, const xmlChar *anchor_time, boolean on_change, boolean dampening_set, uint32 dampening_period, agt_push_dserr_t *errnum) |
Set the YANG-Push datastore parameters and start a YANG push subscription. More... | |
status_t | agt_push_sync_subscription (agt_not_subid_t subid) |
Request a sync for the YANG-Push datastore subscription. More... | |
void | agt_push_config_update (rpc_msg_t *msg, agt_cfg_transaction_t *txcb) |
Do a config update for YANG Push subscriptions if needed. More... | |
boolean | agt_push_is_enabled (void) |
Check if agt_push is enabled. More... | |
YANG Push dynamic subscriptions are supported.
This module uses the agt_not.h APIs. The PUSH module parameters and logic are processed in this module, using subscriptions managed in agt_not.c
#define AGT_PUSH_FL_CREATE bit0 |
These bits match the change-type definition in RFC 8641 They represent the inverse of the excluded-change.
They represent the included changes. A zero byte means YANG Push is not collecting on this object for the datastore
bit0 is create
enum agt_push_dserr_t |
datastore error parameter numbers Used internally to identify error objects for <rpc-error>
void agt_push_cleanup | ( | void | ) |
Cleanup the PUSH Module.
CALLED FROM u_ietf-yang-push.c ONLY NOT CALLED FROM agt.c
void agt_push_config_update | ( | rpc_msg_t * | msg, |
agt_cfg_transaction_t * | txcb | ||
) |
Do a config update for YANG Push subscriptions if needed.
msg | RPC msg in progress |
txcb | transaction control block |
status_t agt_push_establish_subscription | ( | ses_cb_t * | scb, |
ncx_nmda_ds_t | datastore_id, | ||
const xmlChar * | selection_filter_ref, | ||
const val_value_t * | datastore_subtree_filter, | ||
const val_value_t * | datastore_xpath_filter, | ||
const xmlChar * | stop_time, | ||
val_value_t * | encoding, | ||
boolean | periodic, | ||
uint32 | period, | ||
const xmlChar * | anchor_time, | ||
boolean | on_change, | ||
uint32 | dampening_period, | ||
boolean | sync_on_start, | ||
uint32 | included_changes, | ||
agt_not_subid_t * | subid, | ||
agt_push_dserr_t * | errnum | ||
) |
Set the YANG-Push datastore parameters and start a YANG push subscription.
scb | session control block starting the subscription | |
datastore_id | ID of datastore to use for push | |
selection_filter_ref | filter by reference: option 1 of 3 for subscription filter | |
datastore_subtree_filter | inline subtree filter: option 2 of 3 for subscription filter | |
datastore_xpath_filter | inline XPath filter: option 3 of 3 for subscription filter | |
stop_time | stop time is a common parm if replay supported for stream | |
encoding | encoding is a common parm. Only XML is supported. | |
periodic | TRUE for periodic subscription, FALSE on-change | |
period | internval to use if periodic | |
anchor_time | anchor the periodic intervals if periodic | |
on_change | TRUE if on-change; FALSE if periodic | |
dampening_period | dampening interval if on-change | |
sync_on_start | send a full update for the first one | |
included_changes | inverted flags of excluded_change | |
[out] | subid | address of return subscription ID assigned *subid subscription ID assigned (if NO_ERR) |
[out] | errnum | address of return parm number of error *errnum parm number of error if returning error (if some error) |
status_t agt_push_init | ( | obj_template_t * | update_obj, |
obj_template_t * | change_obj | ||
) |
Initialize the PUSH modules.
Called after the CLI parameters are set and before any load-config CALLED FROM u_ietf-yang-push.c ONLY NOT CALLED FROM agt.c
update_obj | push-update notification |
change_obj | push-change-update notification |
status_t agt_push_init2 | ( | void | ) |
PUSH init phase 2.
CALLED FROM u_ietf-yang-push.c ONLY NOT CALLED FROM agt.c
boolean agt_push_is_enabled | ( | void | ) |
Check if agt_push is enabled.
could be false if –with-new-notifs is set to true and no yang-push bundle
status_t agt_push_modify_subscription | ( | ses_cb_t * | scb, |
agt_not_subid_t | cur_subid, | ||
ncx_nmda_ds_t | datastore_id, | ||
const xmlChar * | selection_filter_ref, | ||
const val_value_t * | datastore_subtree_filter, | ||
const val_value_t * | datastore_xpath_filter, | ||
const xmlChar * | stop_time, | ||
boolean | periodic, | ||
uint32 | period, | ||
const xmlChar * | anchor_time, | ||
boolean | on_change, | ||
boolean | dampening_set, | ||
uint32 | dampening_period, | ||
agt_push_dserr_t * | errnum | ||
) |
Set the YANG-Push datastore parameters and start a YANG push subscription.
scb | session control block starting the subscription | |
cur_subid | current subscription ID | |
datastore_id | ID of datastore to use for push | |
selection_filter_ref | filter by reference: option 1 of 3 for subscription filter | |
datastore_subtree_filter | inline subtree filter: option 2 of 3 for subscription filter | |
datastore_xpath_filter | inline XPath filter: option 3 of 3 for subscription filter | |
stop_time | stop time is a common parm if replay supported for stream | |
periodic | TRUE for periodic subscription, FALSE on-change | |
period | internval to use if periodic | |
anchor_time | anchor the periodic intervals if periodic | |
on_change | TRUE if on-change; FALSE if periodic | |
dampening_set | dampening interval is set | |
dampening_period | dampening interval if on-change | |
[out] | errnum | address of return parm number of error *errnum parm number of error if returning error (if some error) |
status_t agt_push_sync_subscription | ( | agt_not_subid_t | subid | ) |
Request a sync for the YANG-Push datastore subscription.
subid | subscription ID |