Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add iceberg high availability on table using rename #246

Merged
merged 1 commit into from
Apr 24, 2023

Conversation

Jrmyy
Copy link
Contributor

@Jrmyy Jrmyy commented Apr 20, 2023

Description

This PR resolves #73. I had to add an extra parameter to the AthenaRelation, called s3_path_table_part to have the table stored in the correct location.

Models used to test - Optional

{{ config(
  materialized='table',
  partitioned_by=['hour(ts)'],
  table_type='iceberg',
  table_properties={
    'vacuum_max_snapshot_age_seconds': '86400',
    'optimize_rewrite_delete_file_threshold': '2'
  }
) }}

SELECT cast(t.ts AS timestamp(6)) AS ts
FROM
    unnest(
        sequence(
            current_date - INTERVAL '1' DAY,
            cast(REPLACE(cast(current_timestamp as varchar), ' UTC', '') as timestamp(6)),
            INTERVAL '1' MINUTE
        )
    ) AS t(ts)

Checklist

  • You followed contributing section
  • You added unit testing when necessary
  • [] You added functional testing when necessary

Copy link
Contributor

@nicor88 nicor88 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good, I left some minor comments.

@Jrmyy Jrmyy merged commit 58d09c3 into main Apr 24, 2023
@Jrmyy Jrmyy deleted the feat-iceberg-table-ha branch April 24, 2023 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Zero Downtime options for table materialization
2 participants