Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-11946

colMod should expose padding factor, so one can tune it up and down

      This is important to be able to "hint" to the system the correct padding, as some workloads are heavy to start and tapper off. This type of workload makes it impossible to learn the padding factor when needed. It would not override the normal behavior just tune the current level for heuristics to still tune as more data is learned.

      It should behave like this, so that is not a new setting up just updating the existing data to help the engine make better INITIAL decisions.

      > db.col1.stats() 
      {      
      	"ns" 			: "foo.col1",
          "count" 		: 1,    
          "size" 			: 24,  
          "avgObjSize" 	: 24,      
          "storageSize" 	: 4096,   
          "numExtents" 	: 1,
       	"nindexes" 		: 1,        
       	"lastExtentSize" : 4096,        
       	"paddingFactor" : 1,
       	"systemFlags" 	: 1,     
       	"userFlags" 	: 0,        
       	"totalIndexSize" : 8176,
       	"indexSizes" : {               
       		"_id_" : 8176   
       	},      
       	"ok" : 1 
       } 
       >db.runCommand( {"collMod" : "col1" , "paddingFactor" : 1.3 } ) 
       {
       	"PaddingSize_old" : 1, 
       	"PaddingSize_new" : 1.3, 
       	"ok" : 1 
       } 
      > db.col1.stats()
      {      
      	"ns" 			: "foo.col1",      
       	"count" 		: 1,    
       	"size" 			: 24,    
       	"avgObjSize" 	: 24,    
       	"storageSize" 	: 4096,   
       	"numExtents" 	: 1,       
       	"nindexes" 		: 1,
       	"lastExtentSize" : 4096,       
       	"paddingFactor" : 1.3,  
       	"systemFlags" 	: 1,
       	"userFlags" 	: 0,       
       	"totalIndexSize" : 8176,        
       	"indexSizes" : {
         		"_id_" : 8176   
          },      
          "ok" : 1 
      }
      

      Pull request is ready once the test case is written.

            Assignee:
            Unassigned Unassigned
            Reporter:
            david.b.murphy.tx@gmail.com David Murphy
            Votes:
            2 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: