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
6e68423d
Commit
6e68423d
authored
Jun 09, 2006
by
tomas@poseidon.ndb.mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge poseidon.ndb.mysql.com:/home/tomas/mysql-5.0
into poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
parents
5af1d8de
a6294a33
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
38 additions
and
36 deletions
+38
-36
storage/ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
storage/ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
+3
-2
storage/ndb/src/mgmsrv/MgmtSrvr.cpp
storage/ndb/src/mgmsrv/MgmtSrvr.cpp
+28
-27
storage/ndb/src/mgmsrv/MgmtSrvr.hpp
storage/ndb/src/mgmsrv/MgmtSrvr.hpp
+0
-2
storage/ndb/src/mgmsrv/Services.cpp
storage/ndb/src/mgmsrv/Services.cpp
+7
-5
No files found.
storage/ndb/src/kernel/blocks/cmvmi/Cmvmi.cpp
View file @
6e68423d
...
@@ -234,6 +234,7 @@ void Cmvmi::execEVENT_REP(Signal* signal)
...
@@ -234,6 +234,7 @@ void Cmvmi::execEVENT_REP(Signal* signal)
void
void
Cmvmi
::
execEVENT_SUBSCRIBE_REQ
(
Signal
*
signal
){
Cmvmi
::
execEVENT_SUBSCRIBE_REQ
(
Signal
*
signal
){
EventSubscribeReq
*
subReq
=
(
EventSubscribeReq
*
)
&
signal
->
theData
[
0
];
EventSubscribeReq
*
subReq
=
(
EventSubscribeReq
*
)
&
signal
->
theData
[
0
];
Uint32
senderRef
=
signal
->
getSendersBlockRef
();
SubscriberPtr
ptr
;
SubscriberPtr
ptr
;
jamEntry
();
jamEntry
();
DBUG_ENTER
(
"Cmvmi::execEVENT_SUBSCRIBE_REQ"
);
DBUG_ENTER
(
"Cmvmi::execEVENT_SUBSCRIBE_REQ"
);
...
@@ -251,7 +252,7 @@ Cmvmi::execEVENT_SUBSCRIBE_REQ(Signal * signal){
...
@@ -251,7 +252,7 @@ Cmvmi::execEVENT_SUBSCRIBE_REQ(Signal * signal){
* Create a new one
* Create a new one
*/
*/
if
(
subscribers
.
seize
(
ptr
)
==
false
){
if
(
subscribers
.
seize
(
ptr
)
==
false
){
sendSignal
(
s
ubReq
->
block
Ref
,
GSN_EVENT_SUBSCRIBE_REF
,
signal
,
1
,
JBB
);
sendSignal
(
s
ender
Ref
,
GSN_EVENT_SUBSCRIBE_REF
,
signal
,
1
,
JBB
);
return
;
return
;
}
}
ptr
.
p
->
logLevel
.
clear
();
ptr
.
p
->
logLevel
.
clear
();
...
@@ -278,7 +279,7 @@ Cmvmi::execEVENT_SUBSCRIBE_REQ(Signal * signal){
...
@@ -278,7 +279,7 @@ Cmvmi::execEVENT_SUBSCRIBE_REQ(Signal * signal){
}
}
signal
->
theData
[
0
]
=
ptr
.
i
;
signal
->
theData
[
0
]
=
ptr
.
i
;
sendSignal
(
ptr
.
p
->
block
Ref
,
GSN_EVENT_SUBSCRIBE_CONF
,
signal
,
1
,
JBB
);
sendSignal
(
sender
Ref
,
GSN_EVENT_SUBSCRIBE_CONF
,
signal
,
1
,
JBB
);
DBUG_VOID_RETURN
;
DBUG_VOID_RETURN
;
}
}
...
...
storage/ndb/src/mgmsrv/MgmtSrvr.cpp
View file @
6e68423d
...
@@ -1499,7 +1499,8 @@ int
...
@@ -1499,7 +1499,8 @@ int
MgmtSrvr
::
setEventReportingLevelImpl
(
int
nodeId
,
MgmtSrvr
::
setEventReportingLevelImpl
(
int
nodeId
,
const
EventSubscribeReq
&
ll
)
const
EventSubscribeReq
&
ll
)
{
{
INIT_SIGNAL_SENDER
(
ss
,
nodeId
);
SignalSender
ss
(
theFacade
);
ss
.
lock
();
SimpleSignal
ssig
;
SimpleSignal
ssig
;
EventSubscribeReq
*
dst
=
EventSubscribeReq
*
dst
=
...
@@ -1508,41 +1509,54 @@ MgmtSrvr::setEventReportingLevelImpl(int nodeId,
...
@@ -1508,41 +1509,54 @@ MgmtSrvr::setEventReportingLevelImpl(int nodeId,
EventSubscribeReq
::
SignalLength
);
EventSubscribeReq
::
SignalLength
);
*
dst
=
ll
;
*
dst
=
ll
;
send
(
ss
,
ssig
,
nodeId
,
NODE_TYPE_DB
);
NodeBitmask
nodes
;
nodes
.
clear
();
Uint32
max
=
(
nodeId
==
0
)
?
(
nodeId
=
1
,
MAX_NDB_NODES
)
:
nodeId
;
for
(;
nodeId
<=
max
;
nodeId
++
)
{
if
(
nodeTypes
[
nodeId
]
!=
NODE_TYPE_DB
)
continue
;
if
(
okToSendTo
(
nodeId
,
false
))
continue
;
if
(
ss
.
sendSignal
(
nodeId
,
&
ssig
)
==
SEND_OK
)
{
nodes
.
set
(
nodeId
);
}
}
#if 0
int
error
=
0
;
while (
1
)
while
(
!
nodes
.
isclear
()
)
{
{
SimpleSignal
*
signal
=
ss
.
waitFor
();
SimpleSignal
*
signal
=
ss
.
waitFor
();
int
gsn
=
signal
->
readSignalNumber
();
int
gsn
=
signal
->
readSignalNumber
();
nodeId
=
refToNode
(
signal
->
header
.
theSendersBlockRef
);
switch
(
gsn
)
{
switch
(
gsn
)
{
case
GSN_EVENT_SUBSCRIBE_CONF
:{
case
GSN_EVENT_SUBSCRIBE_CONF
:{
nodes
.
clear
(
nodeId
);
break
;
break
;
}
}
case
GSN_EVENT_SUBSCRIBE_REF
:{
case
GSN_EVENT_SUBSCRIBE_REF
:{
return SEND_OR_RECEIVE_FAILED;
nodes
.
clear
(
nodeId
);
error
=
1
;
break
;
}
}
case
GSN_NF_COMPLETEREP
:{
case
GSN_NF_COMPLETEREP
:{
const
NFCompleteRep
*
const
rep
=
const
NFCompleteRep
*
const
rep
=
CAST_CONSTPTR
(
NFCompleteRep
,
signal
->
getDataPtr
());
CAST_CONSTPTR
(
NFCompleteRep
,
signal
->
getDataPtr
());
if (rep->failedNodeId == nodeId)
nodes
.
clear
(
rep
->
failedNodeId
);
return SEND_OR_RECEIVE_FAILED;
break
;
break
;
}
}
case
GSN_NODE_FAILREP
:{
case
GSN_NODE_FAILREP
:{
const NodeFailRep * const rep =
// ignore, NF_COMPLETEREP will arrive later
CAST_CONSTPTR(NodeFailRep, signal->getDataPtr());
if (NodeBitmask::get(rep->theNodes,nodeId))
return SEND_OR_RECEIVE_FAILED;
break
;
break
;
}
}
default:
default:
report_unknown_signal
(
signal
);
report_unknown_signal
(
signal
);
return
SEND_OR_RECEIVE_FAILED
;
return
SEND_OR_RECEIVE_FAILED
;
}
}
}
}
#endif
if
(
error
)
return
SEND_OR_RECEIVE_FAILED
;
return
0
;
return
0
;
}
}
...
@@ -1562,19 +1576,6 @@ MgmtSrvr::setNodeLogLevelImpl(int nodeId, const SetLogLevelOrd & ll)
...
@@ -1562,19 +1576,6 @@ MgmtSrvr::setNodeLogLevelImpl(int nodeId, const SetLogLevelOrd & ll)
return
ss
.
sendSignal
(
nodeId
,
&
ssig
)
==
SEND_OK
?
0
:
SEND_OR_RECEIVE_FAILED
;
return
ss
.
sendSignal
(
nodeId
,
&
ssig
)
==
SEND_OK
?
0
:
SEND_OR_RECEIVE_FAILED
;
}
}
int
MgmtSrvr
::
send
(
SignalSender
&
ss
,
SimpleSignal
&
ssig
,
Uint32
node
,
Uint32
node_type
){
Uint32
max
=
(
node
==
0
)
?
MAX_NODES
:
node
+
1
;
for
(;
node
<
max
;
node
++
){
while
(
nodeTypes
[
node
]
!=
(
int
)
node_type
&&
node
<
max
)
node
++
;
if
(
nodeTypes
[
node
]
!=
(
int
)
node_type
)
break
;
ss
.
sendSignal
(
node
,
&
ssig
);
}
return
0
;
}
//****************************************************************************
//****************************************************************************
//****************************************************************************
//****************************************************************************
...
...
storage/ndb/src/mgmsrv/MgmtSrvr.hpp
View file @
6e68423d
...
@@ -486,8 +486,6 @@ public:
...
@@ -486,8 +486,6 @@ public:
private
:
private
:
//**************************************************************************
//**************************************************************************
int
send
(
SignalSender
&
ss
,
SimpleSignal
&
ssig
,
Uint32
node
,
Uint32
node_type
);
int
sendStopMgmd
(
NodeId
nodeId
,
int
sendStopMgmd
(
NodeId
nodeId
,
bool
abort
,
bool
abort
,
bool
stop
,
bool
stop
,
...
...
storage/ndb/src/mgmsrv/Services.cpp
View file @
6e68423d
...
@@ -813,9 +813,8 @@ MgmApiSession::setClusterLogLevel(Parser<MgmApiSession>::Context &,
...
@@ -813,9 +813,8 @@ MgmApiSession::setClusterLogLevel(Parser<MgmApiSession>::Context &,
m_mgmsrv
.
m_event_listner
.
unlock
();
m_mgmsrv
.
m_event_listner
.
unlock
();
{
{
LogLevel
ll
;
LogLevel
tmp
;
ll
.
setLogLevel
(
category
,
level
);
m_mgmsrv
.
m_event_listner
.
update_max_log_level
(
tmp
);
m_mgmsrv
.
m_event_listner
.
update_max_log_level
(
ll
);
}
}
m_output
->
println
(
reply
);
m_output
->
println
(
reply
);
...
@@ -1302,8 +1301,11 @@ Ndb_mgmd_event_service::log(int eventType, const Uint32* theData, NodeId nodeId)
...
@@ -1302,8 +1301,11 @@ Ndb_mgmd_event_service::log(int eventType, const Uint32* theData, NodeId nodeId)
void
void
Ndb_mgmd_event_service
::
update_max_log_level
(
const
LogLevel
&
log_level
)
Ndb_mgmd_event_service
::
update_max_log_level
(
const
LogLevel
&
log_level
)
{
{
LogLevel
tmp
=
m_logLevel
;
LogLevel
tmp
=
log_level
;
tmp
.
set_max
(
log_level
);
m_clients
.
lock
();
for
(
int
i
=
m_clients
.
size
()
-
1
;
i
>=
0
;
i
--
)
tmp
.
set_max
(
m_clients
[
i
].
m_logLevel
);
m_clients
.
unlock
();
update_log_level
(
tmp
);
update_log_level
(
tmp
);
}
}
...
...
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