X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=src%2Finclude%2Ffrontend%2Fconnection.h;h=bf902ddc1761b78c5b56f7b3c4903c8614639c3d;hb=9ae83505d8025ab32a8bdf7904ff4df8f9e661bf;hp=45d377e10df2ffb9ff28220b9c331f0410e47e0a;hpb=bf39a85b7764641b4a4f0c452331c8be8cb34a01;p=sysdb.git diff --git a/src/include/frontend/connection.h b/src/include/frontend/connection.h index 45d377e..bf902dd 100644 --- a/src/include/frontend/connection.h +++ b/src/include/frontend/connection.h @@ -52,6 +52,20 @@ typedef struct { } sdb_conn_node_t; #define SDB_CONN_NODE(obj) ((sdb_conn_node_t *)(obj)) +/* + * sdb_connection_enable_logging: + * Enable logging of connection-related messages to the current client + * connection. After this function has been called all log messages + * originating from the thread handling the current client connection will + * also be sent to the client. + * + * Returns: + * - 0 on success + * - a negative value else + */ +int +sdb_connection_enable_logging(void); + /* * sdb_connection_accpet: * Accept a new connection on the specified file-descriptor 'fd' and return a @@ -150,6 +164,17 @@ sdb_fe_session_start(sdb_conn_t *conn); * store access */ +/* + * sdb_fe_fetch: + * Send the named host, serialized as JSON, to the client. + * + * Returns: + * - 0 on success + * - a negative value else + */ +int +sdb_fe_fetch(sdb_conn_t *conn, const char *name); + /* * sdb_fe_list: * Send a complete listing of the store, serialized as JSON, to the client.