[SERVER-68871] Remove 'isJsonLogNoConn()' and 'isJsonLog()' JS helpers and simplify callers Created: 16/Aug/22  Updated: 29/Oct/23  Resolved: 07/Sep/22

Status: Closed
Project: Core Server
Component/s: Logging, Testing Infrastructure
Affects Version/s: None
Fix Version/s: 6.2.0-rc0

Type: Improvement Priority: Major - P3
Reporter: David Storch Assignee: Ivan Fefer
Resolution: Fixed Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: QE 2022-09-19
Participants:

 Description   

The  isJsonLogNoConn() helper has a trivial implementation which always returns true. It looks like we can just delete this function after simplifying callers so that they no longer have code to handle the old logging format.

The story is similar for isJsonLog(). Its implementation runs the "buildinfo" command and returns true unless the version number is 4.2.x. In the master branch we are never testing against a 4.2.x version, so this function should always return true. We can simplify callers to assume that the logging format is the logv2 JSON format and then delete isJsonLog().



 Comments   
Comment by Githook User [ 07/Sep/22 ]

Author:

{'name': 'Ivan Fefer', 'email': 'ivan.fefer@mongodb.com', 'username': 'Fefer-Ivan'}

Message: SERVER-68871 Remove 'isJsonLogNoConn()' and 'isJsonLog()' functions because they always return true. Refactor the callers.
Branch: master
https://github.com/mongodb/mongo/commit/a7cda0d9cf32b7074b4c9a2efe6e6590b4dab564

Comment by Githook User [ 07/Sep/22 ]

Author:

{'name': 'Ivan Fefer', 'email': 'ivan.fefer@mongodb.com', 'username': 'Fefer-Ivan'}

Message: SERVER-68871 Remove 'isJsonLogNoConn()' and 'isJsonLog()' functions because they always return true. Refactor the callers.
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/dc6f9f79e06c909ed87f621bd6834555e00a0090

Generated at Thu Feb 08 06:11:57 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.