@@ -157,7 +157,7 @@ namespace Plugin {
157157 }
158158
159159 int8_t MigrationPreparerImplementation::split (std::list<string>& list, string& value, std::string delimiter) {
160- LOGINFO (" split: %s" , value.c_str ());
160+ // LOGINFO("split: %s", value.c_str());
161161 string::size_type start = 0 , pos = 0 ;
162162 while ((pos = value.find (delimiter, start) )!= std::string::npos) {
163163 list.emplace_back (value.substr (start, pos - start));
@@ -178,7 +178,7 @@ namespace Plugin {
178178 }
179179 // Add the last element without an underscore
180180 value += *it;
181- LOGINFO (" join: %s" , value.c_str ());
181+ // LOGINFO("join: %s", value.c_str());
182182 return Core::ERROR_NONE;
183183 }
184184
@@ -196,7 +196,8 @@ namespace Plugin {
196196
197197 uint32_t MigrationPreparerImplementation::write (const string& name, const string &value) {
198198
199- LOGINFO (" [WRITE] params={name: %s, value: %s}" , name.c_str (), value.c_str ());
199+ // LOGINFO("[WRITE] params={name: %s, value: %s}", name.c_str(), value.c_str());
200+ LOGINFO (" Writing entry for name: %s" , name.c_str ());
200201 string entry;
201202 string key = name;
202203 string newValue = value;
@@ -232,7 +233,8 @@ namespace Plugin {
232233
233234 if (!dataStore.Open (false )) {
234235 LOGERR (" Failed to open migration datastore %s, errno: %d, reason: %s" , DATASTORE_PATH, errno, strerror (errno));
235- LOGERR (" Failed to create entry for {%s:%s} in migration datastore" , key.c_str (), newValue.c_str ());
236+ // LOGERR("Failed to create entry for {%s:%s} in migration datastore", key.c_str(), newValue.c_str());
237+ LOGERR (" Failed to create entry for name: %s in migration datastore" , key.c_str ());
236238 _dataStoreMutex.unlock ();
237239 return ERROR_OPEN;
238240 }
@@ -253,7 +255,8 @@ namespace Plugin {
253255 string oldValue = _valueEntry[_lineNumber[key] - 2 ];
254256
255257 if (oldValue == newValue) {
256- LOGWARN (" Entry {%s:%s} is already existing in the dataStore, returning success" , oldValue.c_str (), key.c_str ());
258+ // LOGWARN("Entry {%s:%s} is already existing in the dataStore, returning success", oldValue.c_str(), key.c_str());
259+ LOGWARN (" Entry for name: %s is already existing in the dataStore, returning success" , key.c_str ());
257260 _dataStoreMutex.unlock ();
258261 return Core::ERROR_NONE;
259262 }
@@ -279,23 +282,26 @@ namespace Plugin {
279282 return Core::ERROR_NONE;
280283 }
281284 result = WEXITSTATUS (result);
282- LOGERR (" Failed to update entry for {%s:%s} in migration datastore, v_secure_system failed with error %d" ,key.c_str (), newValue.c_str (), result);
285+ // LOGERR("Failed to update entry for {%s:%s} in migration datastore, v_secure_system failed with error %d",key.c_str(), newValue.c_str(), result);
286+ LOGERR (" Failed to update entry for name: %s in migration datastore, v_secure_system failed with error %d" ,key.c_str (), result);
283287 _dataStoreMutex.unlock ();
284288 return ERROR_WRITE;
285289 }
286290
287291 // Handle subsequent Write request
288292 if (!dataStore.Open (false )) {
289293 LOGERR (" Failed to create migration datastore %s, errno: %d, reason: %s" , DATASTORE_PATH, errno, strerror (errno));
290- LOGERR (" Failed to create entry for {%s:%s} in migration datastore" , key.c_str (), newValue.c_str ());
294+ // LOGERR("Failed to create entry for {%s:%s} in migration datastore", key.c_str(), newValue.c_str());
295+ LOGERR (" Failed to create entry for name: %s in migration datastore" , key.c_str ());
291296 _dataStoreMutex.unlock ();
292297 return ERROR_OPEN;
293298 }
294299
295300 // append new key-value pair to the dataStore
296301 if (!dataStore.Position (false , dataStore.Size () - 2 )) {
297302 LOGERR (" DataStore truncate failed with errno: %d, reason: %s\n " , errno, strerror (errno));
298- LOGERR (" Failed to create entry for {%s:%s} in migration datastore" , key.c_str (), newValue.c_str ());
303+ // LOGERR("Failed to create entry for {%s:%s} in migration datastore", key.c_str(), newValue.c_str());
304+ LOGERR (" Failed to create entry for %s in migration datastore" , key.c_str ());
299305 dataStore.Close ();
300306 _dataStoreMutex.unlock ();
301307 return ERROR_WRITE;
@@ -311,7 +317,7 @@ namespace Plugin {
311317
312318 uint32_t MigrationPreparerImplementation::read (const string& name, string &result) {
313319
314- LOGINFO (" [READ] params={ name: %s} " , name.c_str ());
320+ LOGINFO (" Reading entry for name: %s" , name.c_str ());
315321 string key = name;
316322
317323 if (!_fileExist) {
@@ -336,7 +342,7 @@ namespace Plugin {
336342
337343 uint32_t MigrationPreparerImplementation::Delete (const string& name) {
338344
339- LOGINFO (" [DELETE] params={ name: %s} " , name.c_str ());
345+ LOGINFO (" Deleting entry for name: %s" , name.c_str ());
340346 string key = name;
341347 int result;
342348
0 commit comments