Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-2143

Pass through all options to listCollections command

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.13.0.rc1
    • Component/s: Public API
    • Labels:

      Description

      Ruby driver has 3 listCollections-related helpers:

      • collections
      • list_collections
      • collections_names

      As a follow-up to https://jira.mongodb.org/browse/RUBY-2142, we should make it possible to pass all server-supported options to all of these helpers. This would entail:

       Changing all 3 methods to take options = {} as the argument.
      Changing the methods to forward options ultimately to the listCollections command.
       Adding the authorized_collections => authorizedCollections mapping.
      Verify that name_only option also works in list_collections, if so add it to the docstring & add a test.
      Updating docstrings on all methods to add all known options.

      Note that all of our helpers filter out system collections. Once authorized_collections is added as an argument, this filtering could potentially be removed to allow applications to discover system collections, though this would be a behavior change and potentially would need Mongoid work ahead of time to use the authorized_collections option.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              grace.chong Grace Chong
              Reporter:
              oleg.pudeyev Oleg Pudeyev
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: