0

After connecting a client to Mongoc with Julia (Version 1.11.1). I try to disconnect. I found this :

julia> destroy!(client)
ERROR: UndefVarError: `destroy!` not defined in `Main`
Suggestion: check for spelling errors or missing imports.
Stacktrace:
 [1] top-level scope
   @ REPL

Is there a way to disconnect from MongoDB ? Thank

2
  • 1
    The function may not be exported. Have you tried MongoDB.destroy!(client) ?
    – Bill
    Commented Nov 28 at 4:06
  • Yes it is good : Mongoc.destroy!(client) Commented Nov 29 at 11:10

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.