Use common constants for monitor and server parameters
The parameter names for monitors and servers now use a set of constant names. This removes some of the errors caused by spelling mistakes when the same parameter name is repeated in multiple places. The service, filter and listener parameters should also be converted to constants. This allows for a consistent user experience.
This commit is contained in:

committed by
Markus Mäkelä

parent
9aa4138705
commit
695a4032ca
@ -30,6 +30,15 @@ MXS_BEGIN_DECLS
|
||||
#define MAX_SERVER_MONPW_LEN 512
|
||||
#define MAX_NUM_SLAVES 128 /**< Maximum number of slaves under a single server*/
|
||||
|
||||
/**
|
||||
* Server configuration parameters names
|
||||
*/
|
||||
extern const char CN_MONITORPW[];
|
||||
extern const char CN_MONITORUSER[];
|
||||
extern const char CN_PERSISTMAXTIME[];
|
||||
extern const char CN_PERSISTPOOLMAX[];
|
||||
extern const char CN_USE_PROXY_PROTOCOL[];
|
||||
|
||||
/**
|
||||
* The server parameters used for weighting routing decissions
|
||||
*/
|
||||
@ -192,8 +201,6 @@ enum
|
||||
(((server)->status & (SERVER_RUNNING|SERVER_MASTER|SERVER_SLAVE|SERVER_MAINT)) == \
|
||||
(SERVER_RUNNING|SERVER_MASTER|SERVER_SLAVE))
|
||||
|
||||
extern const char USE_PROXY_PROTOCOL[];
|
||||
|
||||
/**
|
||||
* @brief Allocate a new server
|
||||
*
|
||||
|
Reference in New Issue
Block a user