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

Pass through all options to listCollections command

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

      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.

            Assignee:
            grace.chong@mongodb.com Grace Chong (Inactive)
            Reporter:
            oleg.pudeyev@mongodb.com Oleg Pudeyev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: