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
f3513a79
Commit
f3513a79
authored
Oct 21, 2004
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
more snprintf...
parent
63920158
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
126 additions
and
126 deletions
+126
-126
ndb/src/common/debugger/EventLogger.cpp
ndb/src/common/debugger/EventLogger.cpp
+105
-105
ndb/src/common/logger/FileLogHandler.cpp
ndb/src/common/logger/FileLogHandler.cpp
+2
-2
ndb/src/common/logger/LogHandler.cpp
ndb/src/common/logger/LogHandler.cpp
+2
-2
ndb/src/common/logger/listtest/LogHandlerListUnitTest.cpp
ndb/src/common/logger/listtest/LogHandlerListUnitTest.cpp
+1
-1
ndb/src/common/logger/loggertest/LoggerUnitTest.cpp
ndb/src/common/logger/loggertest/LoggerUnitTest.cpp
+1
-1
ndb/src/common/util/File.cpp
ndb/src/common/util/File.cpp
+2
-2
ndb/src/common/util/NdbErrHnd.cpp
ndb/src/common/util/NdbErrHnd.cpp
+8
-8
ndb/src/mgmsrv/ConfigInfo.cpp
ndb/src/mgmsrv/ConfigInfo.cpp
+4
-4
ndb/test/ndbapi/userInterface.cpp
ndb/test/ndbapi/userInterface.cpp
+1
-1
No files found.
ndb/src/common/debugger/EventLogger.cpp
View file @
f3513a79
...
@@ -127,7 +127,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -127,7 +127,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// TODO: Change the switch implementation...
// TODO: Change the switch implementation...
char
theNodeId
[
32
];
char
theNodeId
[
32
];
if
(
nodeId
!=
0
){
if
(
nodeId
!=
0
){
::
snprintf
(
theNodeId
,
32
,
"Node %u: "
,
nodeId
);
BaseString
::
snprintf
(
theNodeId
,
32
,
"Node %u: "
,
nodeId
);
}
else
{
}
else
{
theNodeId
[
0
]
=
0
;
theNodeId
[
0
]
=
0
;
}
}
...
@@ -135,13 +135,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -135,13 +135,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
EventReport
::
EventType
eventType
=
(
EventReport
::
EventType
)
type
;
EventReport
::
EventType
eventType
=
(
EventReport
::
EventType
)
type
;
switch
(
eventType
){
switch
(
eventType
){
case
EventReport
:
:
Connected
:
case
EventReport
:
:
Connected
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode %u Connected"
,
"%sNode %u Connected"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
ConnectedApiVersion
:
case
EventReport
:
:
ConnectedApiVersion
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode %u: API version %d.%d.%d"
,
"%sNode %u: API version %d.%d.%d"
,
theNodeId
,
theNodeId
,
theData
[
1
],
theData
[
1
],
...
@@ -150,7 +150,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -150,7 +150,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
getBuild
(
theData
[
2
]));
getBuild
(
theData
[
2
]));
break
;
break
;
case
EventReport
:
:
Disconnected
:
case
EventReport
:
:
Disconnected
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode %u Disconnected"
,
"%sNode %u Disconnected"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
...
@@ -159,7 +159,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -159,7 +159,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT communication to node closed.
// REPORT communication to node closed.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sCommunication to Node %u closed"
,
"%sCommunication to Node %u closed"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
...
@@ -168,7 +168,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -168,7 +168,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT communication to node opened.
// REPORT communication to node opened.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sCommunication to Node %u opened"
,
"%sCommunication to Node %u opened"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
...
@@ -177,7 +177,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -177,7 +177,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// Start of NDB has been initiated.
// Start of NDB has been initiated.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sStart initiated (version %d.%d.%d)"
,
"%sStart initiated (version %d.%d.%d)"
,
theNodeId
,
theNodeId
,
getMajor
(
theData
[
1
]),
getMajor
(
theData
[
1
]),
...
@@ -185,13 +185,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -185,13 +185,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
getBuild
(
theData
[
1
]));
getBuild
(
theData
[
1
]));
break
;
break
;
case
EventReport
:
:
NDBStopStarted
:
case
EventReport
:
:
NDBStopStarted
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%s%s shutdown initiated"
,
"%s%s shutdown initiated"
,
theNodeId
,
theNodeId
,
(
theData
[
1
]
==
1
?
"Cluster"
:
"Node"
));
(
theData
[
1
]
==
1
?
"Cluster"
:
"Node"
));
break
;
break
;
case
EventReport
:
:
NDBStopAborted
:
case
EventReport
:
:
NDBStopAborted
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode shutdown aborted"
,
"%sNode shutdown aborted"
,
theNodeId
);
theNodeId
);
break
;
break
;
...
@@ -199,7 +199,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -199,7 +199,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// Start of NDB has been completed.
// Start of NDB has been completed.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sStarted (version %d.%d.%d)"
,
"%sStarted (version %d.%d.%d)"
,
theNodeId
,
theNodeId
,
getMajor
(
theData
[
1
]),
getMajor
(
theData
[
1
]),
...
@@ -211,7 +211,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -211,7 +211,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// STTORRY recevied after restart finished.
// STTORRY recevied after restart finished.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sSTTORRY received after restart finished"
,
"%sSTTORRY received after restart finished"
,
theNodeId
);
theNodeId
);
break
;
break
;
...
@@ -237,7 +237,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -237,7 +237,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
type
=
""
;
type
=
""
;
break
;
break
;
default:
{
default:
{
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sStart phase %u completed (unknown = %d)"
,
"%sStart phase %u completed (unknown = %d)"
,
theNodeId
,
theNodeId
,
theData
[
1
],
theData
[
1
],
...
@@ -245,7 +245,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -245,7 +245,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
return
m_text
;
return
m_text
;
}
}
}
}
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sStart phase %u completed %s"
,
"%sStart phase %u completed %s"
,
theNodeId
,
theNodeId
,
theData
[
1
],
theData
[
1
],
...
@@ -254,7 +254,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -254,7 +254,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
break
;
break
;
}
}
case
EventReport
:
:
CM_REGCONF
:
case
EventReport
:
:
CM_REGCONF
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sCM_REGCONF president = %u, own Node = %u, our dynamic id = %u"
"%sCM_REGCONF president = %u, own Node = %u, our dynamic id = %u"
,
,
theNodeId
,
theNodeId
,
...
@@ -286,7 +286,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -286,7 +286,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
break
;
break
;
}
//switch
}
//switch
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sCM_REGREF from Node %u to our Node %u. Cause = %s"
,
"%sCM_REGREF from Node %u to our Node %u. Cause = %s"
,
theNodeId
,
theNodeId
,
theData
[
2
],
theData
[
2
],
...
@@ -298,7 +298,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -298,7 +298,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Node Restart copied a fragment.
// REPORT Node Restart copied a fragment.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sWe are Node %u with dynamic ID %u, our left neighbour "
"%sWe are Node %u with dynamic ID %u, our left neighbour "
"is Node %u, our right is Node %u"
,
"is Node %u, our right is Node %u"
,
...
@@ -315,13 +315,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -315,13 +315,13 @@ EventLogger::getText(char * m_text, size_t m_text_len,
if
(
theData
[
1
]
==
0
)
if
(
theData
[
1
]
==
0
)
{
{
if
(
theData
[
3
]
!=
0
)
{
if
(
theData
[
3
]
!=
0
)
{
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode %u completed failure of Node %u"
,
"%sNode %u completed failure of Node %u"
,
theNodeId
,
theNodeId
,
theData
[
3
],
theData
[
3
],
theData
[
2
]);
theData
[
2
]);
}
else
{
}
else
{
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sAll nodes completed failure of Node %u"
,
"%sAll nodes completed failure of Node %u"
,
theNodeId
,
theNodeId
,
theData
[
2
]);
theData
[
2
]);
...
@@ -338,7 +338,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -338,7 +338,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
line
=
"DBLQH"
;
line
=
"DBLQH"
;
}
}
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNode failure of %u %s completed"
,
"%sNode failure of %u %s completed"
,
theNodeId
,
theNodeId
,
theData
[
2
],
theData
[
2
],
...
@@ -346,7 +346,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -346,7 +346,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
}
}
break
;
break
;
case
EventReport
:
:
NODE_FAILREP
:
case
EventReport
:
:
NODE_FAILREP
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode %u has failed. The Node state at failure "
"%sNode %u has failed. The Node state at failure "
"was %u"
,
"was %u"
,
...
@@ -366,41 +366,41 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -366,41 +366,41 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
unsigned
state
=
sd
->
code
>>
16
;
const
unsigned
state
=
sd
->
code
>>
16
;
switch
(
code
)
{
switch
(
code
)
{
case
ArbitCode
:
:
ThreadStart
:
case
ArbitCode
:
:
ThreadStart
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sPresident restarts arbitration thread [state=%u]"
,
"%sPresident restarts arbitration thread [state=%u]"
,
theNodeId
,
state
);
theNodeId
,
state
);
break
;
break
;
case
ArbitCode
:
:
PrepPart2
:
case
ArbitCode
:
:
PrepPart2
:
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sPrepare arbitrator node %u [ticket=%s]"
,
"%sPrepare arbitrator node %u [ticket=%s]"
,
theNodeId
,
sd
->
node
,
ticketText
);
theNodeId
,
sd
->
node
,
ticketText
);
break
;
break
;
case
ArbitCode
:
:
PrepAtrun
:
case
ArbitCode
:
:
PrepAtrun
:
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sReceive arbitrator node %u [ticket=%s]"
,
"%sReceive arbitrator node %u [ticket=%s]"
,
theNodeId
,
sd
->
node
,
ticketText
);
theNodeId
,
sd
->
node
,
ticketText
);
break
;
break
;
case
ArbitCode
:
:
ApiStart
:
case
ArbitCode
:
:
ApiStart
:
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
sd
->
ticket
.
getText
(
ticketText
,
sizeof
(
ticketText
));
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sStarted arbitrator node %u [ticket=%s]"
,
"%sStarted arbitrator node %u [ticket=%s]"
,
theNodeId
,
sd
->
node
,
ticketText
);
theNodeId
,
sd
->
node
,
ticketText
);
break
;
break
;
case
ArbitCode
:
:
ApiFail
:
case
ArbitCode
:
:
ApiFail
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sLost arbitrator node %u - process failure [state=%u]"
,
"%sLost arbitrator node %u - process failure [state=%u]"
,
theNodeId
,
sd
->
node
,
state
);
theNodeId
,
sd
->
node
,
state
);
break
;
break
;
case
ArbitCode
:
:
ApiExit
:
case
ArbitCode
:
:
ApiExit
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sLost arbitrator node %u - process exit [state=%u]"
,
"%sLost arbitrator node %u - process exit [state=%u]"
,
theNodeId
,
sd
->
node
,
state
);
theNodeId
,
sd
->
node
,
state
);
break
;
break
;
default:
default:
ArbitCode
::
getErrText
(
code
,
errText
,
sizeof
(
errText
));
ArbitCode
::
getErrText
(
code
,
errText
,
sizeof
(
errText
));
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sLost arbitrator node %u - %s [state=%u]"
,
"%sLost arbitrator node %u - %s [state=%u]"
,
theNodeId
,
sd
->
node
,
errText
,
state
);
theNodeId
,
sd
->
node
,
errText
,
state
);
break
;
break
;
...
@@ -417,48 +417,48 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -417,48 +417,48 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
unsigned
state
=
sd
->
code
>>
16
;
const
unsigned
state
=
sd
->
code
>>
16
;
switch
(
code
)
{
switch
(
code
)
{
case
ArbitCode
:
:
LoseNodes
:
case
ArbitCode
:
:
LoseNodes
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration check lost - less than 1/2 nodes left"
,
"%sArbitration check lost - less than 1/2 nodes left"
,
theNodeId
);
theNodeId
);
break
;
break
;
case
ArbitCode
:
:
WinGroups
:
case
ArbitCode
:
:
WinGroups
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration check won - node group majority"
,
"%sArbitration check won - node group majority"
,
theNodeId
);
theNodeId
);
break
;
break
;
case
ArbitCode
:
:
LoseGroups
:
case
ArbitCode
:
:
LoseGroups
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration check lost - missing node group"
,
"%sArbitration check lost - missing node group"
,
theNodeId
);
theNodeId
);
break
;
break
;
case
ArbitCode
:
:
Partitioning
:
case
ArbitCode
:
:
Partitioning
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNetwork partitioning - arbitration required"
,
"%sNetwork partitioning - arbitration required"
,
theNodeId
);
theNodeId
);
break
;
break
;
case
ArbitCode
:
:
WinChoose
:
case
ArbitCode
:
:
WinChoose
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration won - positive reply from node %u"
,
"%sArbitration won - positive reply from node %u"
,
theNodeId
,
sd
->
node
);
theNodeId
,
sd
->
node
);
break
;
break
;
case
ArbitCode
:
:
LoseChoose
:
case
ArbitCode
:
:
LoseChoose
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration lost - negative reply from node %u"
,
"%sArbitration lost - negative reply from node %u"
,
theNodeId
,
sd
->
node
);
theNodeId
,
sd
->
node
);
break
;
break
;
case
ArbitCode
:
:
LoseNorun
:
case
ArbitCode
:
:
LoseNorun
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNetwork partitioning - no arbitrator available"
,
"%sNetwork partitioning - no arbitrator available"
,
theNodeId
);
theNodeId
);
break
;
break
;
case
ArbitCode
:
:
LoseNocfg
:
case
ArbitCode
:
:
LoseNocfg
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sNetwork partitioning - no arbitrator configured"
,
"%sNetwork partitioning - no arbitrator configured"
,
theNodeId
);
theNodeId
);
break
;
break
;
default:
default:
ArbitCode
::
getErrText
(
code
,
errText
,
sizeof
(
errText
));
ArbitCode
::
getErrText
(
code
,
errText
,
sizeof
(
errText
));
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sArbitration failure - %s [state=%u]"
,
"%sArbitration failure - %s [state=%u]"
,
theNodeId
,
errText
,
state
);
theNodeId
,
errText
,
state
);
break
;
break
;
...
@@ -470,7 +470,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -470,7 +470,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// This event reports that a global checkpoint has been started and this
// This event reports that a global checkpoint has been started and this
// node is the master of this global checkpoint.
// node is the master of this global checkpoint.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sGlobal checkpoint %u started"
,
"%sGlobal checkpoint %u started"
,
theNodeId
,
theNodeId
,
...
@@ -481,7 +481,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -481,7 +481,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// This event reports that a global checkpoint has been completed on this
// This event reports that a global checkpoint has been completed on this
// node and the node is the master of this global checkpoint.
// node and the node is the master of this global checkpoint.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sGlobal checkpoint %u completed"
,
"%sGlobal checkpoint %u completed"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
...
@@ -491,7 +491,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -491,7 +491,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// This event reports that a local checkpoint has been started and this
// This event reports that a local checkpoint has been started and this
// node is the master of this local checkpoint.
// node is the master of this local checkpoint.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLocal checkpoint %u started. "
"%sLocal checkpoint %u started. "
"Keep GCI = %u oldest restorable GCI = %u"
,
"Keep GCI = %u oldest restorable GCI = %u"
,
...
@@ -505,7 +505,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -505,7 +505,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// This event reports that a local checkpoint has been completed on this
// This event reports that a local checkpoint has been completed on this
// node and the node is the master of this local checkpoint.
// node and the node is the master of this local checkpoint.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLocal checkpoint %u completed"
,
"%sLocal checkpoint %u completed"
,
theNodeId
,
theNodeId
,
...
@@ -515,14 +515,14 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -515,14 +515,14 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// This event reports that a table has been created.
// This event reports that a table has been created.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sTable with ID = %u created"
,
"%sTable with ID = %u created"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
LCPStoppedInCalcKeepGci
:
case
EventReport
:
:
LCPStoppedInCalcKeepGci
:
if
(
theData
[
1
]
==
0
)
if
(
theData
[
1
]
==
0
)
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sLocal Checkpoint stopped in CALCULATED_KEEP_GCI"
,
"%sLocal Checkpoint stopped in CALCULATED_KEEP_GCI"
,
theNodeId
);
theNodeId
);
break
;
break
;
...
@@ -530,7 +530,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -530,7 +530,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Node Restart completed copy of dictionary information.
// REPORT Node Restart completed copy of dictionary information.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode restart completed copy of dictionary information"
,
"%sNode restart completed copy of dictionary information"
,
theNodeId
);
theNodeId
);
...
@@ -539,7 +539,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -539,7 +539,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Node Restart completed copy of distribution information.
// REPORT Node Restart completed copy of distribution information.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode restart completed copy of distribution information"
,
"%sNode restart completed copy of distribution information"
,
theNodeId
);
theNodeId
);
...
@@ -548,7 +548,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -548,7 +548,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Node Restart is starting to copy the fragments.
// REPORT Node Restart is starting to copy the fragments.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode restart starting to copy the fragments "
"%sNode restart starting to copy the fragments "
"to Node %u"
,
"to Node %u"
,
...
@@ -559,7 +559,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -559,7 +559,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Node Restart copied a fragment.
// REPORT Node Restart copied a fragment.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sTable ID = %u, fragment ID = %u have been copied "
"%sTable ID = %u, fragment ID = %u have been copied "
"to Node %u"
,
"to Node %u"
,
...
@@ -569,7 +569,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -569,7 +569,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
NR_CopyFragsCompleted
:
case
EventReport
:
:
NR_CopyFragsCompleted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode restart completed copying the fragments "
"%sNode restart completed copying the fragments "
"to Node %u"
,
"to Node %u"
,
...
@@ -577,7 +577,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -577,7 +577,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
LCPFragmentCompleted
:
case
EventReport
:
:
LCPFragmentCompleted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sTable ID = %u, fragment ID = %u has completed LCP "
"%sTable ID = %u, fragment ID = %u has completed LCP "
"on Node %u"
,
"on Node %u"
,
...
@@ -590,7 +590,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -590,7 +590,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
// -------------------------------------------------------------------
// -------------------------------------------------------------------
// Report information about transaction activity once per 10 seconds.
// Report information about transaction activity once per 10 seconds.
// -------------------------------------------------------------------
// -------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sTrans. Count = %u, Commit Count = %u, "
"%sTrans. Count = %u, Commit Count = %u, "
"Read Count = %u, Simple Read Count = %u,
\n
"
"Read Count = %u, Simple Read Count = %u,
\n
"
...
@@ -610,7 +610,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -610,7 +610,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
10
]);
theData
[
10
]);
break
;
break
;
case
EventReport
:
:
OperationReportCounters
:
case
EventReport
:
:
OperationReportCounters
:
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%sOperations=%u"
,
"%sOperations=%u"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
...
@@ -619,7 +619,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -619,7 +619,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Undo Logging blocked due to buffer near to overflow.
// REPORT Undo Logging blocked due to buffer near to overflow.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sACC Blocked %u and TUP Blocked %u times last second"
,
"%sACC Blocked %u and TUP Blocked %u times last second"
,
theNodeId
,
theNodeId
,
...
@@ -628,7 +628,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -628,7 +628,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
break
;
break
;
case
EventReport
:
:
TransporterError
:
case
EventReport
:
:
TransporterError
:
case
EventReport
:
:
TransporterWarning
:
case
EventReport
:
:
TransporterWarning
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sTransporter to node %d reported error 0x%x"
,
"%sTransporter to node %d reported error 0x%x"
,
theNodeId
,
theNodeId
,
...
@@ -639,7 +639,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -639,7 +639,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Undo Logging blocked due to buffer near to overflow.
// REPORT Undo Logging blocked due to buffer near to overflow.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode %d missed heartbeat %d"
,
"%sNode %d missed heartbeat %d"
,
theNodeId
,
theNodeId
,
...
@@ -650,21 +650,21 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -650,21 +650,21 @@ EventLogger::getText(char * m_text, size_t m_text_len,
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
// REPORT Undo Logging blocked due to buffer near to overflow.
// REPORT Undo Logging blocked due to buffer near to overflow.
//-----------------------------------------------------------------------
//-----------------------------------------------------------------------
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode %d declared dead due to missed heartbeat"
,
"%sNode %d declared dead due to missed heartbeat"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
JobStatistic
:
case
EventReport
:
:
JobStatistic
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sMean loop Counter in doJob last 8192 times = %u"
,
"%sMean loop Counter in doJob last 8192 times = %u"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
SendBytesStatistic
:
case
EventReport
:
:
SendBytesStatistic
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sMean send size to Node = %d last 4096 sends = %u bytes"
,
"%sMean send size to Node = %d last 4096 sends = %u bytes"
,
theNodeId
,
theNodeId
,
...
@@ -672,7 +672,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -672,7 +672,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
2
]);
theData
[
2
]);
break
;
break
;
case
EventReport
:
:
ReceiveBytesStatistic
:
case
EventReport
:
:
ReceiveBytesStatistic
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sMean receive size to Node = %d last 4096 sends = %u bytes"
,
"%sMean receive size to Node = %d last 4096 sends = %u bytes"
,
theNodeId
,
theNodeId
,
...
@@ -680,14 +680,14 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -680,14 +680,14 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
2
]);
theData
[
2
]);
break
;
break
;
case
EventReport
:
:
SentHeartbeat
:
case
EventReport
:
:
SentHeartbeat
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode Sent Heartbeat to node = %d"
,
"%sNode Sent Heartbeat to node = %d"
,
theNodeId
,
theNodeId
,
theData
[
1
]);
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
CreateLogBytes
:
case
EventReport
:
:
CreateLogBytes
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLog part %u, log file %u, MB %u"
,
"%sLog part %u, log file %u, MB %u"
,
theNodeId
,
theNodeId
,
...
@@ -696,7 +696,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -696,7 +696,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
3
]);
theData
[
3
]);
break
;
break
;
case
EventReport
:
:
StartLog
:
case
EventReport
:
:
StartLog
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLog part %u, start MB %u, stop MB %u, last GCI, log exec %u"
,
"%sLog part %u, start MB %u, stop MB %u, last GCI, log exec %u"
,
theNodeId
,
theNodeId
,
...
@@ -706,7 +706,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -706,7 +706,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
4
]);
theData
[
4
]);
break
;
break
;
case
EventReport
:
:
StartREDOLog
:
case
EventReport
:
:
StartREDOLog
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sNode: %d StartLog: [GCI Keep: %d LastCompleted: %d NewestRestorable: %d]"
,
"%sNode: %d StartLog: [GCI Keep: %d LastCompleted: %d NewestRestorable: %d]"
,
theNodeId
,
theNodeId
,
...
@@ -723,7 +723,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -723,7 +723,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
line
=
"DBACC"
;
line
=
"DBACC"
;
}
}
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%s UNDO %s %d [%d %d %d %d %d %d %d %d %d]"
,
"%s UNDO %s %d [%d %d %d %d %d %d %d %d %d]"
,
theNodeId
,
theNodeId
,
...
@@ -741,36 +741,36 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -741,36 +741,36 @@ EventLogger::getText(char * m_text, size_t m_text_len,
}
}
break
;
break
;
case
EventReport
:
:
InfoEvent
:
case
EventReport
:
:
InfoEvent
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%s%s"
,
"%s%s"
,
theNodeId
,
theNodeId
,
(
char
*
)
&
theData
[
1
]);
(
char
*
)
&
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
WarningEvent
:
case
EventReport
:
:
WarningEvent
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%s%s"
,
"%s%s"
,
theNodeId
,
theNodeId
,
(
char
*
)
&
theData
[
1
]);
(
char
*
)
&
theData
[
1
]);
break
;
break
;
case
EventReport
:
:
GCP_TakeoverStarted
:
case
EventReport
:
:
GCP_TakeoverStarted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sGCP Take over started"
,
theNodeId
);
"%sGCP Take over started"
,
theNodeId
);
break
;
break
;
case
EventReport
:
:
GCP_TakeoverCompleted
:
case
EventReport
:
:
GCP_TakeoverCompleted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sGCP Take over completed"
,
theNodeId
);
"%sGCP Take over completed"
,
theNodeId
);
break
;
break
;
case
EventReport
:
:
LCP_TakeoverStarted
:
case
EventReport
:
:
LCP_TakeoverStarted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLCP Take over started"
,
theNodeId
);
"%sLCP Take over started"
,
theNodeId
);
break
;
break
;
case
EventReport
:
:
LCP_TakeoverCompleted
:
case
EventReport
:
:
LCP_TakeoverCompleted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sLCP Take over completed (state = %d)"
,
"%sLCP Take over completed (state = %d)"
,
theNodeId
,
theData
[
1
]);
theNodeId
,
theData
[
1
]);
...
@@ -783,7 +783,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -783,7 +783,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
block
=
theData
[
5
];
const
int
block
=
theData
[
5
];
const
int
percent
=
(
used
*
100
)
/
total
;
const
int
percent
=
(
used
*
100
)
/
total
;
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"%s%s usage %s %d%s(%d %dK pages of total %d)"
,
"%s%s usage %s %d%s(%d %dK pages of total %d)"
,
theNodeId
,
theNodeId
,
(
block
==
DBACC
?
"Index"
:
(
block
==
DBTUP
?
"Data"
:
"<unknown>"
)),
(
block
==
DBACC
?
"Index"
:
(
block
==
DBTUP
?
"Data"
:
"<unknown>"
)),
...
@@ -802,7 +802,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -802,7 +802,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Created subscription id"
"Grep::SSCoord: Created subscription id"
" (subId=%d,SubKey=%d)"
" (subId=%d,SubKey=%d)"
" Return code: %d."
,
" Return code: %d."
,
...
@@ -816,7 +816,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -816,7 +816,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Created subscription id"
"Grep::PSCoord: Created subscription id"
" (subId=%d,SubKey=%d)"
" (subId=%d,SubKey=%d)"
" Return code: %d."
,
" Return code: %d."
,
...
@@ -831,7 +831,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -831,7 +831,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
const
int
nodegrp
=
theData
[
5
];
const
int
nodegrp
=
theData
[
5
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Created subscription using"
"Grep::SSCoord: Created subscription using"
" (subId=%d,SubKey=%d)"
" (subId=%d,SubKey=%d)"
" in primary system. Primary system has %d nodegroup(s)."
" in primary system. Primary system has %d nodegroup(s)."
...
@@ -847,7 +847,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -847,7 +847,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have created "
"Grep::PSCoord: All participants have created "
"subscriptions"
"subscriptions"
" using (subId=%d,SubKey=%d)."
" using (subId=%d,SubKey=%d)."
...
@@ -862,7 +862,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -862,7 +862,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Logging started on meta data changes."
"Grep::SSCoord: Logging started on meta data changes."
" using (subId=%d,SubKey=%d)"
" using (subId=%d,SubKey=%d)"
" Return code: %d"
,
" Return code: %d"
,
...
@@ -876,7 +876,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -876,7 +876,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have started "
"Grep::PSCoord: All participants have started "
"logging meta data"
"logging meta data"
" changes on the subscription subId=%d,SubKey=%d) "
" changes on the subscription subId=%d,SubKey=%d) "
...
@@ -891,7 +891,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -891,7 +891,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Logging started on table data changes "
"Grep::SSCoord: Logging started on table data changes "
" using (subId=%d,SubKey=%d)"
" using (subId=%d,SubKey=%d)"
" Return code: %d"
,
" Return code: %d"
,
...
@@ -905,7 +905,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -905,7 +905,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have started logging "
"Grep::PSCoord: All participants have started logging "
"table data changes on the subscription "
"table data changes on the subscription "
"subId=%d,SubKey=%d)."
"subId=%d,SubKey=%d)."
...
@@ -920,7 +920,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -920,7 +920,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have started "
"Grep::PSCoord: All participants have started "
" synchronization on meta data (META SCAN) using "
" synchronization on meta data (META SCAN) using "
"(subId=%d,SubKey=%d)."
"(subId=%d,SubKey=%d)."
...
@@ -935,7 +935,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -935,7 +935,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Synchronization started (META SCAN) on "
"Grep::SSCoord: Synchronization started (META SCAN) on "
" meta data using (subId=%d,SubKey=%d)"
" meta data using (subId=%d,SubKey=%d)"
" Return code: %d"
,
" Return code: %d"
,
...
@@ -949,7 +949,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -949,7 +949,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have started "
"Grep::PSCoord: All participants have started "
"synchronization "
"synchronization "
" on table data (DATA SCAN) using (subId=%d,SubKey=%d)."
" on table data (DATA SCAN) using (subId=%d,SubKey=%d)."
...
@@ -965,7 +965,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -965,7 +965,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
const
int
gci
=
theData
[
5
];
const
int
gci
=
theData
[
5
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Synchronization started (DATA SCAN) on "
"Grep::SSCoord: Synchronization started (DATA SCAN) on "
"table data using (subId=%d,SubKey=%d). GCI = %d"
"table data using (subId=%d,SubKey=%d). GCI = %d"
" Return code: %d"
,
" Return code: %d"
,
...
@@ -980,7 +980,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -980,7 +980,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: All participants have removed "
"Grep::PSCoord: All participants have removed "
"subscription (subId=%d,SubKey=%d). I have cleaned "
"subscription (subId=%d,SubKey=%d). I have cleaned "
"up resources I've used."
"up resources I've used."
...
@@ -995,7 +995,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -995,7 +995,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Removed subscription "
"Grep::SSCoord: Removed subscription "
"(subId=%d,SubKey=%d)"
"(subId=%d,SubKey=%d)"
" Return code: %d"
,
" Return code: %d"
,
...
@@ -1005,7 +1005,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1005,7 +1005,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
break
;
break
;
}
}
default:
default:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sUnknown GrepSubscriptonInfo event: %d"
,
"%sUnknown GrepSubscriptonInfo event: %d"
,
theNodeId
,
theNodeId
,
...
@@ -1024,7 +1024,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1024,7 +1024,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord:Error code: %d Error message: %s"
"Grep::SSCoord:Error code: %d Error message: %s"
" (subId=%d,SubKey=%d)"
,
" (subId=%d,SubKey=%d)"
,
err
,
err
,
...
@@ -1038,7 +1038,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1038,7 +1038,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: FAILED to Created subscription using"
"Grep::SSCoord: FAILED to Created subscription using"
" (subId=%d,SubKey=%d)in primary system."
" (subId=%d,SubKey=%d)in primary system."
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1053,7 +1053,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1053,7 +1053,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Logging failed to start on meta "
"Grep::SSCoord: Logging failed to start on meta "
"data changes."
"data changes."
" using (subId=%d,SubKey=%d)"
" using (subId=%d,SubKey=%d)"
...
@@ -1069,7 +1069,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1069,7 +1069,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Logging FAILED to start on table data "
"Grep::SSCoord: Logging FAILED to start on table data "
" changes using (subId=%d,SubKey=%d)"
" changes using (subId=%d,SubKey=%d)"
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1084,7 +1084,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1084,7 +1084,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Synchronization FAILED (META SCAN) on "
"Grep::SSCoord: Synchronization FAILED (META SCAN) on "
" meta data using (subId=%d,SubKey=%d)"
" meta data using (subId=%d,SubKey=%d)"
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1100,7 +1100,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1100,7 +1100,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
const
int
gci
=
theData
[
5
];
const
int
gci
=
theData
[
5
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Synchronization FAILED (DATA SCAN) on "
"Grep::SSCoord: Synchronization FAILED (DATA SCAN) on "
"table data using (subId=%d,SubKey=%d). GCI = %d"
"table data using (subId=%d,SubKey=%d). GCI = %d"
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1116,7 +1116,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1116,7 +1116,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::SSCoord: Failed to remove subscription "
"Grep::SSCoord: Failed to remove subscription "
"(subId=%d,SubKey=%d). "
"(subId=%d,SubKey=%d). "
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1133,7 +1133,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1133,7 +1133,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Error code: %d Error Message: %s"
"Grep::PSCoord: Error code: %d Error Message: %s"
" (subId=%d,SubKey=%d)"
,
" (subId=%d,SubKey=%d)"
,
err
,
err
,
...
@@ -1147,7 +1147,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1147,7 +1147,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: FAILED to Created subscription using"
"Grep::PSCoord: FAILED to Created subscription using"
" (subId=%d,SubKey=%d)in primary system."
" (subId=%d,SubKey=%d)in primary system."
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1162,7 +1162,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1162,7 +1162,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Logging failed to start on meta "
"Grep::PSCoord: Logging failed to start on meta "
"data changes."
"data changes."
" using (subId=%d,SubKey=%d)"
" using (subId=%d,SubKey=%d)"
...
@@ -1178,7 +1178,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1178,7 +1178,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Logging FAILED to start on table data "
"Grep::PSCoord: Logging FAILED to start on table data "
" changes using (subId=%d,SubKey=%d)"
" changes using (subId=%d,SubKey=%d)"
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1193,7 +1193,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1193,7 +1193,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Synchronization FAILED (META SCAN) on "
"Grep::PSCoord: Synchronization FAILED (META SCAN) on "
" meta data using (subId=%d,SubKey=%d)"
" meta data using (subId=%d,SubKey=%d)"
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1209,7 +1209,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1209,7 +1209,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
const
int
gci
=
theData
[
5
];
const
int
gci
=
theData
[
5
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Synchronization FAILED (DATA SCAN) on "
"Grep::PSCoord: Synchronization FAILED (DATA SCAN) on "
"table data using (subId=%d,SubKey=%d). GCI = %d. "
"table data using (subId=%d,SubKey=%d). GCI = %d. "
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1225,7 +1225,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1225,7 +1225,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
const
int
subId
=
theData
[
2
];
const
int
subId
=
theData
[
2
];
const
int
subKey
=
theData
[
3
];
const
int
subKey
=
theData
[
3
];
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Grep::PSCoord: Failed to remove subscription "
"Grep::PSCoord: Failed to remove subscription "
"(subId=%d,SubKey=%d)."
"(subId=%d,SubKey=%d)."
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
...
@@ -1239,7 +1239,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1239,7 +1239,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
{
{
const
int
err
=
theData
[
4
];
const
int
err
=
theData
[
4
];
const
int
nodeId
=
theData
[
5
];
const
int
nodeId
=
theData
[
5
];
::
snprintf
(
m_text
,
m_text_len
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
"Rep: Node %d."
"Rep: Node %d."
" Error code: %d Error Message: %s"
,
" Error code: %d Error Message: %s"
,
nodeId
,
nodeId
,
...
@@ -1250,7 +1250,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1250,7 +1250,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
default:
default:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sUnknown GrepSubscriptionAlert event: %d"
,
"%sUnknown GrepSubscriptionAlert event: %d"
,
theNodeId
,
theNodeId
,
...
@@ -1261,19 +1261,19 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1261,19 +1261,19 @@ EventLogger::getText(char * m_text, size_t m_text_len,
}
}
case
EventReport
:
:
BackupStarted
:
case
EventReport
:
:
BackupStarted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sBackup %d started from node %d"
,
"%sBackup %d started from node %d"
,
theNodeId
,
theData
[
2
],
refToNode
(
theData
[
1
]));
theNodeId
,
theData
[
2
],
refToNode
(
theData
[
1
]));
break
;
break
;
case
EventReport
:
:
BackupFailedToStart
:
case
EventReport
:
:
BackupFailedToStart
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sBackup request from %d failed to start. Error: %d"
,
"%sBackup request from %d failed to start. Error: %d"
,
theNodeId
,
refToNode
(
theData
[
1
]),
theData
[
2
]);
theNodeId
,
refToNode
(
theData
[
1
]),
theData
[
2
]);
break
;
break
;
case
EventReport
:
:
BackupCompleted
:
case
EventReport
:
:
BackupCompleted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sBackup %d started from node %d completed
\n
"
"%sBackup %d started from node %d completed
\n
"
" StartGCP: %d StopGCP: %d
\n
"
" StartGCP: %d StopGCP: %d
\n
"
...
@@ -1284,7 +1284,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1284,7 +1284,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
5
],
theData
[
7
]);
theData
[
5
],
theData
[
7
]);
break
;
break
;
case
EventReport
:
:
BackupAborted
:
case
EventReport
:
:
BackupAborted
:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sBackup %d started from %d has been aborted. Error: %d"
,
"%sBackup %d started from %d has been aborted. Error: %d"
,
theNodeId
,
theNodeId
,
...
@@ -1293,7 +1293,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
...
@@ -1293,7 +1293,7 @@ EventLogger::getText(char * m_text, size_t m_text_len,
theData
[
3
]);
theData
[
3
]);
break
;
break
;
default:
default:
::
snprintf
(
m_text
,
BaseString
::
snprintf
(
m_text
,
m_text_len
,
m_text_len
,
"%sUnknown event: %d"
,
"%sUnknown event: %d"
,
theNodeId
,
theNodeId
,
...
...
ndb/src/common/logger/FileLogHandler.cpp
View file @
f3513a79
...
@@ -153,11 +153,11 @@ FileLogHandler::createNewFile()
...
@@ -153,11 +153,11 @@ FileLogHandler::createNewFile()
if
(
fileNo
>=
m_maxNoFiles
)
if
(
fileNo
>=
m_maxNoFiles
)
{
{
fileNo
=
1
;
fileNo
=
1
;
::
snprintf
(
newName
,
sizeof
(
newName
),
BaseString
::
snprintf
(
newName
,
sizeof
(
newName
),
"%s.%d"
,
m_pLogFile
->
getName
(),
fileNo
);
"%s.%d"
,
m_pLogFile
->
getName
(),
fileNo
);
break
;
break
;
}
}
::
snprintf
(
newName
,
sizeof
(
newName
),
BaseString
::
snprintf
(
newName
,
sizeof
(
newName
),
"%s.%d"
,
m_pLogFile
->
getName
(),
fileNo
++
);
"%s.%d"
,
m_pLogFile
->
getName
(),
fileNo
++
);
}
while
(
File_class
::
exists
(
newName
));
}
while
(
File_class
::
exists
(
newName
));
...
...
ndb/src/common/logger/LogHandler.cpp
View file @
f3513a79
...
@@ -45,7 +45,7 @@ LogHandler::getDefaultHeader(char* pStr, const char* pCategory,
...
@@ -45,7 +45,7 @@ LogHandler::getDefaultHeader(char* pStr, const char* pCategory,
Logger
::
LoggerLevel
level
)
const
Logger
::
LoggerLevel
level
)
const
{
{
char
time
[
MAX_DATE_TIME_HEADER_LENGTH
];
char
time
[
MAX_DATE_TIME_HEADER_LENGTH
];
::
snprintf
(
pStr
,
MAX_HEADER_LENGTH
,
"%s [%s] %s -- "
,
BaseString
::
snprintf
(
pStr
,
MAX_HEADER_LENGTH
,
"%s [%s] %s -- "
,
getTimeAsString
((
char
*
)
time
),
getTimeAsString
((
char
*
)
time
),
pCategory
,
pCategory
,
Logger
::
LoggerLevelNames
[
level
]);
Logger
::
LoggerLevelNames
[
level
]);
...
@@ -84,7 +84,7 @@ LogHandler::getTimeAsString(char* pStr) const
...
@@ -84,7 +84,7 @@ LogHandler::getTimeAsString(char* pStr) const
tm_now
=
::
localtime
(
&
now
);
//uses the "current" timezone
tm_now
=
::
localtime
(
&
now
);
//uses the "current" timezone
#endif
#endif
::
snprintf
(
pStr
,
MAX_DATE_TIME_HEADER_LENGTH
,
BaseString
::
snprintf
(
pStr
,
MAX_DATE_TIME_HEADER_LENGTH
,
m_pDateTimeFormat
,
m_pDateTimeFormat
,
tm_now
->
tm_year
+
1900
,
tm_now
->
tm_year
+
1900
,
tm_now
->
tm_mon
+
1
,
//month is [0,11]. +1 -> [1,12]
tm_now
->
tm_mon
+
1
,
//month is [0,11]. +1 -> [1,12]
...
...
ndb/src/common/logger/listtest/LogHandlerListUnitTest.cpp
View file @
f3513a79
...
@@ -128,7 +128,7 @@ LogHandlerListUnitTest::testTraverseNext(const char* msg)
...
@@ -128,7 +128,7 @@ LogHandlerListUnitTest::testTraverseNext(const char* msg)
{
{
char
*
str
=
new
char
[
3
];
char
*
str
=
new
char
[
3
];
pHandlers
[
i
]
=
new
ConsoleLogHandler
();
pHandlers
[
i
]
=
new
ConsoleLogHandler
();
::
snprintf
(
str
,
3
,
"%d"
,
i
);
BaseString
::
snprintf
(
str
,
3
,
"%d"
,
i
);
pHandlers
[
i
]
->
setDateTimeFormat
(
str
);
pHandlers
[
i
]
->
setDateTimeFormat
(
str
);
list
.
add
(
pHandlers
[
i
]);
list
.
add
(
pHandlers
[
i
]);
}
}
...
...
ndb/src/common/logger/loggertest/LoggerUnitTest.cpp
View file @
f3513a79
...
@@ -86,7 +86,7 @@ NDB_COMMAND(loggertest, "loggertest", "loggertest -console | -file",
...
@@ -86,7 +86,7 @@ NDB_COMMAND(loggertest, "loggertest", "loggertest -console | -file",
{
{
ndbout
<<
"-- "
<<
" Test "
<<
i
+
1
ndbout
<<
"-- "
<<
" Test "
<<
i
+
1
<<
" ["
<<
testCases
[
i
].
name
<<
"] --"
<<
endl
;
<<
" ["
<<
testCases
[
i
].
name
<<
"] --"
<<
endl
;
::
snprintf
(
str
,
256
,
"%s %s %s %d"
,
"Logging "
,
BaseString
::
snprintf
(
str
,
256
,
"%s %s %s %d"
,
"Logging "
,
testCases
[
i
].
name
,
" message "
,
i
);
testCases
[
i
].
name
,
" message "
,
i
);
if
(
testCases
[
i
].
test
(
str
))
if
(
testCases
[
i
].
test
(
str
))
{
{
...
...
ndb/src/common/util/File.cpp
View file @
f3513a79
...
@@ -83,7 +83,7 @@ File_class::File_class(const char* aFileName, const char* mode) :
...
@@ -83,7 +83,7 @@ File_class::File_class(const char* aFileName, const char* mode) :
m_file
(
NULL
),
m_file
(
NULL
),
m_fileMode
(
mode
)
m_fileMode
(
mode
)
{
{
::
snprintf
(
m_fileName
,
MAX_FILE_NAME_SIZE
,
aFileName
);
BaseString
::
snprintf
(
m_fileName
,
MAX_FILE_NAME_SIZE
,
aFileName
);
}
}
bool
bool
...
@@ -99,7 +99,7 @@ File_class::open(const char* aFileName, const char* mode)
...
@@ -99,7 +99,7 @@ File_class::open(const char* aFileName, const char* mode)
/**
/**
* Only copy if it's not the same string
* Only copy if it's not the same string
*/
*/
::
snprintf
(
m_fileName
,
MAX_FILE_NAME_SIZE
,
aFileName
);
BaseString
::
snprintf
(
m_fileName
,
MAX_FILE_NAME_SIZE
,
aFileName
);
}
}
m_fileMode
=
mode
;
m_fileMode
=
mode
;
bool
rc
=
true
;
bool
rc
=
true
;
...
...
ndb/src/common/util/NdbErrHnd.cpp
View file @
f3513a79
...
@@ -346,15 +346,15 @@ extern "C" OSBOOLEAN ndb_err_hnd(bool user_called,
...
@@ -346,15 +346,15 @@ extern "C" OSBOOLEAN ndb_err_hnd(bool user_called,
file_name
=
"ose_err.h"
;
file_name
=
"ose_err.h"
;
}
}
snprintf
(
error_message
.
header1
,
BaseString
::
snprintf
(
error_message
.
header1
,
BUFSIZE
,
BUFSIZE
,
"This is the OSE Example System Error handler
\r\n
"
);
"This is the OSE Example System Error handler
\r\n
"
);
snprintf
(
error_message
.
err_hnd_file
,
BaseString
::
snprintf
(
error_message
.
err_hnd_file
,
BUFSIZE
,
BUFSIZE
,
"located in: "
__FILE__
"
\r\n
"
);
"located in: "
__FILE__
"
\r\n
"
);
snprintf
(
error_message
.
header2
,
BaseString
::
snprintf
(
error_message
.
header2
,
BUFSIZE
,
BUFSIZE
,
"An Error has been reported:
\r\n
"
);
"An Error has been reported:
\r\n
"
);
...
@@ -371,28 +371,28 @@ extern "C" OSBOOLEAN ndb_err_hnd(bool user_called,
...
@@ -371,28 +371,28 @@ extern "C" OSBOOLEAN ndb_err_hnd(bool user_called,
user_called
);
user_called
);
}
}
snprintf
(
error_message
.
error_code_line
,
BaseString
::
snprintf
(
error_message
.
error_code_line
,
BUFSIZE
,
BUFSIZE
,
"error code: 0x%08x
\r\n
"
,
"error code: 0x%08x
\r\n
"
,
error_code
);
error_code
);
snprintf
(
error_message
.
subcode_line
,
BaseString
::
snprintf
(
error_message
.
subcode_line
,
BUFSIZE
,
BUFSIZE
,
" subcode: %s (0x%08x)
\r\n
"
,
" subcode: %s (0x%08x)
\r\n
"
,
subcode_mnemonic
,
subcode_mnemonic
,
(
subcode
<<
16
));
(
subcode
<<
16
));
snprintf
(
error_message
.
product_line
,
BaseString
::
snprintf
(
error_message
.
product_line
,
BUFSIZE
,
BUFSIZE
,
" product: %s
\r\n
"
,
" product: %s
\r\n
"
,
product_name
);
product_name
);
snprintf
(
error_message
.
header_file_line
,
BaseString
::
snprintf
(
error_message
.
header_file_line
,
BUFSIZE
,
BUFSIZE
,
" header file: %s
\r\n
"
,
" header file: %s
\r\n
"
,
file_name
);
file_name
);
snprintf
(
error_message
.
extra_line
,
BaseString
::
snprintf
(
error_message
.
extra_line
,
BUFSIZE
,
BUFSIZE
,
"extra: 0x%08x
\r\n
"
,
"extra: 0x%08x
\r\n
"
,
extra
);
extra
);
...
...
ndb/src/mgmsrv/ConfigInfo.cpp
View file @
f3513a79
...
@@ -3405,9 +3405,9 @@ add_node_connections(Vector<ConfigInfo::ConfigRuleSection>§ions,
...
@@ -3405,9 +3405,9 @@ add_node_connections(Vector<ConfigInfo::ConfigRuleSection>§ions,
s
.
m_sectionType
=
BaseString
(
"TCP"
);
s
.
m_sectionType
=
BaseString
(
"TCP"
);
s
.
m_sectionData
=
new
Properties
(
true
);
s
.
m_sectionData
=
new
Properties
(
true
);
char
buf
[
16
];
char
buf
[
16
];
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId1
);
BaseString
::
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId1
);
s
.
m_sectionData
->
put
(
"NodeId1"
,
buf
);
s
.
m_sectionData
->
put
(
"NodeId1"
,
buf
);
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId2
);
BaseString
::
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId2
);
s
.
m_sectionData
->
put
(
"NodeId2"
,
buf
);
s
.
m_sectionData
->
put
(
"NodeId2"
,
buf
);
sections
.
push_back
(
s
);
sections
.
push_back
(
s
);
}
}
...
@@ -3422,9 +3422,9 @@ add_node_connections(Vector<ConfigInfo::ConfigRuleSection>§ions,
...
@@ -3422,9 +3422,9 @@ add_node_connections(Vector<ConfigInfo::ConfigRuleSection>§ions,
s
.
m_sectionType
=
BaseString
(
"TCP"
);
s
.
m_sectionType
=
BaseString
(
"TCP"
);
s
.
m_sectionData
=
new
Properties
(
true
);
s
.
m_sectionData
=
new
Properties
(
true
);
char
buf
[
16
];
char
buf
[
16
];
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId1
);
BaseString
::
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId1
);
s
.
m_sectionData
->
put
(
"NodeId1"
,
buf
);
s
.
m_sectionData
->
put
(
"NodeId1"
,
buf
);
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId2
);
BaseString
::
snprintf
(
buf
,
sizeof
(
buf
),
"%u"
,
nodeId2
);
s
.
m_sectionData
->
put
(
"NodeId2"
,
buf
);
s
.
m_sectionData
->
put
(
"NodeId2"
,
buf
);
sections
.
push_back
(
s
);
sections
.
push_back
(
s
);
}
}
...
...
ndb/test/ndbapi/userInterface.cpp
View file @
f3513a79
...
@@ -103,7 +103,7 @@ void showTime()
...
@@ -103,7 +103,7 @@ void showTime()
now
=
::
time
((
time_t
*
)
NULL
);
now
=
::
time
((
time_t
*
)
NULL
);
tm_now
=
::
gmtime
(
&
now
);
tm_now
=
::
gmtime
(
&
now
);
::
snprintf
(
buf
,
128
,
BaseString
::
snprintf
(
buf
,
128
,
"%d-%.2d-%.2d %.2d:%.2d:%.2d"
,
"%d-%.2d-%.2d %.2d:%.2d:%.2d"
,
tm_now
->
tm_year
+
1900
,
tm_now
->
tm_year
+
1900
,
tm_now
->
tm_mon
,
tm_now
->
tm_mon
,
...
...
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