[SERVER-58164] When group insert fails, the error type is not printed in logs. Created: 29/Jun/21  Updated: 29/Oct/23  Resolved: 01/Jul/21

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 4.4.8, 5.1.0-rc0

Type: Improvement Priority: Major - P3
Reporter: Wenbin Zhu Assignee: Wenbin Zhu
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
is related to SERVER-57671 Inital Sync fails when collections ar... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v5.0, v4.4
Sprint: Repl 2021-07-12
Participants:

 Description   

When group insert fails here, we only print a message and some attributes to the log, without actually printing the error itself. It seems to assume the caller of this method would print the error status, but  unfortunately the caller only checks if the status is OK and ignores it if it's an error instead of printing the error.  This makes it hard to debug issues since we don't know what caused it to fail. We should also exclude `NamespaceNotFound` error from the error log similar to DuplicateKey error, which can also be safely ignore during initial sync.



 Comments   
Comment by Vivian Ge (Inactive) [ 06/Oct/21 ]

Updating the fixversion since branching activities occurred yesterday. This ticket will be in rc0 when it’s been triggered. For more active release information, please keep an eye on #server-release. Thank you!

Comment by Githook User [ 20/Jul/21 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-58164 Log error code and exclude NamespaceNotFound in error logs when group insert fails.

(cherry picked from commit 6e00ab669dfae4bb5381d6c8a7766ca7a0bcf349)
Branch: v4.4
https://github.com/mongodb/mongo/commit/a395774d97caeaeb9f2019f6430332b152f3314d

Comment by Githook User [ 20/Jul/21 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-58164 Log error code and exclude NamespaceNotFound in error logs when group insert fails.

(cherry picked from commit 6e00ab669dfae4bb5381d6c8a7766ca7a0bcf349)
Branch: v5.0
https://github.com/mongodb/mongo/commit/2722d1b6534d8f125d2a80b572e63e32b708a276

Comment by Githook User [ 01/Jul/21 ]

Author:

{'name': 'Wenbin Zhu', 'email': 'wenbin.zhu@mongodb.com', 'username': 'WenbinZhu'}

Message: SERVER-58164 Log error code and exclude NamespaceNotFound in error logs when group insert fails.
Branch: master
https://github.com/mongodb/mongo/commit/6e00ab669dfae4bb5381d6c8a7766ca7a0bcf349

Generated at Thu Feb 08 05:43:45 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.