Skip to content

STRATCONN-6767 - [GEC] Treat updated events as add in mirror sync mode#3731

Open
varadarajan-tw wants to merge 6 commits intomainfrom
STRATCONN-6767
Open

STRATCONN-6767 - [GEC] Treat updated events as add in mirror sync mode#3731
varadarajan-tw wants to merge 6 commits intomainfrom
STRATCONN-6767

Conversation

@varadarajan-tw
Copy link
Copy Markdown
Contributor

@varadarajan-tw varadarajan-tw commented Apr 17, 2026

Fixes the Customer Match User List action in the Google Enhanced Conversions destination failing with "Could not determine operation type" when RETL sends updated events in mirror sync mode.

When syncMode is mirror, RETL subscribes to new, updated, and deleted events. However, the destination only handled new (→ ADD) and deleted (→ REMOVE), silently dropping or erroring on updated events. Since Google's API doesn't support an Update operation, updated events should be treated as add — the user identifiers may have changed and need to be re-synced.

Changes

  • functions.ts: Two places where mirror mode determines operation type now include updatedadd mapping:
    • determineOperationType (batch path)
    • The non-batch identifier loop
  • __tests__/userList.test.ts: Two new tests covering the updated event in mirror mode (single-event and batch paths)

Testing

Had to test directly on staging with Integrations as we don't have RETL subscription. This chane is pretty much contained to RETL -> GEC flow. So, this testing is sufficient.
Test Results

  • Added unit tests for new functionality
  • Tested end-to-end using the local server
  • [If destination is already live] Tested for backward compatibility of destination. Note: New required fields are a breaking change.
  • [Segmenters] Tested in the staging environment
  • [Segmenters] [If applicable for this change] Tested for regression with Hadron.

Security Review

  • Reviewed all field definitions for sensitive data (API keys, tokens, passwords, client secrets) and confirmed they use type: 'password'

New Destination Checklist

  • Extracted all action API versions to verioning-info.ts file. example

When syncMode is mirror, RETL sends updated events but the Customer Match
User List action had no handler for them, causing "Could not determine
operation type" errors. Updated events now map to the ADD operation since
identifiers may have changed.
Copy link
Copy Markdown
Contributor

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

Fixes Google Enhanced Conversions (Customer Match User List) handling of RETL updated events in mirror sync mode by treating them as add, preventing “Could not determine operation type” failures and ensuring identifiers are re-synced.

Changes:

  • Map event_name = updatedadd when syncMode = mirror in both non-batch and batch operation-determination paths.
  • Add unit tests covering updated events in mirror mode for single-event and batch execution.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
packages/destination-actions/src/destinations/google-enhanced-conversions/functions.ts Updates mirror-mode operation logic to treat updated as an add in both non-batch identifier extraction and batch operation detection.
packages/destination-actions/src/destinations/google-enhanced-conversions/__tests__/userList.test.ts Adds tests for updated mirror-mode behavior (single-event + batch) and extends coverage around sync mode handling.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 17, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.87%. Comparing base (f3ebd4f) to head (19abc61).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3731      +/-   ##
==========================================
- Coverage   81.07%   80.87%   -0.20%     
==========================================
  Files        1655     1347     -308     
  Lines       32088    25057    -7031     
  Branches     7090     5201    -1889     
==========================================
- Hits        26014    20266    -5748     
+ Misses       5101     3844    -1257     
+ Partials      973      947      -26     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copilot AI review requested due to automatic review settings April 21, 2026 09:39
payload.event_name === 'Audience Entered' ||
syncMode === 'add' ||
(syncMode === 'mirror' && payload.event_name === 'new')
(syncMode === 'mirror' && (payload.event_name === 'new' || payload.event_name === 'updated'))
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

More improvements for this are on the way with standardized audience membership evaluators

Copy link
Copy Markdown
Contributor

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 2 out of 2 changed files in this pull request and generated 2 comments.

@varadarajan-tw varadarajan-tw marked this pull request as ready for review April 21, 2026 09:50
@varadarajan-tw varadarajan-tw requested a review from a team as a code owner April 21, 2026 09:50
Copilot AI review requested due to automatic review settings April 21, 2026 09:50
Copy link
Copy Markdown
Contributor

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 2 out of 2 changed files in this pull request and generated 1 comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants