Beispiel #1
0
def s3_clear_published_bucket_pdm_test_output(context, timeout=30, **kwargs):
    console_printer.print_info(
        "Executing 's3_clear_published_bucket_pdm_test_output' fixture"
    )
    aws_helper.clear_s3_prefix(
        context.published_bucket, context.pdm_test_output_s3_prefix, False
    )
Beispiel #2
0
def s3_clear_pdm_start(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_pdm_start' fixture")
    aws_helper.clear_s3_prefix(
        context.published_bucket,
        os.path.join(context.fixture_path_local, "pdm-test-data"),
        True,
    )
Beispiel #3
0
def s3_clear_historic_data_start(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_historic_data_start' fixture")
    aws_helper.clear_s3_prefix(
        context.s3_ingest_bucket,
        os.path.join(context.ucfs_historic_data_prefix, context.test_run_name),
        True,
    )
Beispiel #4
0
def s3_clear_snapshot(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_snapshot' fixture")
    aws_helper.clear_s3_prefix(
        context.mongo_snapshot_bucket,
        os.path.join(context.mongo_snapshot_path, context.test_run_name),
        True,
    )
    aws_helper.clear_s3_prefix(
        context.mongo_snapshot_bucket,
        os.path.join(context.snapshot_s3_status_path, context.test_run_name),
        True,
    )
    context.add_cleanup(print, "Executing 's3_clear_snapshot' cleanup")
    context.add_cleanup(
        aws_helper.clear_s3_prefix,
        context.mongo_snapshot_bucket,
        os.path.join(context.mongo_snapshot_path, context.test_run_name),
        True,
    )
    context.add_cleanup(
        aws_helper.clear_s3_prefix,
        context.mongo_snapshot_bucket,
        os.path.join(context.snapshot_s3_status_path, context.test_run_name),
        True,
    )
Beispiel #5
0
def s3_clear_corporate_data_start(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_corporate_data_start' fixture")

    aws_helper.clear_s3_prefix(
        context.corporate_storage_s3_bucket_id,
        context.cdl_data_load_s3_base_prefix_tests,
        True,
    )
Beispiel #6
0
def s3_clear_k2hb_manifests_main(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_k2hb_manifests_main' fixture")
    console_printer.print_info(
        f"Clearing manifests from '{context.k2hb_manifest_write_s3_bucket}/{context.k2hb_main_manifest_write_s3_prefix}'"
    )
    aws_helper.clear_s3_prefix(
        context.k2hb_manifest_write_s3_bucket,
        context.k2hb_main_manifest_write_s3_prefix,
        True,
        False,
    )
Beispiel #7
0
def s3_clear_dlq(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_dlq' fixture")
    aws_helper.clear_s3_prefix(
        context.s3_ingest_bucket, context.s3_dlq_path_and_date_prefix, True
    )
    context.add_cleanup(print, "Executing 's3_clear_dlq' cleanup")
    context.add_cleanup(
        aws_helper.clear_s3_prefix,
        context.s3_ingest_bucket,
        context.s3_dlq_path_and_date_prefix,
        True,
    )
Beispiel #8
0
def s3_clear_snapshot_output(context, snapshot_type):
    for topic in context.topics:
        snapshot_s3_full_output_path = (
            snapshots_helper.generate_snapshot_output_s3_path(
                context.snapshot_s3_output_path,
                topic,
                context.db_name,
                context.formatted_date,
                snapshot_type,
            )
        )
        aws_helper.clear_s3_prefix(
            context.snapshot_s3_output_bucket, snapshot_s3_full_output_path, True
        )
        context.add_cleanup(
            print, f"Executing 's3_clear_snapshot_output' cleanup for topic '{topic}'"
        )
        context.add_cleanup(
            aws_helper.clear_s3_prefix,
            context.snapshot_s3_output_bucket,
            snapshot_s3_full_output_path,
            True,
        )
Beispiel #9
0
def s3_clear_manifest_output(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_manifest_output' fixture")
    aws_helper.clear_s3_prefix(
        context.manifest_s3_bucket, context.manifest_s3_output_prefix_queries, True
    )
    aws_helper.clear_s3_prefix(
        context.manifest_s3_bucket, context.manifest_s3_output_prefix_templates, True
    )
    aws_helper.clear_s3_prefix(
        context.manifest_s3_bucket, context.manifest_s3_output_parquet_location, False
    )
Beispiel #10
0
def s3_clear_kickstart_start(context, timeout=30, **kwargs):
    console_printer.print_info("Executing 's3_clear_kickstart_adg_start' fixture")
    aws_helper.clear_s3_prefix(context.published_bucket, "kickstart-e2e-tests", False)