Below is the list of changes that have just been committed into a local
5.1 repository of root. When root does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet@stripped, 2006-09-04 18:23:32+00:00, lzhou@stripped +4 -0
Merge dev3-138.dev.cn.tlan:/home/zhl/mysql/mysql-5.0/bug21128
into dev3-138.dev.cn.tlan:/home/zhl/mysql/mysql-5.1/bug21128
MERGE: 1.1810.1697.133
storage/ndb/include/mgmapi/mgmapi.h@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Auto merged
MERGE: 1.42.10.2
storage/ndb/include/mgmapi/mgmapi.h@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Merge rename: ndb/include/mgmapi/mgmapi.h -> storage/ndb/include/mgmapi/mgmapi.h
storage/ndb/src/mgmapi/mgmapi.cpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Auto merged
MERGE: 1.44.24.2
storage/ndb/src/mgmapi/mgmapi.cpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Merge rename: ndb/src/mgmapi/mgmapi.cpp -> storage/ndb/src/mgmapi/mgmapi.cpp
storage/ndb/src/mgmsrv/Services.cpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Auto merged
MERGE: 1.45.29.2
storage/ndb/src/mgmsrv/Services.cpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Merge rename: ndb/src/mgmsrv/Services.cpp -> storage/ndb/src/mgmsrv/Services.cpp
storage/ndb/src/mgmsrv/Services.hpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Auto merged
MERGE: 1.13.6.2
storage/ndb/src/mgmsrv/Services.hpp@stripped, 2006-09-04 18:23:28+00:00, lzhou@stripped +0 -0
Merge rename: ndb/src/mgmsrv/Services.hpp -> storage/ndb/src/mgmsrv/Services.hpp
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: lzhou
# Host: dev3-138.dev.cn.tlan
# Root: /home/zhl/mysql/mysql-5.1/bug21128/RESYNC
--- 1.42.10.1/ndb/include/mgmapi/mgmapi.h 2006-09-04 18:23:38 +00:00
+++ 1.54/storage/ndb/include/mgmapi/mgmapi.h 2006-09-04 18:23:38 +00:00
@@ -171,7 +171,6 @@
= NODE_TYPE_MGM
#endif
#ifndef DOXYGEN_SHOULD_SKIP_INTERNAL
- ,NDB_MGM_NODE_TYPE_REP = NODE_TYPE_REP /** A replication node */
,NDB_MGM_NODE_TYPE_MIN = 0 /** Min valid value*/
,NDB_MGM_NODE_TYPE_MAX = 3 /** Max valid value*/
#endif
@@ -906,16 +905,6 @@
enum ndb_mgm_event_category category,
int level,
struct ndb_mgm_reply* reply);
-
- /**
- * Returns the port number where statistics information is sent
- *
- * @param handle NDB management handle.
- * @param reply Reply message.
- * @return -1 on error.
- */
- int ndb_mgm_get_stat_port(NdbMgmHandle handle,
- struct ndb_mgm_reply* reply);
#endif
/**
--- 1.44.24.1/ndb/src/mgmapi/mgmapi.cpp 2006-09-04 18:23:38 +00:00
+++ 1.70/storage/ndb/src/mgmapi/mgmapi.cpp 2006-09-04 18:23:38 +00:00
@@ -142,6 +142,12 @@
return ret; \
}
+#define DBUG_CHECK_REPLY(reply, ret) \
+ if (reply == NULL) { \
+ SET_ERROR(handle, NDB_MGM_ILLEGAL_SERVER_REPLY, ""); \
+ DBUG_RETURN(ret); \
+ }
+
/*****************************************************************************
* Handles
*****************************************************************************/
@@ -202,7 +208,7 @@
handle->cfg.~LocalConfig();
new (&(handle->cfg)) LocalConfig;
handle->cfg.init(0, 0); /* reset the LocalConfig */
- SET_ERROR(handle, NDB_MGM_ILLEGAL_CONNECT_STRING, "");
+ SET_ERROR(handle, NDB_MGM_ILLEGAL_CONNECT_STRING, mgmsrv ? mgmsrv : "");
DBUG_RETURN(-1);
}
handle->cfg_i= -1;
@@ -1476,34 +1482,7 @@
extern "C"
int
-ndb_mgm_get_stat_port(NdbMgmHandle handle, struct ndb_mgm_reply* /*reply*/)
-{
- SET_ERROR(handle, NDB_MGM_NO_ERROR, "Executing: ndb_mgm_get_stat_port");
- const ParserRow<ParserDummy> stat_reply[] = {
- MGM_CMD("error", NULL, ""),
- MGM_ARG("result", String, Mandatory, "Error message"),
- MGM_CMD("get statport reply", NULL, ""),
- MGM_ARG("tcpport", Int, Mandatory, "TCP port for statistics"),
- MGM_END()
- };
- CHECK_HANDLE(handle, -1);
- CHECK_CONNECTED(handle, -1);
-
- Properties args;
- const Properties *reply;
- reply = ndb_mgm_call(handle, stat_reply, "get statport", &args);
- CHECK_REPLY(reply, -1);
-
- Uint32 port;
- reply->get("tcpport", &port);
-
- delete reply;
- return port;
-}
-
-extern "C"
-int
-ndb_mgm_dump_state(NdbMgmHandle handle, int nodeId, int* _args,
+ndb_mgm_dump_state(NdbMgmHandle handle, int nodeId, const int * _args,
int _num_args, struct ndb_mgm_reply* /* reply */)
{
SET_ERROR(handle, NDB_MGM_NO_ERROR, "Executing: ndb_mgm_dump_state");
@@ -2353,9 +2332,9 @@
int param,
int value,
struct ndb_mgm_reply* mgmreply){
- DBUG_ENTER("ndb_mgm_set_connection_int_parameter");
CHECK_HANDLE(handle, 0);
CHECK_CONNECTED(handle, 0);
+ DBUG_ENTER("ndb_mgm_set_connection_int_parameter");
Properties args;
args.put("node1", node1);
@@ -2372,7 +2351,7 @@
const Properties *prop;
prop= ndb_mgm_call(handle, reply, "set connection parameter", &args);
- CHECK_REPLY(prop, -1);
+ DBUG_CHECK_REPLY(prop, -1);
int res= -1;
do {
@@ -2396,9 +2375,9 @@
int param,
int *value,
struct ndb_mgm_reply* mgmreply){
- DBUG_ENTER("ndb_mgm_get_connection_int_parameter");
CHECK_HANDLE(handle, -1);
CHECK_CONNECTED(handle, -2);
+ DBUG_ENTER("ndb_mgm_get_connection_int_parameter");
Properties args;
args.put("node1", node1);
@@ -2414,7 +2393,7 @@
const Properties *prop;
prop = ndb_mgm_call(handle, reply, "get connection parameter", &args);
- CHECK_REPLY(prop, -3);
+ DBUG_CHECK_REPLY(prop, -3);
int res= -1;
do {
@@ -2462,9 +2441,9 @@
{
Uint32 nodeid=0;
- DBUG_ENTER("ndb_mgm_get_mgmd_nodeid");
CHECK_HANDLE(handle, 0);
CHECK_CONNECTED(handle, 0);
+ DBUG_ENTER("ndb_mgm_get_mgmd_nodeid");
Properties args;
@@ -2476,7 +2455,7 @@
const Properties *prop;
prop = ndb_mgm_call(handle, reply, "get mgmd nodeid", &args);
- CHECK_REPLY(prop, 0);
+ DBUG_CHECK_REPLY(prop, 0);
if(!prop->get("nodeid",&nodeid)){
fprintf(handle->errstream, "Unable to get value\n");
@@ -2490,9 +2469,9 @@
extern "C"
int ndb_mgm_report_event(NdbMgmHandle handle, Uint32 *data, Uint32 length)
{
- DBUG_ENTER("ndb_mgm_report_event");
CHECK_HANDLE(handle, 0);
CHECK_CONNECTED(handle, 0);
+ DBUG_ENTER("ndb_mgm_report_event");
Properties args;
args.put("length", length);
@@ -2511,7 +2490,7 @@
const Properties *prop;
prop = ndb_mgm_call(handle, reply, "report event", &args);
- CHECK_REPLY(prop, -1);
+ DBUG_CHECK_REPLY(prop, -1);
DBUG_RETURN(0);
}
@@ -2519,9 +2498,9 @@
extern "C"
int ndb_mgm_end_session(NdbMgmHandle handle)
{
- DBUG_ENTER("ndb_mgm_end_session");
CHECK_HANDLE(handle, 0);
CHECK_CONNECTED(handle, 0);
+ DBUG_ENTER("ndb_mgm_end_session");
SocketOutputStream s_output(handle->socket);
s_output.println("end session");
--- 1.45.29.1/ndb/src/mgmsrv/Services.cpp 2006-09-04 18:23:38 +00:00
+++ 1.74/storage/ndb/src/mgmsrv/Services.cpp 2006-09-04 18:23:38 +00:00
@@ -123,8 +123,6 @@
const
ParserRow<MgmApiSession> commands[] = {
- MGM_CMD("get statport", &MgmApiSession::getStatPort, ""),
-
MGM_CMD("get config", &MgmApiSession::getConfig, ""),
MGM_ARG("version", Int, Mandatory, "Configuration version number"),
MGM_ARG("node", Int, Optional, "Node ID"),
@@ -504,7 +502,8 @@
NDB_TICKS tick= 0;
/* only report error on second attempt as not to clog the cluster log */
while (!m_mgmsrv.alloc_node_id(&tmp, (enum ndb_mgm_node_type)nodetype,
- (struct sockaddr*)&addr, &addrlen, error_code, error_string,
+ (struct sockaddr*)&addr, &addrlen,
+ error_code, error_string,
tick == 0 ? 0 : log_event))
{
/* NDB_MGM_ALLOCID_CONFIG_MISMATCH is a non retriable error */
@@ -665,15 +664,6 @@
free(tmp_str);
return;
-}
-
-void
-MgmApiSession::getStatPort(Parser_t::Context &,
- const class Properties &) {
-
- m_output->println("get statport reply");
- m_output->println("tcpport: %d", 0);
- m_output->println("");
}
void
--- 1.13.6.1/ndb/src/mgmsrv/Services.hpp 2006-09-04 18:23:38 +00:00
+++ 1.22/storage/ndb/src/mgmsrv/Services.hpp 2006-09-04 18:23:38 +00:00
@@ -54,7 +54,6 @@
virtual ~MgmApiSession();
void runSession();
- void getStatPort(Parser_t::Context &ctx, const class Properties &args);
void getConfig(Parser_t::Context &ctx, const class Properties &args);
#ifdef MGM_GET_CONFIG_BACKWARDS_COMPAT
void getConfig_old(Parser_t::Context &ctx);
| Thread |
|---|
| • bk commit into 5.1 tree (lzhou:1.2287) | lzhou | 4 Sep |