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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
496ad0c3
Commit
496ad0c3
authored
Jul 08, 2004
by
joreland@mysql.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BUG#3963
parent
e18b384b
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
53 additions
and
32 deletions
+53
-32
ndb/src/kernel/blocks/dbtc/Dbtc.hpp
ndb/src/kernel/blocks/dbtc/Dbtc.hpp
+1
-1
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp
+31
-25
ndb/src/mgmapi/mgmapi.cpp
ndb/src/mgmapi/mgmapi.cpp
+1
-1
ndb/test/run-test/daily-basic-tests.txt
ndb/test/run-test/daily-basic-tests.txt
+4
-0
ndb/test/run-test/main.cpp
ndb/test/run-test/main.cpp
+16
-5
No files found.
ndb/src/kernel/blocks/dbtc/Dbtc.hpp
View file @
496ad0c3
...
@@ -1391,7 +1391,7 @@ private:
...
@@ -1391,7 +1391,7 @@ private:
void
sendCompleteLqh
(
Signal
*
signal
,
void
sendCompleteLqh
(
Signal
*
signal
,
TcConnectRecord
*
const
regTcPtr
);
TcConnectRecord
*
const
regTcPtr
);
void
sendTCKEY_FAILREF
(
Signal
*
signal
,
const
ApiConnectRecord
*
);
void
sendTCKEY_FAILREF
(
Signal
*
signal
,
const
ApiConnectRecord
*
);
void
sendTCKEY_FAILCONF
(
Signal
*
signal
,
const
ApiConnectRecord
*
);
void
sendTCKEY_FAILCONF
(
Signal
*
signal
,
ApiConnectRecord
*
);
void
checkStartTimeout
(
Signal
*
signal
);
void
checkStartTimeout
(
Signal
*
signal
);
void
checkStartFragTimeout
(
Signal
*
signal
);
void
checkStartFragTimeout
(
Signal
*
signal
);
void
timeOutFoundFragLab
(
Signal
*
signal
,
Uint32
TscanConPtr
);
void
timeOutFoundFragLab
(
Signal
*
signal
,
Uint32
TscanConPtr
);
...
...
ndb/src/kernel/blocks/dbtc/DbtcMain.cpp
View file @
496ad0c3
...
@@ -1048,13 +1048,12 @@ Dbtc::handleFailedApiNode(Signal* signal,
...
@@ -1048,13 +1048,12 @@ Dbtc::handleFailedApiNode(Signal* signal,
apiConnectptr
.
i
++
;
apiConnectptr
.
i
++
;
if
(
apiConnectptr
.
i
>
((
capiConnectFilesize
/
3
)
-
1
))
{
if
(
apiConnectptr
.
i
>
((
capiConnectFilesize
/
3
)
-
1
))
{
jam
();
jam
();
capiConnectClosing
[
TapiFailedNode
]
--
;
/**
/**
* Finished with scanning connection record
* Finished with scanning connection record
*
*
* Now scan markers
* Now scan markers
*/
*/
removeMarkerForFailedAPI
(
signal
,
TapiFailedNode
,
RNIL
);
// RNIL = first
removeMarkerForFailedAPI
(
signal
,
TapiFailedNode
,
0
);
return
;
return
;
}
//if
}
//if
}
while
(
TloopCount
++
<
256
);
}
while
(
TloopCount
++
<
256
);
...
@@ -1069,16 +1068,27 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
...
@@ -1069,16 +1068,27 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
Uint32
nodeId
,
Uint32
nodeId
,
Uint32
startBucket
)
Uint32
startBucket
)
{
{
CommitAckMarkerIterator
iter
;
TcFailRecordPtr
node_fail_ptr
;
if
(
startBucket
==
RNIL
){
node_fail_ptr
.
i
=
0
;
jam
();
ptrAss
(
node_fail_ptr
,
tcFailRecord
);
capiConnectClosing
[
nodeId
]
++
;
if
(
node_fail_ptr
.
p
->
failStatus
!=
FS_IDLE
)
{
m_commitAckMarkerHash
.
next
(
0
,
iter
);
}
else
{
jam
();
jam
();
m_commitAckMarkerHash
.
next
(
startBucket
,
iter
);
DEBUG
(
"Restarting removeMarkerForFailedAPI"
);
/**
* TC take-over in progress
* needs to restart as this
* creates new markers
*/
signal
->
theData
[
0
]
=
TcContinueB
::
ZHANDLE_FAILED_API_NODE_REMOVE_MARKERS
;
signal
->
theData
[
1
]
=
nodeId
;
signal
->
theData
[
2
]
=
0
;
sendSignalWithDelay
(
cownref
,
GSN_CONTINUEB
,
signal
,
500
,
3
);
return
;
}
}
CommitAckMarkerIterator
iter
;
m_commitAckMarkerHash
.
next
(
startBucket
,
iter
);
const
Uint32
RT_BREAK
=
256
;
const
Uint32
RT_BREAK
=
256
;
for
(
Uint32
i
=
0
;
i
<
RT_BREAK
||
iter
.
bucket
==
startBucket
;
i
++
){
for
(
Uint32
i
=
0
;
i
<
RT_BREAK
||
iter
.
bucket
==
startBucket
;
i
++
){
jam
();
jam
();
...
@@ -1108,7 +1118,6 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
...
@@ -1108,7 +1118,6 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
/**
/**
* Check so that the record is not still in use
* Check so that the record is not still in use
*
*
* (This can happen when NF and API Fail happens at the same time)
*/
*/
ApiConnectRecordPtr
apiConnectPtr
;
ApiConnectRecordPtr
apiConnectPtr
;
apiConnectPtr
.
i
=
iter
.
curr
.
p
->
apiConnectPtr
;
apiConnectPtr
.
i
=
iter
.
curr
.
p
->
apiConnectPtr
;
...
@@ -1122,7 +1131,6 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
...
@@ -1122,7 +1131,6 @@ Dbtc::removeMarkerForFailedAPI(Signal* signal,
*/
*/
break
;
break
;
}
}
sendRemoveMarkers
(
signal
,
iter
.
curr
.
p
);
sendRemoveMarkers
(
signal
,
iter
.
curr
.
p
);
m_commitAckMarkerHash
.
release
(
iter
.
curr
);
m_commitAckMarkerHash
.
release
(
iter
.
curr
);
...
@@ -7327,25 +7335,23 @@ Dbtc::sendTCKEY_FAILREF(Signal* signal, const ApiConnectRecord * regApiPtr){
...
@@ -7327,25 +7335,23 @@ Dbtc::sendTCKEY_FAILREF(Signal* signal, const ApiConnectRecord * regApiPtr){
}
}
void
void
Dbtc
::
sendTCKEY_FAILCONF
(
Signal
*
signal
,
const
ApiConnectRecord
*
regApiPtr
){
Dbtc
::
sendTCKEY_FAILCONF
(
Signal
*
signal
,
ApiConnectRecord
*
regApiPtr
){
jam
();
jam
();
TcKeyFailConf
*
const
failConf
=
(
TcKeyFailConf
*
)
&
signal
->
theData
[
0
];
TcKeyFailConf
*
const
failConf
=
(
TcKeyFailConf
*
)
&
signal
->
theData
[
0
];
if
(
regApiPtr
->
commitAckMarker
==
RNIL
){
const
Uint32
ref
=
regApiPtr
->
ndbapiBlockref
;
jam
();
const
Uint32
marker
=
regApiPtr
->
commitAckMarker
;
failConf
->
apiConnectPtr
=
regApiPtr
->
ndbapiConnect
;
if
(
ref
!=
0
){
}
else
{
failConf
->
apiConnectPtr
=
regApiPtr
->
ndbapiConnect
|
(
marker
!=
RNIL
);
jam
();
failConf
->
apiConnectPtr
=
regApiPtr
->
ndbapiConnect
|
1
;
}
failConf
->
transId1
=
regApiPtr
->
transid
[
0
];
failConf
->
transId1
=
regApiPtr
->
transid
[
0
];
failConf
->
transId2
=
regApiPtr
->
transid
[
1
];
failConf
->
transId2
=
regApiPtr
->
transid
[
1
];
sendSignal
(
regApiPtr
->
ndbapiBlockref
,
sendSignal
(
regApiPtr
->
ndbapiBlockref
,
GSN_TCKEY_FAILCONF
,
signal
,
TcKeyFailConf
::
SignalLength
,
JBB
);
GSN_TCKEY_FAILCONF
,
signal
,
TcKeyFailConf
::
SignalLength
,
JBB
);
}
regApiPtr
->
commitAckMarker
=
RNIL
;
}
}
/*------------------------------------------------------------*/
/*------------------------------------------------------------*/
/* THIS PART HANDLES THE ABORT PHASE IN THE CASE OF A */
/* THIS PART HANDLES THE ABORT PHASE IN THE CASE OF A */
/* NODE FAILURE BEFORE THE COMMIT DECISION. */
/* NODE FAILURE BEFORE THE COMMIT DECISION. */
...
...
ndb/src/mgmapi/mgmapi.cpp
View file @
496ad0c3
...
@@ -544,7 +544,7 @@ ndb_mgm_get_status(NdbMgmHandle handle)
...
@@ -544,7 +544,7 @@ ndb_mgm_get_status(NdbMgmHandle handle)
buf
[
strlen
(
buf
)
-
1
]
=
'\0'
;
buf
[
strlen
(
buf
)
-
1
]
=
'\0'
;
if
(
strcmp
(
"node status"
,
buf
)
!=
0
)
{
if
(
strcmp
(
"node status"
,
buf
)
!=
0
)
{
SET_ERROR
(
handle
,
NDB_MGM_ILLEGAL_NODE_STATUS
,
""
);
SET_ERROR
(
handle
,
NDB_MGM_ILLEGAL_NODE_STATUS
,
buf
);
return
NULL
;
return
NULL
;
}
}
...
...
ndb/test/run-test/daily-basic-tests.txt
View file @
496ad0c3
...
@@ -139,6 +139,10 @@ max-time: 500
...
@@ -139,6 +139,10 @@ max-time: 500
cmd: testBasicAsynch
cmd: testBasicAsynch
args: -n PkDeleteAsynch
args: -n PkDeleteAsynch
max-time:
cmd: ndb_drop_table
args: T1 T2 T3 T4 T5 T6 T7 T8 T9 T10 T11 T12 T13 T14
max-time: 500
max-time: 500
cmd: testBasic
cmd: testBasic
args: -n MassiveRollback T1 T6 T13
args: -n MassiveRollback T1 T6 T13
...
...
ndb/test/run-test/main.cpp
View file @
496ad0c3
...
@@ -614,11 +614,22 @@ wait_ndb(atrt_config& config, int goal){
...
@@ -614,11 +614,22 @@ wait_ndb(atrt_config& config, int goal){
/**
/**
* 1) retreive current state
* 1) retreive current state
*/
*/
state
=
0
;
do
{
state
=
ndb_mgm_get_status
(
handle
);
state
=
ndb_mgm_get_status
(
handle
);
if
(
state
==
0
){
if
(
state
==
0
){
g_logger
.
critical
(
"Unable to poll db state"
);
const
int
err
=
ndb_mgm_get_latest_error
(
handle
);
g_logger
.
error
(
"Unable to poll db state: %d %s %s"
,
ndb_mgm_get_latest_error
(
handle
),
ndb_mgm_get_latest_error_msg
(
handle
),
ndb_mgm_get_latest_error_desc
(
handle
));
if
(
err
==
NDB_MGM_SERVER_NOT_CONNECTED
&&
connect_ndb_mgm
(
config
)){
g_logger
.
error
(
"Reconnected..."
);
continue
;
}
return
false
;
return
false
;
}
}
}
while
(
state
==
0
);
NdbAutoPtr
<
void
>
tmp
(
state
);
NdbAutoPtr
<
void
>
tmp
(
state
);
min2
=
goal
;
min2
=
goal
;
...
...
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