Functions
MyQtt Storage: Plugable storage API

Functions

axl_bool myqtt_storage_clear (MyQttCtx *ctx, MyQttConn *conn, MyQttStorage storage)
 Allows to clear current session storage associated to the provided connection. More...
 
axl_bool myqtt_storage_clear_offline (MyQttCtx *ctx, const char *client_identifier, MyQttStorage storage)
 Clears the storage associated to the provided client_identifier. More...
 
axlList * myqtt_storage_get_retained_topics (MyQttCtx *ctx, const char *topic_filter)
 Allows to get the list of topics with message retention stored, filtered by the provided topic_filter. More...
 
axl_bool myqtt_storage_init (MyQttCtx *ctx, MyQttConn *conn, MyQttStorage storage)
 Inits storage service for the provided client id. More...
 
axl_bool myqtt_storage_init_offline (MyQttCtx *ctx, const char *client_identifier, MyQttStorage storage)
 Offline storage initialization for the provided client identifier. More...
 
axl_bool myqtt_storage_lock_pkgid (MyQttCtx *ctx, MyQttConn *conn, int pkg_id)
 Allows to lock the provided id or fail if it is already in use. More...
 
axl_bool myqtt_storage_lock_pkgid_offline (MyQttCtx *ctx, const char *client_identifier, int pkg_id)
 Allows to lock the provided id or fail if it is already in use. More...
 
void myqtt_storage_queued_flush (MyQttCtx *ctx, MyQttConn *conn)
 Allows to redeliver all queued messages associated to the connected session provided. More...
 
int myqtt_storage_queued_messages (MyQttCtx *ctx, MyQttConn *conn)
 Allows to get current queued messages pending to be redelivered on next connection. More...
 
int myqtt_storage_queued_messages_offline (MyQttCtx *ctx, const char *client_identifier)
 Allows to get current queued messages pending to be redelivered on next connection (offline version). More...
 
int myqtt_storage_queued_messages_quota (MyQttCtx *ctx, MyQttConn *conn)
 Allows to get current storage quota used by queued messages pending to be redelivered on next connection. More...
 
int myqtt_storage_queued_messages_quota_offline (MyQttCtx *ctx, const char *client_identifier)
 Allows to get current storage quota used by queued messages pending to be redelivered on next connection. More...
 
axl_bool myqtt_storage_release_msg (MyQttCtx *ctx, MyQttConn *conn, axlPointer handle, unsigned char *app_msg, int app_msg_size)
 Allows to release the provided message on the local session storage associated to the provided connection. More...
 
void myqtt_storage_release_pkgid (MyQttCtx *ctx, MyQttConn *conn, int pkg_id)
 Allows to release the provided id from the current session associated to the provided connection. More...
 
void myqtt_storage_release_pkgid_offline (MyQttCtx *ctx, const char *client_identifier, int pkg_id)
 Allows to release the provided id from the current session associated to the provided connection. More...
 
axl_bool myqtt_storage_retain_msg_recover (MyQttCtx *ctx, const char *topic_name, MyQttQos *qos, unsigned char **app_msg, int *app_msg_size)
 Allows to recover retained message for the provided topic (if any). More...
 
void myqtt_storage_retain_msg_release (MyQttCtx *ctx, const char *topic_name)
 Allows to release retain message (if any) associated to the provided topic_filter.
 
axl_bool myqtt_storage_retain_msg_set (MyQttCtx *ctx, const char *topic_name, MyQttQos qos, const unsigned char *app_msg, int app_msg_size)
 Allows to store retain message for the provided topic name so every new subscription on that topic will receive that message. More...
 
axl_bool myqtt_storage_session_recover (MyQttCtx *ctx, MyQttConn *conn)
 Allows to recover session stored by the server with current storage for the provided connection. More...
 
axl_bool myqtt_storage_set_path (MyQttCtx *ctx, const char *storage_path, int hash_size)
 Allows to configure the storage location for the provided MyQtt context. More...
 
axlPointer myqtt_storage_store_msg (MyQttCtx *ctx, MyQttConn *conn, int packet_id, MyQttQos qos, unsigned char *app_msg, int app_msg_size)
 Allows to storage the provided message on the local session storage associated to the provided connection. More...
 
axlPointer myqtt_storage_store_msg_offline (MyQttCtx *ctx, const char *client_identifier, int packet_id, MyQttQos qos, unsigned char *app_msg, int app_msg_size)
 Allows to storage the provided message on the local session storage associated to the provided connection. More...
 
axl_bool myqtt_storage_sub (MyQttCtx *ctx, MyQttConn *conn, const char *topic_filter, MyQttQos requested_qos)
 Function to record subscription for the provided client at the current storage. More...
 
int myqtt_storage_sub_count (MyQttCtx *ctx, MyQttConn *conn)
 Allows to get current number of subscriptions registered on the storage for the provided connection. More...
 
int myqtt_storage_sub_count_offline (MyQttCtx *ctx, const char *client_identifier)
 Allows to get current number of subscriptions registered on the storage for the provided client identifier. More...
 
axl_bool myqtt_storage_sub_exists (MyQttCtx *ctx, MyQttConn *conn, const char *topic_filter)
 Allows to check if the provided topic_filter is already subscribed for the provided connection. More...
 
axl_bool myqtt_storage_sub_exists_common (MyQttCtx *ctx, MyQttConn *conn, const char *topic_filter, MyQttQos requested_qos, axl_bool remove_if_found)
 Allows to check if the provided topic_filter is already subscribed for the provided connection and optionally removing it. More...
 
axl_bool myqtt_storage_sub_offline (MyQttCtx *ctx, const char *client_identifier, const char *topic_filter, MyQttQos requested_qos)
 Offline function to record subscription for the provided client identifer at the current storage. More...
 
axl_bool myqtt_storage_unsub (MyQttCtx *ctx, MyQttConn *conn, const char *topic_filter)
 Function to unsubscribe the provided topic filter on the provided connection. More...
 

Detailed Description