Pass dbName to validateViewDefinitionBSON in DurableViewCatalog::onExternalInsert

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 6.1.0-rc0, 6.0.5
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • Execution Team 2022-06-13
    • 10
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      validateViewDefinitionBSON is meant to take in the db name, however in DurableViewCatalog::onExternalInsert we pass the full namespace. This causes this uassert to fail because database names are not allowed to contain a ".", and since we pass the full namespace for dbName, it will contain a ".". The exception is currently swallowed because we catch exceptions thrown by onExternalInsert.

      However, if we change DurableViewCatalog::onExternalInsert to correctly pass the dbName, we'll eventually hit this invariant in CollectionCatalog::createView because we don't actually ever take a collection lock on the view name currently - we have a lock on the database and the collection name itself, but not the view.

            Assignee:
            Dianna Hohensee (Inactive)
            Reporter:
            Janna Golden
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: