mirror of
https://github.com/MariaDB/server.git
synced 2025-07-21 21:22:27 +03:00
Add shared memory protocol and option --protocol
This commit is contained in:
@ -56,6 +56,7 @@ typedef int my_socket;
|
||||
|
||||
#include "mysql_com.h"
|
||||
#include "mysql_version.h"
|
||||
#include "typelib.h"
|
||||
|
||||
extern unsigned int mysql_port;
|
||||
extern char *mysql_unix_port;
|
||||
@ -137,24 +138,36 @@ struct st_mysql_options {
|
||||
a read that is replication-aware
|
||||
*/
|
||||
my_bool no_master_reads;
|
||||
char *shared_memory_base_name;
|
||||
unsigned int protocol;
|
||||
};
|
||||
|
||||
enum mysql_option { MYSQL_OPT_CONNECT_TIMEOUT, MYSQL_OPT_COMPRESS,
|
||||
MYSQL_OPT_NAMED_PIPE, MYSQL_INIT_COMMAND,
|
||||
MYSQL_READ_DEFAULT_FILE, MYSQL_READ_DEFAULT_GROUP,
|
||||
MYSQL_SET_CHARSET_DIR, MYSQL_SET_CHARSET_NAME,
|
||||
MYSQL_OPT_LOCAL_INFILE};
|
||||
enum mysql_option
|
||||
{
|
||||
MYSQL_OPT_CONNECT_TIMEOUT, MYSQL_OPT_COMPRESS, MYSQL_OPT_NAMED_PIPE, MYSQL_INIT_COMMAND,
|
||||
MYSQL_READ_DEFAULT_FILE, MYSQL_READ_DEFAULT_GROUP,MYSQL_SET_CHARSET_DIR, MYSQL_SET_CHARSET_NAME,
|
||||
MYSQL_OPT_LOCAL_INFILE, MYSQL_OPT_PROTOCOL, MYSQL_SHARED_MEMORY_BASE_NAME
|
||||
};
|
||||
|
||||
enum mysql_status { MYSQL_STATUS_READY,MYSQL_STATUS_GET_RESULT,
|
||||
MYSQL_STATUS_USE_RESULT};
|
||||
enum mysql_status
|
||||
{
|
||||
MYSQL_STATUS_READY,MYSQL_STATUS_GET_RESULT,MYSQL_STATUS_USE_RESULT
|
||||
};
|
||||
|
||||
enum mysql_protocol_type
|
||||
{
|
||||
MYSQL_PROTOCOL_DEFAULT, MYSQL_PROTOCOL_TCP, MYSQL_PROTOCOL_SOCKET, MYSQL_PROTOCOL_PIPE,
|
||||
MYSQL_PROTOCOL_MEMORY
|
||||
};
|
||||
/*
|
||||
There are three types of queries - the ones that have to go to
|
||||
the master, the ones that go to a slave, and the adminstrative
|
||||
type which must happen on the pivot connectioin
|
||||
*/
|
||||
enum mysql_rpl_type { MYSQL_RPL_MASTER, MYSQL_RPL_SLAVE,
|
||||
MYSQL_RPL_ADMIN };
|
||||
enum mysql_rpl_type
|
||||
{
|
||||
MYSQL_RPL_MASTER, MYSQL_RPL_SLAVE, MYSQL_RPL_ADMIN
|
||||
};
|
||||
|
||||
|
||||
typedef struct st_mysql
|
||||
|
Reference in New Issue
Block a user