How to use the jardin.tools.retry function in jardin

To help you get started, we’ve selected a few jardin examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github instacart / jardin / jardin / database / drivers / sf.py View on Github external
    @retry(sf.InterfaceError, tries=3)
    def execute(self, *query):
        return super(DatabaseConnection, self).execute(*query)
github instacart / jardin / jardin / database / drivers / pg.py View on Github external
    @retry(pg.OperationalError, tries=3)
    def connect(self):
        connection = super(DatabaseConnection, self).connect()
        connection.initialize(config.logger)
        return connection
github instacart / jardin / jardin / database / drivers / mysql.py View on Github external
    @retry(DRIVER.OperationalError, tries=3)
    def connect(self):
        return super(DatabaseConnection, self).connect()
github instacart / jardin / jardin / database / drivers / sf.py View on Github external
    @retry(sf.OperationalError, tries=3)
    def connect(self):
        return super(DatabaseConnection, self).connect()
github instacart / jardin / jardin / database / drivers / pg.py View on Github external
    @retry(
        (
            pg.InterfaceError,
            pg.extensions.TransactionRollbackError,
            pg.extensions.QueryCanceledError
            ),
        tries=3)
    def execute(self, *query):
        return super(DatabaseConnection, self).execute(*query)
github instacart / jardin / jardin / database / drivers / mysql.py View on Github external
    @retry(DRIVER.InterfaceError, tries=3)
    def execute(self, *query):
        return super(DatabaseConnection, self).execute(*query)