[DOCS-13197] Investigate changes in SERVER-38691: serverInfo not present in explain output for aggregation Created: 04/Nov/19  Updated: 13/Nov/23  Resolved: 09/Jun/20

Status: Closed
Project: Documentation
Component/s: manual, Server
Affects Version/s: None
Fix Version/s: 4.2.2, 4.0.14, 4.3.2, 3.6.16, Server_Docs_20231030, Server_Docs_20231106, Server_Docs_20231105, Server_Docs_20231113

Type: Task Priority: Major - P3
Reporter: Backlog - Core Eng Program Management Team Assignee: Jeffrey Allen
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Documented
documents SERVER-38691 serverInfo not present in explain out... Closed
Participants:
Days since reply: 3 years, 35 weeks, 1 day ago
Epic Link: DOCS: 4.4 Server Release Work

 Description   

Description

Downstream Change Summary

Previously, an aggregation explain plan would sometimes not include serverInfo; this has been fixed.

Also, for a sharded explain plan, we previously only included the serverInfo for each shard. Now we also include the serverInfo for the mongos. (https://docs.mongodb.com/manual/reference/explain-results/index.html#serverinfo)

Description of Linked Ticket

Explain output for find commands include a  serverInfo object that contains version information:

> db.foo.explain().find().finish().serverInfo
{
	"host" : "MacBook-Pro.local",
	"port" : 27017,
	"version" : "4.1.4",
	"gitVersion" : "2f4b5918497b09a226a3ec5dcff930edd52ea1e9"
} 

However, this information is not available for aggregation commands:

> db.foo.explain().aggregate([])
{
	"stages" : [
		{
			"$cursor" : {
				"query" : {
					
				},
				"queryPlanner" : {
					"plannerVersion" : 1,
					"namespace" : "test.foo",
					"indexFilterSet" : false,
					"parsedQuery" : {
						
					},
					"queryHash" : "8B3D4AB8",
					"winningPlan" : {
						"stage" : "COLLSCAN",
						"direction" : "forward"
					},
					"rejectedPlans" : [ ]
				}
			}
		}
	],
	"ok" : 1
} 

This would be helpful to include for more complete information when troubleshooting .

Scope of changes

Impact to Other Docs

MVP (Work and Date)

Resources (Scope or Design Docs, Invision, etc.)



 Comments   
Comment by Githook User [ 09/Jun/20 ]

Author:

{'name': 'jeff-allen-mongo', 'email': 'jeffrey.allen@10gen.com', 'username': 'jeff-allen-mongo'}

Message: (DOCS-13197): Explain result improvements for mongos
Branch: v3.6
https://github.com/mongodb/docs/commit/fe7e43754ef2046f6af0de5b0660e384547516cd

Comment by Githook User [ 09/Jun/20 ]

Author:

{'name': 'jeff-allen-mongo', 'email': 'jeffrey.allen@10gen.com', 'username': 'jeff-allen-mongo'}

Message: (DOCS-13197): Explain result improvements for mongos
Branch: v4.0
https://github.com/mongodb/docs/commit/81d04fe182f705225c898bde2cc69c1ed5164580

Comment by Githook User [ 09/Jun/20 ]

Author:

{'name': 'jeff-allen-mongo', 'email': 'jeffrey.allen@10gen.com', 'username': 'jeff-allen-mongo'}

Message: (DOCS-13197): Explain result improvements for mongos
Branch: v4.2
https://github.com/mongodb/docs/commit/bc1664cfd15031e3fc6f84cb5655b042ceb07954

Comment by Githook User [ 09/Jun/20 ]

Author:

{'name': 'jeff-allen-mongo', 'email': 'jeffrey.allen@10gen.com', 'username': 'jeff-allen-mongo'}

Message: (DOCS-13197): Explain result improvements for mongos
Branch: master
https://github.com/mongodb/docs/commit/733244e032f0d3a7696452bf2d337e2d524e2e80

Generated at Thu Feb 08 08:07:10 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.