Advertisement
the_cec

explain_query_geo_category

Oct 2nd, 2015
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JSON 5.71 KB | None | 0 0
  1. {
  2.     "queryPlanner" : {
  3.         "plannerVersion" : 1,
  4.         "namespace" : "poi_database_production.pois",
  5.         "indexFilterSet" : false,
  6.         "parsedQuery" : {
  7.             "$and" : [
  8.                 {
  9.                     "status" : {
  10.                         "$eq" : "enabled"
  11.                     }
  12.                 },
  13.                 {
  14.                     "category_ids" : {
  15.                         "$in" : [
  16.                             ObjectId("56056db896b23c29e2000001")
  17.                         ]
  18.                     }
  19.                 },
  20.                 {
  21.                     "location" : {
  22.                         "$near" : {
  23.                             "$geometry" : {
  24.                                 "type" : "Point",
  25.                                 "coordinates" : [
  26.                                     9,
  27.                                     45.98
  28.                                 ]
  29.                             }
  30.                         }
  31.                     }
  32.                 }
  33.             ]
  34.         },
  35.         "winningPlan" : {
  36.             "stage" : "LIMIT",
  37.             "limitAmount" : 0,
  38.             "inputStage" : {
  39.                 "stage" : "GEO_NEAR_2DSPHERE",
  40.                 "keyPattern" : {
  41.                     "location" : "2dsphere",
  42.                     "status" : 1,
  43.                     "category_ids" : 1,
  44.                     "properties.property_id" : 1,
  45.                     "properties.value" : 1
  46.                 },
  47.                 "indexName" : "location_2dsphere_status_1_category_ids_1_properties.property_id_1_properties.value_1",
  48.                 "inputStage" : {
  49.                     "stage" : "FETCH",
  50.                     "inputStage" : {
  51.                         "stage" : "IXSCAN",
  52.                         "filter" : {
  53.                             "TwoDSphereKeyInRegionExpression" : true
  54.                         },
  55.                         "keyPattern" : {
  56.                             "location" : "2dsphere",
  57.                             "status" : 1,
  58.                             "category_ids" : 1,
  59.                             "properties.property_id" : 1,
  60.                             "properties.value" : 1
  61.                         },
  62.                         "indexName" : "location_2dsphere_status_1_category_ids_1_properties.property_id_1_properties.value_1",
  63.                         "isMultiKey" : true,
  64.                         "direction" : "forward",
  65.                         "indexBounds" : {
  66.                             "location" : [
  67.                                 "[\"2f0330020\", \"2f0330020\"]",
  68.                                 "[\"2f03300201\", \"2f03300201\"]",
  69.                                 "[\"2f033002011\", \"2f033002011\"]",
  70.                                 "[\"2f0330020112\", \"2f0330020112\"]",
  71.                                 "[\"2f03300201120\", \"2f03300201121\")",
  72.                                 "[\"2f03300201123\", \"2f03300201124\")",
  73.                                 "[\"2f0330020113\", \"2f0330020114\")",
  74.                                 "[\"2f033002012\", \"2f033002012\"]",
  75.                                 "[\"2f0330020120\", \"2f0330020120\"]",
  76.                                 "[\"2f03300201203\", \"2f03300201204\")"
  77.                             ],
  78.                             "status" : [
  79.                                 "[\"enabled\", \"enabled\"]"
  80.                             ],
  81.                             "category_ids" : [
  82.                                 "[ObjectId('56056db896b23c29e2000001'), ObjectId('56056db896b23c29e2000001')]"
  83.                             ],
  84.                             "properties.property_id" : [
  85.                                 "[MinKey, MaxKey]"
  86.                             ],
  87.                             "properties.value" : [
  88.                                 "[MinKey, MaxKey]"
  89.                             ]
  90.                         }
  91.                     }
  92.                 }
  93.             }
  94.         },
  95.         "rejectedPlans" : [ ]
  96.     },
  97.     "executionStats" : {
  98.         "executionSuccess" : true,
  99.         "nReturned" : 101,
  100.         "executionTimeMillis" : 23,
  101.         "totalKeysExamined" : 5158,
  102.         "totalDocsExamined" : 2460,
  103.         "executionStages" : {
  104.             "stage" : "LIMIT",
  105.             "nReturned" : 101,
  106.             "executionTimeMillisEstimate" : 0,
  107.             "works" : 5262,
  108.             "advanced" : 101,
  109.             "needTime" : 5160,
  110.             "needFetch" : 0,
  111.             "saveState" : 41,
  112.             "restoreState" : 41,
  113.             "isEOF" : 1,
  114.             "invalidates" : 0,
  115.             "limitAmount" : 0,
  116.             "inputStage" : {
  117.                 "stage" : "GEO_NEAR_2DSPHERE",
  118.                 "nReturned" : 101,
  119.                 "executionTimeMillisEstimate" : 0,
  120.                 "works" : 5261,
  121.                 "advanced" : 101,
  122.                 "needTime" : 5160,
  123.                 "needFetch" : 0,
  124.                 "saveState" : 41,
  125.                 "restoreState" : 41,
  126.                 "isEOF" : 0,
  127.                 "invalidates" : 0,
  128.                 "keyPattern" : {
  129.                     "location" : "2dsphere",
  130.                     "status" : 1,
  131.                     "category_ids" : 1,
  132.                     "properties.property_id" : 1,
  133.                     "properties.value" : 1
  134.                 },
  135.                 "indexName" : "location_2dsphere_status_1_category_ids_1_properties.property_id_1_properties.value_1",
  136.                 "searchIntervals" : [ ],
  137.                 "inputStage" : {
  138.                     "stage" : "FETCH",
  139.                     "nReturned" : 2460,
  140.                     "executionTimeMillisEstimate" : 0,
  141.                     "works" : 5159,
  142.                     "advanced" : 2460,
  143.                     "needTime" : 2698,
  144.                     "needFetch" : 0,
  145.                     "saveState" : 41,
  146.                     "restoreState" : 41,
  147.                     "isEOF" : 1,
  148.                     "invalidates" : 0,
  149.                     "docsExamined" : 2460,
  150.                     "alreadyHasObj" : 0,
  151.                     "inputStage" : {
  152.                         "stage" : "IXSCAN",
  153.                         "filter" : {
  154.                             "TwoDSphereKeyInRegionExpression" : true
  155.                         },
  156.                         "nReturned" : 2460,
  157.                         "executionTimeMillisEstimate" : 0,
  158.                         "works" : 5159,
  159.                         "advanced" : 2460,
  160.                         "needTime" : 2698,
  161.                         "needFetch" : 0,
  162.                         "saveState" : 41,
  163.                         "restoreState" : 41,
  164.                         "isEOF" : 1,
  165.                         "invalidates" : 0,
  166.                         "keyPattern" : {
  167.                             "location" : "2dsphere",
  168.                             "status" : 1,
  169.                             "category_ids" : 1,
  170.                             "properties.property_id" : 1,
  171.                             "properties.value" : 1
  172.                         },
  173.                         "indexName" : "location_2dsphere_status_1_category_ids_1_properties.property_id_1_properties.value_1",
  174.                         "isMultiKey" : true,
  175.                         "direction" : "forward",
  176.                         "indexBounds" : {
  177.                             "location" : [
  178.                                 "[\"2f0330020\", \"2f0330020\"]",
  179.                                 "[\"2f03300201\", \"2f03300201\"]",
  180.                                 "[\"2f033002011\", \"2f033002011\"]",
  181.                                 "[\"2f0330020112\", \"2f0330020112\"]",
  182.                                 "[\"2f03300201120\", \"2f03300201121\")",
  183.                                 "[\"2f03300201123\", \"2f03300201124\")",
  184.                                 "[\"2f0330020113\", \"2f0330020114\")",
  185.                                 "[\"2f033002012\", \"2f033002012\"]",
  186.                                 "[\"2f0330020120\", \"2f0330020120\"]",
  187.                                 "[\"2f03300201203\", \"2f03300201204\")"
  188.                             ],
  189.                             "status" : [
  190.                                 "[\"enabled\", \"enabled\"]"
  191.                             ],
  192.                             "category_ids" : [
  193.                                 "[ObjectId('56056db896b23c29e2000001'), ObjectId('56056db896b23c29e2000001')]"
  194.                             ],
  195.                             "properties.property_id" : [
  196.                                 "[MinKey, MaxKey]"
  197.                             ],
  198.                             "properties.value" : [
  199.                                 "[MinKey, MaxKey]"
  200.                             ]
  201.                         },
  202.                         "keysExamined" : 5158,
  203.                         "dupsTested" : 0,
  204.                         "dupsDropped" : 0,
  205.                         "seenInvalidated" : 0,
  206.                         "matchTested" : 2460
  207.                     }
  208.                 }
  209.             }
  210.         }
  211.     },
  212.     "serverInfo" : {
  213.         "host" : "speedy.local",
  214.         "port" : 27017,
  215.         "version" : "3.0.3",
  216.         "gitVersion" : "nogitversion"
  217.     },
  218.     "ok" : 1
  219. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement