Make Atlas Search and Vector Search Index creation blocking calls

XMLWordPrintableJSON

    • Python Drivers
    • Not Needed
    • None
    • None
    • None
    • None
    • None
    • None

      Context

      Atlas Search and Vector Search indexes have a limitation whereby it takes a non-trivial amount of time (in some cases up to 1 minute) to create an index on a collection. As a result, when making migrations that destroy and then re-create an index, you will always run into an index creation error. 

      This is a bug in implementation. Index creation and deletion should be blocking calls for our migration calls.

      Definition oI done

      Add a blocking function call to Atlas and Vector Search index mutations. The change in code should occur in the `add_index` and `remove_index` calls within the `django_mongodb_backend/schema.py` code.

       

      As well, remove all of our testing that implements a custom "wait_for_index_ready" operation. 

      Pitfalls

      We do not have consensus on an acceptable wait time. We should ping the Atlas Server team to get this number and abide by that. As well, we should make this decision public knowledge for the other ODM teams

            Assignee:
            Tim Graham
            Reporter:
            Jib Adegunloye
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: