@@ -394,7 +394,12 @@ CHIP_ERROR DefaultICDClientStorage::StoreEntry(const ICDClientInfo & clientInfo)
394
394
DefaultStorageKeyAllocator::ICDClientInfoKey (clientInfo.peer_node .GetFabricIndex ()).KeyName (), backingBuffer.Get (),
395
395
static_cast <uint16_t >(len)));
396
396
397
- return IncreaseEntryCountForFabric (clientInfo.peer_node .GetFabricIndex ());
397
+ ReturnErrorOnFailure (IncreaseEntryCountForFabric (clientInfo.peer_node .GetFabricIndex ()));
398
+ ChipLogProgress (ICD,
399
+ " Store ICD entry successfully with peer nodeId " ChipLogFormatScopedNodeId
400
+ " and checkin nodeId " ChipLogFormatScopedNodeId,
401
+ ChipLogValueScopedNodeId (clientInfo.peer_node ), ChipLogValueScopedNodeId (clientInfo.check_in_node ));
402
+ return CHIP_NO_ERROR;
398
403
}
399
404
400
405
CHIP_ERROR DefaultICDClientStorage::IncreaseEntryCountForFabric (FabricIndex fabricIndex)
@@ -475,7 +480,10 @@ CHIP_ERROR DefaultICDClientStorage::DeleteEntry(const ScopedNodeId & peerNode)
475
480
mpClientInfoStore->SyncSetKeyValue (DefaultStorageKeyAllocator::ICDClientInfoKey (peerNode.GetFabricIndex ()).KeyName (),
476
481
backingBuffer.Get (), static_cast <uint16_t >(len)));
477
482
478
- return DecreaseEntryCountForFabric (peerNode.GetFabricIndex ());
483
+ ReturnErrorOnFailure (DecreaseEntryCountForFabric (peerNode.GetFabricIndex ()));
484
+ ChipLogProgress (ICD, " Remove ICD entry successfully with peer nodeId " ChipLogFormatScopedNodeId,
485
+ ChipLogValueScopedNodeId (peerNode));
486
+ return CHIP_NO_ERROR;
479
487
}
480
488
481
489
CHIP_ERROR DefaultICDClientStorage::DeleteAllEntries (FabricIndex fabricIndex)
@@ -508,7 +516,10 @@ CHIP_ERROR DefaultICDClientStorage::DeleteAllEntries(FabricIndex fabricIndex)
508
516
{
509
517
return mpClientInfoStore->SyncDeleteKeyValue (DefaultStorageKeyAllocator::ICDFabricList ().KeyName ());
510
518
}
511
- return StoreFabricList ();
519
+
520
+ ReturnErrorOnFailure (StoreFabricList ());
521
+ ChipLogProgress (ICD, " Remove all ICD entries successfully for fabric index %u" , fabricIndex);
522
+ return CHIP_NO_ERROR;
512
523
}
513
524
514
525
CHIP_ERROR DefaultICDClientStorage::ProcessCheckInPayload (const ByteSpan & payload, ICDClientInfo & clientInfo,
0 commit comments