Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
7e89c72a
Commit
7e89c72a
authored
Aug 06, 2004
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Jammed Qmgr a bit more
Fixed Bug #4935, initialise before connecting again Some lines removed
parent
66525627
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
21 additions
and
20 deletions
+21
-20
ndb/src/common/mgmcommon/ConfigInfo.cpp
ndb/src/common/mgmcommon/ConfigInfo.cpp
+0
-2
ndb/src/common/mgmcommon/IPCConfig.cpp
ndb/src/common/mgmcommon/IPCConfig.cpp
+0
-1
ndb/src/common/transporter/Transporter.cpp
ndb/src/common/transporter/Transporter.cpp
+0
-3
ndb/src/common/transporter/TransporterRegistry.cpp
ndb/src/common/transporter/TransporterRegistry.cpp
+1
-2
ndb/src/common/util/SocketClient.cpp
ndb/src/common/util/SocketClient.cpp
+6
-4
ndb/src/common/util/SocketServer.cpp
ndb/src/common/util/SocketServer.cpp
+0
-1
ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
+0
-1
ndb/src/kernel/blocks/ndbcntr/NdbcntrMain.cpp
ndb/src/kernel/blocks/ndbcntr/NdbcntrMain.cpp
+14
-3
ndb/src/kernel/blocks/qmgr/QmgrMain.cpp
ndb/src/kernel/blocks/qmgr/QmgrMain.cpp
+0
-3
No files found.
ndb/src/common/mgmcommon/ConfigInfo.cpp
View file @
7e89c72a
...
...
@@ -2585,7 +2585,6 @@ fixPortNumber(InitConfigFileParser::Context & ctx, const char * data){
Uint32
id1
=
0
,
id2
=
0
;
require
(
ctx
.
m_currentSection
->
get
(
"NodeId1"
,
&
id1
));
require
(
ctx
.
m_currentSection
->
get
(
"NodeId2"
,
&
id2
));
id1
=
id1
<
id2
?
id1
:
id2
;
const
Properties
*
node
;
...
...
@@ -2618,7 +2617,6 @@ fixPortNumber(InitConfigFileParser::Context & ctx, const char * data){
}
ctx
.
m_userProperties
.
put
(
"ServerPortBase"
,
base
);
}
port
=
base
+
adder
;
ctx
.
m_userProperties
.
put
(
"ServerPort_"
,
id1
,
port
);
}
...
...
ndb/src/common/mgmcommon/IPCConfig.cpp
View file @
7e89c72a
...
...
@@ -445,7 +445,6 @@ IPCConfig::configureTransporters(Uint32 nodeId,
if
(
iter
.
get
(
CFG_TCP_RECEIVE_BUFFER_SIZE
,
&
conf
.
maxReceiveSize
))
break
;
conf
.
port
=
tmp_server_port
;
const
char
*
proxy
;
if
(
!
iter
.
get
(
CFG_TCP_PROXY
,
&
proxy
))
{
if
(
strlen
(
proxy
)
>
0
&&
nodeId2
==
nodeId
)
{
...
...
ndb/src/common/transporter/Transporter.cpp
View file @
7e89c72a
...
...
@@ -93,7 +93,6 @@ bool
Transporter
::
connect_client
()
{
if
(
m_connected
)
return
true
;
NDB_SOCKET_TYPE
sockfd
=
m_socket_client
->
connect
();
if
(
sockfd
<
0
)
...
...
@@ -102,7 +101,6 @@ Transporter::connect_client() {
// send info about own id
SocketOutputStream
s_output
(
sockfd
);
s_output
.
println
(
"%d"
,
localNodeId
);
// get remote id
int
nodeId
;
SocketInputStream
s_input
(
sockfd
);
...
...
@@ -115,7 +113,6 @@ Transporter::connect_client() {
NDB_CLOSE_SOCKET
(
sockfd
);
return
false
;
}
bool
res
=
connect_client_impl
(
sockfd
);
if
(
res
){
m_connected
=
true
;
...
...
ndb/src/common/transporter/TransporterRegistry.cpp
View file @
7e89c72a
...
...
@@ -200,8 +200,7 @@ TransporterRegistry::createTransporter(TCP_TransporterConfiguration *config) {
if
(
theTransporters
[
config
->
remoteNodeId
]
!=
NULL
)
return
false
;
TCP_Transporter
*
t
=
new
TCP_Transporter
(
*
this
,
config
->
sendBufferSize
,
config
->
maxReceiveSize
,
...
...
ndb/src/common/util/SocketClient.cpp
View file @
7e89c72a
...
...
@@ -70,19 +70,21 @@ SocketClient::connect()
return
-
1
;
}
}
const
int
r
=
::
connect
(
m_sockfd
,
(
struct
sockaddr
*
)
&
m_servaddr
,
sizeof
(
m_servaddr
));
if
(
r
==
-
1
)
if
(
r
==
-
1
)
{
NDB_CLOSE_SOCKET
(
m_sockfd
);
m_sockfd
=
-
1
;
return
-
1
;
}
if
(
m_auth
)
if
(
m_auth
)
{
if
(
!
m_auth
->
client_authenticate
(
m_sockfd
))
{
NDB_CLOSE_SOCKET
(
m_sockfd
);
m_sockfd
=
-
1
;
return
-
1
;
}
}
NDB_SOCKET_TYPE
sockfd
=
m_sockfd
;
m_sockfd
=
-
1
;
...
...
ndb/src/common/util/SocketServer.cpp
View file @
7e89c72a
...
...
@@ -146,7 +146,6 @@ SocketServer::doAccept(){
ServiceInstance
&
si
=
m_services
[
i
];
if
(
FD_ISSET
(
si
.
m_socket
,
&
readSet
)){
NDB_SOCKET_TYPE
childSock
=
accept
(
si
.
m_socket
,
0
,
0
);
if
(
childSock
==
NDB_INVALID_SOCKET
){
continue
;
...
...
ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
View file @
7e89c72a
...
...
@@ -480,7 +480,6 @@ void Cmvmi::execDISCONNECT_REP(Signal *signal)
void
Cmvmi
::
execCONNECT_REP
(
Signal
*
signal
){
const
Uint32
hostId
=
signal
->
theData
[
0
];
jamEntry
();
const
NodeInfo
::
NodeType
type
=
(
NodeInfo
::
NodeType
)
getNodeInfo
(
hostId
).
m_type
;
...
...
ndb/src/kernel/blocks/ndbcntr/NdbcntrMain.cpp
View file @
7e89c72a
...
...
@@ -554,11 +554,13 @@ Ndbcntr::execCNTR_START_REP(Signal* signal){
}
if
(
cmasterNodeId
!=
getOwnNodeId
()){
jam
();
c_start
.
reset
();
return
;
}
if
(
c_start
.
m_waiting
.
isclear
()){
jam
();
c_start
.
reset
();
return
;
}
...
...
@@ -597,6 +599,7 @@ Ndbcntr::execCNTR_START_REQ(Signal * signal){
ndbrequire
(
false
);
case
NodeState
:
:
SL_STARTING
:
case
NodeState
:
:
SL_STARTED
:
jam
();
break
;
case
NodeState
:
:
SL_STOPPING_1
:
...
...
@@ -616,9 +619,11 @@ Ndbcntr::execCNTR_START_REQ(Signal * signal){
c_start
.
m_waiting
.
set
(
nodeId
);
switch
(
st
){
case
NodeState
:
:
ST_INITIAL_START
:
jam
();
c_start
.
m_withoutLog
.
set
(
nodeId
);
break
;
case
NodeState
:
:
ST_SYSTEM_RESTART
:
jam
();
c_start
.
m_withLog
.
set
(
nodeId
);
if
(
starting
&&
lastGci
>
c_start
.
m_lastGci
){
jam
();
...
...
@@ -631,6 +636,7 @@ Ndbcntr::execCNTR_START_REQ(Signal * signal){
return
;
}
if
(
starting
){
jam
();
Uint32
i
=
c_start
.
m_logNodesCount
++
;
c_start
.
m_logNodes
[
i
].
m_nodeId
=
nodeId
;
c_start
.
m_logNodes
[
i
].
m_lastGci
=
req
->
lastGci
;
...
...
@@ -652,11 +658,12 @@ Ndbcntr::execCNTR_START_REQ(Signal * signal){
}
if
(
starting
){
jam
();
trySystemRestart
(
signal
);
}
else
{
jam
();
startWaitingNodes
(
signal
);
}
return
;
}
...
...
@@ -670,6 +677,7 @@ Ndbcntr::startWaitingNodes(Signal * signal){
NodeState
::
StartType
nrType
=
NodeState
::
ST_NODE_RESTART
;
if
(
c_start
.
m_withoutLog
.
get
(
nodeId
)){
jam
();
nrType
=
NodeState
::
ST_INITIAL_NODE_RESTART
;
}
...
...
@@ -706,6 +714,7 @@ Ndbcntr::startWaitingNodes(Signal * signal){
char
buf
[
100
];
if
(
!
c_start
.
m_withLog
.
isclear
()){
jam
();
ndbout_c
(
"Starting nodes w/ log: %s"
,
c_start
.
m_withLog
.
getText
(
buf
));
NodeReceiverGroup
rg
(
NDBCNTR
,
c_start
.
m_withLog
);
...
...
@@ -716,6 +725,7 @@ Ndbcntr::startWaitingNodes(Signal * signal){
}
if
(
!
c_start
.
m_withoutLog
.
isclear
()){
jam
();
ndbout_c
(
"Starting nodes wo/ log: %s"
,
c_start
.
m_withoutLog
.
getText
(
buf
));
NodeReceiverGroup
rg
(
NDBCNTR
,
c_start
.
m_withoutLog
);
conf
->
startType
=
NodeState
::
ST_INITIAL_NODE_RESTART
;
...
...
@@ -777,6 +787,7 @@ Ndbcntr::trySystemRestart(Signal* signal){
jam
();
return
false
;
}
jam
();
srType
=
NodeState
::
ST_INITIAL_START
;
c_start
.
m_starting
=
c_start
.
m_withoutLog
;
// Used for starting...
c_start
.
m_withoutLog
.
clear
();
...
...
@@ -793,13 +804,11 @@ Ndbcntr::trySystemRestart(Signal* signal){
// If we lose with all nodes, then we're in trouble
ndbrequire
(
!
allNodes
);
return
false
;
break
;
case
CheckNodeGroups
:
:
Partitioning
:
jam
();
bool
allowPartition
=
(
c_start
.
m_startPartitionedTimeout
!=
(
Uint64
)
~
0
);
if
(
allNodes
){
jam
();
if
(
allowPartition
){
jam
();
break
;
...
...
@@ -1043,8 +1052,10 @@ void Ndbcntr::ph5ALab(Signal* signal)
return
;
case
NodeState
:
:
ST_NODE_RESTART
:
case
NodeState
:
:
ST_INITIAL_NODE_RESTART
:
jam
();
break
;
case
NodeState
:
:
ST_ILLEGAL_TYPE
:
jam
();
break
;
}
ndbrequire
(
false
);
...
...
ndb/src/kernel/blocks/qmgr/QmgrMain.cpp
View file @
7e89c72a
...
...
@@ -258,7 +258,6 @@ void Qmgr::execCONNECT_REP(Signal* signal)
{
const
Uint32
nodeId
=
signal
->
theData
[
0
];
c_connectedNodes
.
set
(
nodeId
);
NodeRecPtr
nodePtr
;
nodePtr
.
i
=
getOwnNodeId
();
ptrCheckGuard
(
nodePtr
,
MAX_NODES
,
nodeRec
);
...
...
@@ -679,7 +678,6 @@ void Qmgr::execCM_REGREF(Signal* signal)
UintR
TaddNodeno
=
signal
->
theData
[
1
];
UintR
TrefuseReason
=
signal
->
theData
[
2
];
Uint32
candidate
=
signal
->
theData
[
3
];
DEBUG_START3
(
signal
,
TrefuseReason
);
if
(
candidate
!=
cpresidentCandidate
){
...
...
@@ -768,7 +766,6 @@ void Qmgr::execCM_REGREF(Signal* signal)
Uint64
now
=
NdbTick_CurrentMillisecond
();
if
((
c_regReqReqRecv
==
cnoOfNodes
)
||
now
>
c_stopElectionTime
){
jam
();
electionWon
();
sendSttorryLab
(
signal
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment