HCE project C++ developers source code library  1.1.1
HCE project developer library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
SphinxMessageConst.hpp
Go to the documentation of this file.
1 
14 #ifndef SPHINX_MESSAGE_CONST_HPP
15 #define SPHINX_MESSAGE_CONST_HPP
16 
17 namespace HCE
18 {
19 namespace sphinx
20 {
21 namespace message_const
22 {
23 //-----------------------------------------------------------------------------
24  enum
25  {
99 // DONT_CREATED_FILE,
111  // TODO
112  };
113 
114  const char delimiter = ':';
115  const char space = ' ';
116  const char point = '.';
117 
118  const std::string loadConfigSuccess = "LOAD CONFIG SUCCESS";
119  const std::string host = "HOST";
120  const std::string port = "PORT";
121  const std::string index = "INDEX";
122  const std::string fileNotFound = "File not found";
123  const std::string fileNotOpen = "File not open";
124  const std::string searchdMaxMatches = "SEARCHD MAX MATCHES";
125  const std::string schemaNamesSize = "SCHEMA NAMES SIZE";
126  const std::string attributesCount = "ATTRIBUTES COUNT";
127  const std::string emptyListOfindexFiles = "Empty list of index files";
128  const std::string loadConfigFail = "LOAD CONFIG FAIL";
129  const std::string emptyResultData = "Empty result data";
130  const std::string incorrectJSONType = "Incorrect JSON type";
131  const std::string error = "Error";
132  const std::string errorMsg = "ErrorMsg";
133  const std::string errorCode = "ErrorCode";
134  const std::string serializeOutputJsonMessage = "Serialize OutputJsonMessage";
135  const std::string generateDefaultJSON = "Generate default JSON";
136  const std::string tryMakeIndexCommand = "TRY MAKE INDEX COMMAND";
137  const std::string documentContentIsEmpty = "Document content is empty";
138  const std::string indexName = "INDEX NAME";
139  const std::string makeIndexCommandSuccess = "!!! MAKE INDEX COMMAND SUCCESS !!!";
140  const std::string tryMakeAdminCommand = "TRY MAKE ADMIN COMMAND";
141  const std::string receivedEmptyCommandString = "Received empty command string";
142  const std::string unknownCommand = "Unknown command";
143  const std::string makeAdminCommandSuccess = "!!! MAKE ADMIN COMMAND SUCCESS !!!";
144  const std::string failedToCreateClient = "Failed to create client";
145  const std::string startSearchdReadConfig = "startSearchd read config";
146  const std::string waitStartSearchd = "!!! WAIT START SEARCHD !!!";
147  const std::string startSearchdFail = "Start searchd fail";
148  const std::string tryEasyStart = "TRY EASY START";
149  const std::string waitStopSearchd = "!!! WAIT STOP SEARCHD !!!";
150  const std::string stopSearchd = "STOP SEARCHD";
151  const std::string invalidClientHandle = "Invalid client handle";
152  const std::string invalidFilter = "Invalid filter";
153  const std::string addFilter = "Add filter";
154  const std::string invalidRangeOfFilter = "Invalid range of filter";
155  const std::string unknownFilterType = "Unknown filter type";
156  const std::string serverHostIsEmpty = "Server host is empty";
157  const std::string serverPortIsNull = "Server port is null";
158  const std::string setServerSuccess = "!!! SET SERVER SUCCESS !!!";
159  const std::string openConnectionError = "Open connection error";
160  const std::string easyStartSuccess = "!!! EASY START SUCCESS !!!";
161  const std::string easyStartFallen = "!!! EASY START FALLEN !!!";
162  const std::string fieldAlreadyExist = "Field already exist";
163  const std::string fieldNotFound = "Field not found";
164  const std::string indexAlreadyExist = "Index already exist";
165  const std::string indexNotFound = "Index not found";
166  const std::string notFoundInConfig = "NOT FOUND IN CONFIG";
167  const std::string listOfIndexesIsEmpty = "List of indexes is empty, check initialization";
168  const std::string searchdError = "SEARCHD ERROR";
169  const std::string searchdWarning = "SEARCHD WARNING";
170  const std::string searchdStoppedPidFileExist = "Searchd stopped. Pid file exist = ";
171  const std::string searchdStoppedButPidFileExist = "Searchd stoped but pid file exist";
172  const std::string searchdNotActivity = "Searchd not activity";
173  const std::string fieldNotFoundInCurrentSchema = "Field not found in current schema";
174  const std::string gettingParametersFail = "Getting parameters fail";
175  const std::string errorCleanDir = "ERROR CLEAN DIR";
176  const std::string foundIndexFile = "FOUND INDEX FILE";
177  const std::string removeIndexFile = "REMOVE INDEX FILE";
178  const std::string removeFileFail = "Remove file fail";
179  const std::string openDirFail = "Open dir fail";
180  const std::string errorGetFileList = "ERROR GET FILE LIST";
181  const std::string errorGetIndexList = "ERROR GET INDEX LIST";
182  const std::string emptyDataDir = "Empty data dir";
183  const std::string tryOpenFileFail = "Try open file fail";
184  const std::string tryUseAsDirectoryWasCanceled = "Try use as directory was canceled...";
185  const std::string closeDirFail = "Close dir fail";
186  const std::string foundFreeAllowedPort = "FOUND FREE ALLOWED PORT";
187  const std::string errorGetFreeAllowedPort = "ERROR GET FREE ALLOWED PORT";
188  const std::string errorMakeConfig = "ERROR MAKE CONFIG";
189  const std::string makeDirFail = "Make dir fail";
190  const std::string dontCreatedDir = "Don't created directory";
191 // const std::string dontCreatedFile = "Don't created file";
192  const std::string folderNotExist = "Forder not exist";
193  const std::string fileNotExist = "File not exist";
194  const std::string invalidDataContent = "Invalid data content";
195  const std::string invalidSchemaContent = "Invalid schema content";
196  const std::string commandLine = "COMMAND LINE";
197  const std::string indexationFail = "Indexation fail";
198  const std::string badBranchName = "Bad branch name";
199  const std::string makeSourceFail = "Make source fail";
200  const std::string makeSource = "MAKE SOURCE";
201  const std::string makeIndex = "MAKE INDEX";
202  const std::string receivedEmptyListOfBranches = "Received empty list of branches";
203  // TODO
204  const std::vector<std::pair<unsigned int, std::string> > messages =
205  {
207  { HOST, host },
208  { PORT, port },
209  { INDEX, index },
219  { ERROR, error },
220  { ERROR_MSG, errorMsg },
221  { ERROR_CODE, errorCode },
226  { INDEX_NAME, indexName },
241  { ADD_FILTER, addFilter },
279 // { DONT_CREATED_FILE, dontCreatedFile },
288  { MAKE_SOURCE, makeSource },
289  { MAKE_INDEX, makeIndex },
291 
292  // TODO
293  };
294 //-----------------------------------------------------------------------------
295 //-----------------------------------------------------------------------------
296 } // namespace message_const
297 } // namespace sphinx
298 } // namespace HCE
299 #endif // SPHINX_MESSAGE_CONST_HPP