Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-347

Support deprecated "modifiers" FindOption in CRUD API

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Component/s: None
    • Labels:
    • $i18n.getText("admin.common.words.hide")
      Key Status/Resolution FixVersion
      CDRIVER-1522 Done 1.5.0
      CSHARP-1896 Done 2.10.0
      RUBY-1195 Works as Designed
      PYTHON-1217 Done 3.5
      CXX-1195 Done 3.2.0-rc0
      JAVA-2427 Done 3.5.0
      PERL-718 Done 2.0.0
      NODE-911 Works as Designed
      SCALA-291 Done 2.2.0
      PHPLIB-255 Done 1.1.0
      $i18n.getText("admin.common.words.show")
      #scriptField, #scriptField *{ border: 1px solid black; } #scriptField{ border-collapse: collapse; } #scriptField td { text-align: center; /* Center-align text in table cells */ } #scriptField td.key { text-align: left; /* Left-align text in the Key column */ } #scriptField a { text-decoration: none; /* Remove underlines from links */ border: none; /* Remove border from links */ } /* Add green background color to cells with FixVersion */ #scriptField td.hasFixVersion { background-color: #00FF00; /* Green color code */ } /* Center-align the first row headers */ #scriptField th { text-align: center; } Key Status/Resolution FixVersion CDRIVER-1522 Done 1.5.0 CSHARP-1896 Done 2.10.0 RUBY-1195 Works as Designed PYTHON-1217 Done 3.5 CXX-1195 Done 3.2.0-rc0 JAVA-2427 Done 3.5.0 PERL-718 Done 2.0.0 NODE-911 Works as Designed SCALA-291 Done 2.2.0 PHPLIB-255 Done 1.1.0

      The CRUD specification now states:

      Q: Where did modifiers go in FindOptions?
      MongoDB 3.2 introduced the find command. As opposed to using the general "modifiers" field any longer, each relevant option is listed explicitly. Some options, such as "tailable" or "singleBatch" are not listed as they are derived from other fields. Upgrading a driver should be a simple procedure of deprecating the "modifiers" field and introducing the new fields. When a collision occurs, the explicitly specified field should override the value in "modifiers".

      Drivers still supporting a "modifiers" option for find() should only fall back to values in that document if the first-class option is not specified. This snippet from the PHP driver may serve as an example.

      • "comment" option falls back to "$comment" modifier option
      • "hint" option falls back to "$hint" modifier option
      • "max" option falls back to "$max" modifier option
      • "maxScan" option falls back to "$maxScan" modifier option
      • "maxTimeMS" option falls back to "$maxTimeMS" modifier option
      • "min" option falls back to "$min" modifier option
      • "returnKey" option falls back to "$returnKey" modifier option
      • "showRecordId" option falls back to "$showDiskLoc" modifier option
      • "sort" option falls back to "$orderby" modifier option
      • "snapshot" option falls back to "$snapshot" modifier option

      The CRUD spec does not dictate an "explain" option for find(); however, drivers should ensure that the "$explain" modifier is still supported for legacy queries (i.e. not using the find command).

            Assignee:
            Unassigned Unassigned
            Reporter:
            jmikola@mongodb.com Jeremy Mikola
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'slack.nextup.jira:slack-integration-plus'. Please contact your Jira administrators.