With the following example:
class MyDatabase(object): def __init__(self, uri, user, password): self._driver = GraphDatabase.driver(uri, auth=(user, password)) def close(self): self._driver.close()
When should we call the
Looking at this post, it states not to close the connection. So, I'm in dilemma what to do and what not to do.
Because, we can use the database queries in different interval of time or simultaneously such as post books, post authors, etc. So, should I keep my database connection always open? Is there any downside if I close the connection after every database query in neo4j?