def METHOD_NAME(aggregator, integration_check, pg_instance, pg_replica_instance2):
    check = integration_check(pg_replica_instance2)
    expected_tags = _get_expected_tags(check, pg_replica_instance2, db=DB_NAME)
    replica2_con = _get_superconn(pg_replica_instance2)
    replica2_cur = replica2_con.cursor()
    replica2_cur.execute('BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ;')
    replica2_cur.execute('select * from persons;')
    with _get_superconn(pg_instance) as conn:
        conn.autocommit = True
        with conn.cursor() as cur:
            cur.execute('update persons SET personid = 1 where personid = 1;')
            time.sleep(0.2)
            cur.execute('vacuum verbose persons;')
    _wait_for_value(
        pg_replica_instance2,
        lower_threshold=0,
        query="select confl_snapshot from pg_stat_database_conflicts where datname='datadog_test';",
    )
    check.check(pg_replica_instance2)
    aggregator.assert_metric('postgresql.conflicts.snapshot', value=1, tags=expected_tags)