Loading ndb/include/Makefile.am +2 −1 Original line number Diff line number Diff line Loading @@ -31,7 +31,8 @@ mgmapiinclude_HEADERS = \ mgmapi/mgmapi.h \ mgmapi/mgmapi_debug.h \ mgmapi/mgmapi_config_parameters.h \ mgmapi/mgmapi_config_parameters_debug.h mgmapi/mgmapi_config_parameters_debug.h \ mgmapi/ndb_logevent.h noinst_HEADERS = \ ndb_global.h \ Loading ndb/include/debugger/EventLogger.hpp +1 −1 Original line number Diff line number Diff line Loading @@ -40,7 +40,7 @@ public: * severity - DEBUG to ALERT (Type of log message) */ struct EventRepLogLevelMatrix { EventReport::EventType eventType; Ndb_logevent_type eventType; LogLevel::EventCategory eventCategory; Uint32 threshold; Logger::LoggerLevel severity; Loading ndb/include/kernel/signaldata/EventReport.hpp +6 −82 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ #ifndef SD_EVENT_REPORT_H #define SD_EVENT_REPORT_H #include <ndb_logevent.h> #include "SignalData.hpp" /** Loading Loading @@ -67,98 +68,21 @@ public: 4) Add SentHeartbeat in EventLogger::getText() */ enum EventType { // CONNECTION Connected = 0, Disconnected = 1, CommunicationClosed = 2, CommunicationOpened = 3, ConnectedApiVersion = 51, // CHECKPOINT GlobalCheckpointStarted = 4, GlobalCheckpointCompleted = 5, LocalCheckpointStarted = 6, LocalCheckpointCompleted = 7, LCPStoppedInCalcKeepGci = 8, LCPFragmentCompleted = 9, // STARTUP NDBStartStarted = 10, NDBStartCompleted = 11, STTORRYRecieved = 12, StartPhaseCompleted = 13, CM_REGCONF = 14, CM_REGREF = 15, FIND_NEIGHBOURS = 16, NDBStopStarted = 17, NDBStopAborted = 18, StartREDOLog = 19, StartLog = 20, UNDORecordsExecuted = 21, // NODERESTART NR_CopyDict = 22, NR_CopyDistr = 23, NR_CopyFragsStarted = 24, NR_CopyFragDone = 25, NR_CopyFragsCompleted = 26, // NODEFAIL NodeFailCompleted = 27, NODE_FAILREP = 28, ArbitState = 29, ArbitResult = 30, GCP_TakeoverStarted = 31, GCP_TakeoverCompleted = 32, LCP_TakeoverStarted = 33, LCP_TakeoverCompleted = 34, // STATISTIC TransReportCounters = 35, OperationReportCounters = 36, TableCreated = 37, UndoLogBlocked = 38, JobStatistic = 39, SendBytesStatistic = 40, ReceiveBytesStatistic = 41, MemoryUsage = 50, // ERROR TransporterError = 42, TransporterWarning = 43, MissedHeartbeat = 44, DeadDueToHeartbeat = 45, WarningEvent = 46, // INFO SentHeartbeat = 47, CreateLogBytes = 48, InfoEvent = 49, //GREP GrepSubscriptionInfo = 52, GrepSubscriptionAlert = 53, //BACKUP BackupStarted = 54, BackupFailedToStart = 55, BackupCompleted = 56, BackupAborted = 57 }; void setEventType(EventType type); EventType getEventType() const; void setEventType(Ndb_logevent_type type); Ndb_logevent_type getEventType() const; UintR eventType; // DATA 0 }; inline void EventReport::setEventType(EventType type){ EventReport::setEventType(Ndb_logevent_type type){ eventType = (UintR) type; } inline EventReport::EventType Ndb_logevent_type EventReport::getEventType() const { return (EventType)eventType; return (Ndb_logevent_type)eventType; } #endif ndb/include/mgmapi/ndb_logevent.h 0 → 100644 +106 −0 Original line number Diff line number Diff line /* Copyright (C) 2003 MySQL AB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef NDB_LOGEVENT_H #define NDB_LOGEVENT_H #ifdef __cplusplus extern "C" { #endif enum Ndb_logevent_type { /* CONNECTION */ NDB_LE_Connected = 0, NDB_LE_Disconnected = 1, NDB_LE_CommunicationClosed = 2, NDB_LE_CommunicationOpened = 3, NDB_LE_ConnectedApiVersion = 51, /* CHECKPOINT */ NDB_LE_GlobalCheckpointStarted = 4, NDB_LE_GlobalCheckpointCompleted = 5, NDB_LE_LocalCheckpointStarted = 6, NDB_LE_LocalCheckpointCompleted = 7, NDB_LE_LCPStoppedInCalcKeepGci = 8, NDB_LE_LCPFragmentCompleted = 9, /* STARTUP */ NDB_LE_NDBStartStarted = 10, NDB_LE_NDBStartCompleted = 11, NDB_LE_STTORRYRecieved = 12, NDB_LE_StartPhaseCompleted = 13, NDB_LE_CM_REGCONF = 14, NDB_LE_CM_REGREF = 15, NDB_LE_FIND_NEIGHBOURS = 16, NDB_LE_NDBStopStarted = 17, NDB_LE_NDBStopAborted = 18, NDB_LE_StartREDOLog = 19, NDB_LE_StartLog = 20, NDB_LE_UNDORecordsExecuted = 21, /* NODERESTART */ NDB_LE_NR_CopyDict = 22, NDB_LE_NR_CopyDistr = 23, NDB_LE_NR_CopyFragsStarted = 24, NDB_LE_NR_CopyFragDone = 25, NDB_LE_NR_CopyFragsCompleted = 26, /* NODEFAIL */ NDB_LE_NodeFailCompleted = 27, NDB_LE_NODE_FAILREP = 28, NDB_LE_ArbitState = 29, NDB_LE_ArbitResult = 30, NDB_LE_GCP_TakeoverStarted = 31, NDB_LE_GCP_TakeoverCompleted = 32, NDB_LE_LCP_TakeoverStarted = 33, NDB_LE_LCP_TakeoverCompleted = 34, /* STATISTIC */ NDB_LE_TransReportCounters = 35, NDB_LE_OperationReportCounters = 36, NDB_LE_TableCreated = 37, NDB_LE_UndoLogBlocked = 38, NDB_LE_JobStatistic = 39, NDB_LE_SendBytesStatistic = 40, NDB_LE_ReceiveBytesStatistic = 41, NDB_LE_MemoryUsage = 50, /* ERROR */ NDB_LE_TransporterError = 42, NDB_LE_TransporterWarning = 43, NDB_LE_MissedHeartbeat = 44, NDB_LE_DeadDueToHeartbeat = 45, NDB_LE_WarningEvent = 46, /* INFO */ NDB_LE_SentHeartbeat = 47, NDB_LE_CreateLogBytes = 48, NDB_LE_InfoEvent = 49, /* GREP */ NDB_LE_GrepSubscriptionInfo = 52, NDB_LE_GrepSubscriptionAlert = 53, /* BACKUP */ NDB_LE_BackupStarted = 54, NDB_LE_BackupFailedToStart = 55, NDB_LE_BackupCompleted = 56, NDB_LE_BackupAborted = 57 }; #ifdef __cplusplus } #endif #endif ndb/include/ndbapi/Ndb.hpp +3 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,9 @@ an ordered index, - NdbRecAttr represents an attribute value - NdbDictionary represents meta information about tables and attributes. - NdbError contains the specification for an error. In addition, the NDB API defines a structure NdbError, which contains the specification for an error. It is also possible to receive "events" triggered when data in the database in changed. This is done through the NdbEventOperation class. Loading Loading
ndb/include/Makefile.am +2 −1 Original line number Diff line number Diff line Loading @@ -31,7 +31,8 @@ mgmapiinclude_HEADERS = \ mgmapi/mgmapi.h \ mgmapi/mgmapi_debug.h \ mgmapi/mgmapi_config_parameters.h \ mgmapi/mgmapi_config_parameters_debug.h mgmapi/mgmapi_config_parameters_debug.h \ mgmapi/ndb_logevent.h noinst_HEADERS = \ ndb_global.h \ Loading
ndb/include/debugger/EventLogger.hpp +1 −1 Original line number Diff line number Diff line Loading @@ -40,7 +40,7 @@ public: * severity - DEBUG to ALERT (Type of log message) */ struct EventRepLogLevelMatrix { EventReport::EventType eventType; Ndb_logevent_type eventType; LogLevel::EventCategory eventCategory; Uint32 threshold; Logger::LoggerLevel severity; Loading
ndb/include/kernel/signaldata/EventReport.hpp +6 −82 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ #ifndef SD_EVENT_REPORT_H #define SD_EVENT_REPORT_H #include <ndb_logevent.h> #include "SignalData.hpp" /** Loading Loading @@ -67,98 +68,21 @@ public: 4) Add SentHeartbeat in EventLogger::getText() */ enum EventType { // CONNECTION Connected = 0, Disconnected = 1, CommunicationClosed = 2, CommunicationOpened = 3, ConnectedApiVersion = 51, // CHECKPOINT GlobalCheckpointStarted = 4, GlobalCheckpointCompleted = 5, LocalCheckpointStarted = 6, LocalCheckpointCompleted = 7, LCPStoppedInCalcKeepGci = 8, LCPFragmentCompleted = 9, // STARTUP NDBStartStarted = 10, NDBStartCompleted = 11, STTORRYRecieved = 12, StartPhaseCompleted = 13, CM_REGCONF = 14, CM_REGREF = 15, FIND_NEIGHBOURS = 16, NDBStopStarted = 17, NDBStopAborted = 18, StartREDOLog = 19, StartLog = 20, UNDORecordsExecuted = 21, // NODERESTART NR_CopyDict = 22, NR_CopyDistr = 23, NR_CopyFragsStarted = 24, NR_CopyFragDone = 25, NR_CopyFragsCompleted = 26, // NODEFAIL NodeFailCompleted = 27, NODE_FAILREP = 28, ArbitState = 29, ArbitResult = 30, GCP_TakeoverStarted = 31, GCP_TakeoverCompleted = 32, LCP_TakeoverStarted = 33, LCP_TakeoverCompleted = 34, // STATISTIC TransReportCounters = 35, OperationReportCounters = 36, TableCreated = 37, UndoLogBlocked = 38, JobStatistic = 39, SendBytesStatistic = 40, ReceiveBytesStatistic = 41, MemoryUsage = 50, // ERROR TransporterError = 42, TransporterWarning = 43, MissedHeartbeat = 44, DeadDueToHeartbeat = 45, WarningEvent = 46, // INFO SentHeartbeat = 47, CreateLogBytes = 48, InfoEvent = 49, //GREP GrepSubscriptionInfo = 52, GrepSubscriptionAlert = 53, //BACKUP BackupStarted = 54, BackupFailedToStart = 55, BackupCompleted = 56, BackupAborted = 57 }; void setEventType(EventType type); EventType getEventType() const; void setEventType(Ndb_logevent_type type); Ndb_logevent_type getEventType() const; UintR eventType; // DATA 0 }; inline void EventReport::setEventType(EventType type){ EventReport::setEventType(Ndb_logevent_type type){ eventType = (UintR) type; } inline EventReport::EventType Ndb_logevent_type EventReport::getEventType() const { return (EventType)eventType; return (Ndb_logevent_type)eventType; } #endif
ndb/include/mgmapi/ndb_logevent.h 0 → 100644 +106 −0 Original line number Diff line number Diff line /* Copyright (C) 2003 MySQL AB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #ifndef NDB_LOGEVENT_H #define NDB_LOGEVENT_H #ifdef __cplusplus extern "C" { #endif enum Ndb_logevent_type { /* CONNECTION */ NDB_LE_Connected = 0, NDB_LE_Disconnected = 1, NDB_LE_CommunicationClosed = 2, NDB_LE_CommunicationOpened = 3, NDB_LE_ConnectedApiVersion = 51, /* CHECKPOINT */ NDB_LE_GlobalCheckpointStarted = 4, NDB_LE_GlobalCheckpointCompleted = 5, NDB_LE_LocalCheckpointStarted = 6, NDB_LE_LocalCheckpointCompleted = 7, NDB_LE_LCPStoppedInCalcKeepGci = 8, NDB_LE_LCPFragmentCompleted = 9, /* STARTUP */ NDB_LE_NDBStartStarted = 10, NDB_LE_NDBStartCompleted = 11, NDB_LE_STTORRYRecieved = 12, NDB_LE_StartPhaseCompleted = 13, NDB_LE_CM_REGCONF = 14, NDB_LE_CM_REGREF = 15, NDB_LE_FIND_NEIGHBOURS = 16, NDB_LE_NDBStopStarted = 17, NDB_LE_NDBStopAborted = 18, NDB_LE_StartREDOLog = 19, NDB_LE_StartLog = 20, NDB_LE_UNDORecordsExecuted = 21, /* NODERESTART */ NDB_LE_NR_CopyDict = 22, NDB_LE_NR_CopyDistr = 23, NDB_LE_NR_CopyFragsStarted = 24, NDB_LE_NR_CopyFragDone = 25, NDB_LE_NR_CopyFragsCompleted = 26, /* NODEFAIL */ NDB_LE_NodeFailCompleted = 27, NDB_LE_NODE_FAILREP = 28, NDB_LE_ArbitState = 29, NDB_LE_ArbitResult = 30, NDB_LE_GCP_TakeoverStarted = 31, NDB_LE_GCP_TakeoverCompleted = 32, NDB_LE_LCP_TakeoverStarted = 33, NDB_LE_LCP_TakeoverCompleted = 34, /* STATISTIC */ NDB_LE_TransReportCounters = 35, NDB_LE_OperationReportCounters = 36, NDB_LE_TableCreated = 37, NDB_LE_UndoLogBlocked = 38, NDB_LE_JobStatistic = 39, NDB_LE_SendBytesStatistic = 40, NDB_LE_ReceiveBytesStatistic = 41, NDB_LE_MemoryUsage = 50, /* ERROR */ NDB_LE_TransporterError = 42, NDB_LE_TransporterWarning = 43, NDB_LE_MissedHeartbeat = 44, NDB_LE_DeadDueToHeartbeat = 45, NDB_LE_WarningEvent = 46, /* INFO */ NDB_LE_SentHeartbeat = 47, NDB_LE_CreateLogBytes = 48, NDB_LE_InfoEvent = 49, /* GREP */ NDB_LE_GrepSubscriptionInfo = 52, NDB_LE_GrepSubscriptionAlert = 53, /* BACKUP */ NDB_LE_BackupStarted = 54, NDB_LE_BackupFailedToStart = 55, NDB_LE_BackupCompleted = 56, NDB_LE_BackupAborted = 57 }; #ifdef __cplusplus } #endif #endif
ndb/include/ndbapi/Ndb.hpp +3 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,9 @@ an ordered index, - NdbRecAttr represents an attribute value - NdbDictionary represents meta information about tables and attributes. - NdbError contains the specification for an error. In addition, the NDB API defines a structure NdbError, which contains the specification for an error. It is also possible to receive "events" triggered when data in the database in changed. This is done through the NdbEventOperation class. Loading