Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-8118

mongorestore namespace renaming

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • 3.4.0
    • None
    • None

    Description

      Re: TOOLS-1234; for the 3.4.0 release.

      Overview of changes:

      • five new command line options:
        • '--nsExclude <ns-pattern>' excludes matching namespaces. Can be used in
          multiplicity.
        • '--nsInclude <ns-pattern>' includes matching namespaces. Can be used in
          multiplicity. Includes are processed before excludes, permitting their
          use in combination.
        • '--nsFrom <ns-pattern>' and '--nsTo <ns-pattern>' correspond to each
          other according to the order in which they are specified. Can be used in
          multiplicity.
        • '--dryRun' stops the program before any restoring begins.
      • namespace pattern: <ns-pattern>
        • permits includes/excludes/renames to refer to any namespace that
          matches a pattern comprised of wild cards, which match their smallest
          valid occurrence.
        • for all includes, all excludes, and simple replacements, asterisks may
          be used as wild cards. Replacements correspond linearly to matches.
          Literal asterisks and backslashes (*, \) must be backslash-escaped.
          • examples:
            • --nsFrom 'prod.*' --nsTo 'staging.*'
            • --nsFrom '*.user*' --nsTo '*.member*'
            • --nsExclude 'tests.*' --nsExclude '*.test*'
            • --nsInclude 'internal.*' --nsExclude '*.top_secret'
        • for more complex replacements, dollar sign-delimited wild cards can
          assign a matching variable in the form of '$var$'. Replacements do not
          need to be linear.
          • examples:
            • --nsFrom '$db$.user$stuff$' --nsTo 'user.$stuff$.$db$'
            • --nsFrom 'test_$stack$.$coll$' --nsTo 'recover.$stack$.$coll$'

      Attachments

        Activity

          People

            allison.moore@mongodb.com Allison Reinheimer Moore
            lucas.morales Lucas Morales
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              7 years, 11 weeks, 2 days ago