Enhance aggregation functionality for fast collection cloning

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Works as Designed
    • Priority: Major - P3
    • None
    • Affects Version/s: 2.5.3
    • Component/s: None
    • Environment:
      Rails / Ruby
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      In mongo console I can clone a collection really fast by using the aggregate method, like this:

       

      db.sourcecollection.aggregate([\{$out: "targetcollection"}])

       

      Unfortunately, $out is not implemented in ruby driver.

       

      The only current way to clone a collection in ruby is by going through the documents. There should be the possibility to run the aggregation with '$out' in the pipeline. There is huge difference in terms of efficiency, especially when dealing with large collections.

       

      Thanks for reading this, i hope to be hearing from you soon.

            Assignee:
            Samuel Rossi (Inactive)
            Reporter:
            Stavros Souvatzis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: