Skip to content

Bug 1981813 - [phab-etl] track transactions in the Phab-ETL#8

Merged
dklawren merged 9 commits intomozilla-conduit:mainfrom
dklawren:1981813
Nov 5, 2025
Merged

Bug 1981813 - [phab-etl] track transactions in the Phab-ETL#8
dklawren merged 9 commits intomozilla-conduit:mainfrom
dklawren:1981813

Conversation

@dklawren
Copy link
Contributor

@dklawren dklawren commented Oct 29, 2025

This creates a new transactions table that contains status changes for all revisions. Schema changes will be made in proper place to add the following:

  bq_metrics_transactions_schema = jsonencode([
    { name = "revision_id", type = "INT64" },
    { name = "transaction_id", type = "INT64" },
    { name = "transaction_type", type = "STRING" },
    { name = "date_created", type = "TIMESTAMP" },
    { name = "author_username", type = "STRING" },
    { name = "author_email", type = "STRING" },
    { name = "old_value", type = "STRING" },
    { name = "new_value", type = "STRING" },
  ])

@dklawren dklawren requested review from cgsheeh and Copilot October 29, 2025 03:00
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds transaction tracking functionality to the Phabricator ETL pipeline to capture state changes on revisions. The implementation follows the existing pattern used for comments, diffs, and other data entities.

Key changes:

  • New get_transactions() function that queries and transforms transaction data for state change events
  • Integration of transactions data into the BigQuery pipeline with proper staging and merge operations
  • Configuration for a new BQ_TRANSACTIONS_TABLE_ID environment variable

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Member

@cgsheeh cgsheeh left a comment

Choose a reason for hiding this comment

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

LGTM.

@dklawren dklawren requested review from cgsheeh and Copilot November 4, 2025 16:06
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@dklawren dklawren requested a review from cgsheeh November 5, 2025 01:59
Copy link
Member

@cgsheeh cgsheeh left a comment

Choose a reason for hiding this comment

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

LGTM!

Co-authored-by: Connor Sheehan <sheehan@mozilla.com>
@dklawren dklawren merged commit 5439879 into mozilla-conduit:main Nov 5, 2025
1 check passed
@dklawren dklawren deleted the 1981813 branch November 5, 2025 14:26
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.

3 participants