(self, version, is_aurora)
return self.replication_metrics
Use either REPLICATION_METRICS_10, REPLICATION_METRICS_9_1, or
        REPLICATION_METRICS_9_1 + REPLICATION_METRICS_9_2, depending on the
        postgres version.
        Caches the result on a dictionary
Use either REPLICATION_METRICS_10, REPLICATION_METRICS_9_1, or
        REPLICATION_METRICS_9_1 + REPLICATION_METRICS_9_2, depending on the
        postgres version.
        Caches the result on a dictionary
Use either REPLICATION_METRICS_10 REPLICATION_METRICS_9_1 or REPLICATION_METRICS_9_1 + REPLICATION_METRICS_9_2 depending on the postgres version . Caches the result on a dictionary
def get_replication_metrics(self, version, is_aurora):
        """Use either REPLICATION_METRICS_10, REPLICATION_METRICS_9_1, or
        REPLICATION_METRICS_9_1 + REPLICATION_METRICS_9_2, depending on the
        postgres version.
        Caches the result on a dictionary
        """
        if self.replication_metrics is not None:
            return self.replication_metrics

        if is_aurora:
            logger.debug("Detected Aurora %s. Won't collect replication metrics", version)
            self.replication_metrics = {}
        elif version >= V10:
            self.replication_metrics = dict(REPLICATION_METRICS_10)
        elif version >= V9_1:
            self.replication_metrics = dict(REPLICATION_METRICS_9_1)
            if version >= V9_2:
                self.replication_metrics.update(REPLICATION_METRICS_9_2)
        return self.replication_metrics
def get_replication_metrics ( self , version , is_aurora ) : if self . replication_metrics is not None : return self . replication_metrics if is_aurora : logger . debug ( "Detected Aurora %s. Won't collect replication metrics" , version ) self . replication_metrics = { } elif version >= V10 : self . replication_metrics = dict ( REPLICATION_METRICS_10 ) elif version >= V9_1 : self . replication_metrics = dict ( REPLICATION_METRICS_9_1 ) if version >= V9_2 : self . replication_metrics . update ( REPLICATION_METRICS_9_2 ) return self . replication_metrics