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

Enable partial indexes on time-series collections

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.3.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • QO 2021-09-06, QO 2021-09-20, QO 2021-10-04, QO 2021-11-29, QO 2021-12-13, QO 2021-12-27, QO 2022-01-10, QO 2022-01-24
    • 69

      When someone creates a partial index on a time-series collection, internally we will create a partial index on the buckets collection. The user specifies the partialFilterExpression as a predicate on events, but we'll translate it to a predicate on buckets.

      This sounds identical to how we push down $match predicates past the $_internalUnpackBucket stage. We should make sure that logic is factored out into some helper that can be called both from DocumentSource::optimize() and from CmdCreateIndexes.

      For example:

      • Predicates on metadata are pushed down exactly
      • $lt predicates on measurements are pushed down as $lt on control.min
      • $geoWithin is pushed down as $_internalBucketGeoWithin

            Assignee:
            david.percy@mongodb.com David Percy
            Reporter:
            david.percy@mongodb.com David Percy
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: