示例#1
0
 def get_new_connection(self, *args, **kwargs):
     connections_total.labels(self.alias, self.vendor).inc()
     try:
         return super().get_new_connection(*args, **kwargs)
     except Exception:
         connection_errors_total.labels(self.alias, self.vendor).inc()
         raise
示例#2
0
 def get_new_connection(self, *args, **kwargs):
     connections_total.labels(self.alias, self.vendor).inc()
     try:
         return super(DatabaseWrapperMixin,
                      self).get_new_connection(*args, **kwargs)
     except:
         connection_errors_total.labels(self.alias, self.vendor).inc()
         raise
示例#3
0
 def get_new_connection(self, *args, **kwargs):
     connections_total.labels(self.alias, self.vendor).inc()
     try:
         return super(DatabaseWrapperMixin, self).get_new_connection(
             *args, **kwargs)
     except:
         connection_errors_total.labels(self.alias, self.vendor).inc()
         raise