[SERVER-13006] getParameter for journalCommitInterval returns 0 Created: 03/Mar/14  Updated: 08/May/19  Resolved: 08/May/19

Status: Closed
Project: Core Server
Component/s: Admin
Affects Version/s: 2.6.0-rc0
Fix Version/s: 4.1.11

Type: Bug Priority: Minor - P4
Reporter: Mark Callaghan Assignee: Gregory Wlodarek
Resolution: Done Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:

1) start mongod without setting journalCommitInterval in the config file
2) run getParameter
3) add journalCommitInterval to the config file
4) run getParameter

Sprint: Storage NYC 2019-05-20
Participants:

 Description   

Per http://docs.mongodb.org/manual/reference/configuration-options the default value for journalCommitInterval is 100 or 30. Starting mongod from 2.6 RC0 using the MacOS binary (or something I build myself) I get 0 when it is not set in the config file.

> db.adminCommand({getParameter:1, journalCommitInterval:1})
{ "journalCommitInterval" : 0, "ok" : 1 }

When I explicitly set journalCommitInterval to 200 in the config file I get 200

> db.adminCommand({getParameter:1, journalCommitInterval:1})
{ "journalCommitInterval" : 200, "ok" : 1 }

This is confusing because a non-zero value really is being used given this code in dur.cpp

                unsigned ms = storageGlobalParams.journalCommitInterval;
                if( ms == 0 ) { 
                    // use default
                    ms = samePartition ? 100 : 30;
                }



 Comments   
Comment by Githook User [ 08/May/19 ]

Author:

{'email': 'gregory.wlodarek@mongodb.com', 'name': 'Gregory Wlodarek', 'username': 'GWlodarek'}

Message: SERVER-13006 getParameter for journalCommitInterval returns the appropriate value
Branch: master
https://github.com/mongodb/mongo/commit/39c90b5d46ec0c745c5df251e63d04712728741e

Comment by Asya Kamsky [ 31/Oct/14 ]

0 means it's using the default value.

Generated at Thu Feb 08 03:30:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.