|
Inmplementation of flatstore commands.
Inmplementation of flatstore commands.
Inmplementation of flatstore "connections".
Inmplementation of flatstore "connections".
Flatstore management interface.
Flatstore management interface.
The implementation of parser parsing flatstore:.
The functions parsing and interpreting flatstore: URIs.
Flatstore module interface.
Flatstore module interface.
Per-connection flags for flatstore connections.
More...| enum flat_con_flags |
Definition at line 46 of file flat_con.h.
This function frees all memory used by flat_cmd structure.
| cmd | A pointer to generic db_cmd command being freed. | |
| payload | A pointer to flat_cmd structure to be freed. |
Definition at line 48 of file flat_cmd.c.
References flat_cmd::gen.
| int flat_con | ( | db_con_t * | con | ) |
This function creates a new flat_con structure and attachs the structure to the generic db_con structure in the parameter.
| con | A generic db_con structure to be extended with flatstore payload |
| 0 | on success | |
| A | negative number on error |
| static void flat_con_free | ( | db_con_t * | con, | |
| struct flat_con * | payload | |||
| ) | [static] |
This function function frees all memory that is in use by a flat_con structure.
| con | A generic db_con connection structure. | |
| payload | Flatstore specific payload to be freed. |
Definition at line 53 of file flat_con.c.
| int flat_put | ( | db_res_t * | res, | |
| db_cmd_t * | cmd | |||
| ) |
This is the main execution function in this driver. It is executed whenever a SER module calls db_exec and the target database of the commands is flatstore.
| res | A pointer to (optional) result structure if the command returns a result. |
| 0 | if executed successfully | |
| A | negative number if the database server failed to execute command | |
| A | positive number if there was an error on client side (SER) |
| int flat_uri | ( | db_uri_t * | uri | ) |
This function builds a new flat_uri structure from the body of the generic URI given to it in parameter.
| uri | A generic db_uri structure. |
| 0 | on success | |
| A | negative number on error. |
| static void rotate | ( | rpc_t * | rpc, | |
| void * | c | |||
| ) | [static] |
This function can be called through the management interface in SER and it will register a new file rotation request. This function only registers the request, it will be carried out next time SER attempts to write new data into the file.
Definition at line 44 of file flat_rpc.c.
References flat_rotate.
The character in this variable will be used to delimit fields.
Definition at line 77 of file flatstore_mod.c.
| str flat_delimiter = STR_STATIC_INIT("|") |
The character in this variable will be used to delimit fields.
Definition at line 77 of file flatstore_mod.c.
| str flat_escape = STR_STATIC_INIT("\\") |
The character in this variable will be used to escape specia characters, such as row and field delimiters, if they appear in the data being written in the files.
Definition at line 85 of file flatstore_mod.c.
The character in this variable will be used to escape specia characters, such as row and field delimiters, if they appear in the data being written in the files.
Definition at line 85 of file flatstore_mod.c.
| int flat_flush |
Definition at line 65 of file flatstore_mod.c.
| int flat_flush = 1 |
Definition at line 65 of file flatstore_mod.c.
| time_t flat_local_timestamp |
This variable contains the time of the last rotation of files.
Definition at line 104 of file flatstore_mod.c.
| time_t flat_local_timestamp |
This variable contains the time of the last rotation of files.
Definition at line 104 of file flatstore_mod.c.
The flatstore module generates one file per SER process to ensure that every SER process has its own file and no locking/synchronization is necessary. This variable contains a unique id of the SER process which will be added to the file name.
Definition at line 61 of file flatstore_mod.c.
The flatstore module generates one file per SER process to ensure that every SER process has its own file and no locking/synchronization is necessary. This variable contains a unique id of the SER process which will be added to the file name.
Definition at line 61 of file flatstore_mod.c.
The character in this variable will be used to delimit rows.
Definition at line 71 of file flatstore_mod.c.
| str flat_record_delimiter = STR_STATIC_INIT("\n") |
The character in this variable will be used to delimit rows.
Definition at line 71 of file flatstore_mod.c.
| time_t* flat_rotate |
This variable holds the timestamp of the last file rotation request received through the management interface.
Definition at line 98 of file flatstore_mod.c.
Referenced by rotate().
| time_t* flat_rotate |
This variable holds the timestamp of the last file rotation request received through the management interface.
Definition at line 98 of file flatstore_mod.c.
Referenced by rotate().
This is the suffix of newly created files.
Definition at line 91 of file flatstore_mod.c.
| str flat_suffix = STR_STATIC_INIT(".log") |
This is the suffix of newly created files.
Definition at line 91 of file flatstore_mod.c.
1.7.1