Skip to content

Conversation

@jgrantr
Copy link

@jgrantr jgrantr commented Nov 3, 2025

Note

Adds Redshift S3 load pipeline and hashed surrogate key support to the Postgres connector, improves DW delete/SCD handling, and introduces a release publish workflow.

  • Postgres connector (major enhancements):
    • Add Redshift-compatible S3 load path (streamToTableFromS3) and Redshift-specific staging (DISTSTYLE ALL, SORTKEY), with sort key discovery and COPY from S3.
    • Update fact/dimension imports: configurable batched deletes, prefer delete semantics, support hashed surrogate keys (with guarded configs), optional bypass of SCD logic, and use delete+reinsert strategy for large updates.
    • Improve dimension linking: surrogate date/time key handling, hashed key linking, and conditional ANALYZE; more robust temp table cleanup.
    • DDL updates: use bigint for SKs/dimension FKs when hashed keys, adjust default timestamps and index creation per engine.
  • Data Warehouse utilities:
    • combine.js: merge logic treats delete on either side as authoritative, simplifying updates vs. deletes.
    • load.js: route validation errors to Leo streams pipeline; minor stream/signature tweaks.
  • CI/CD:
    • New GitHub Actions workflow to publish the Postgres package on GitHub release.
  • Packages:
    • Version bumps and dependency updates across common, entity-table, and postgres packages.

Written by Cursor Bugbot for commit 1a4a4c8. This will update automatically on new commits. Configure here.

czirker and others added 27 commits March 3, 2023 13:32
…oading into the DW and then having a processing failure
ES-2516 - reset deleted flag on update or insert
…fixes

ES-2516 - don't write deletes to the CSV file/staging table
@jgrantr jgrantr requested a review from czirker November 3, 2025 17:42
@ch-snyk-sa
Copy link

ch-snyk-sa commented Nov 3, 2025

Snyk checks have failed. 31 issues have been found so far.

Status Scanner Critical High Medium Low Total (31)
Licenses 0 0 0 0 0 issues
Code Security 0 0 0 0 0 issues
Open Source Security 0 24 6 1 31 issues
Up to 10 code/snyk issues appear as inline comments below; view the rest through the details page.

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bug: Fixed: Correct Writable Property Name Used

Incorrect property check for stream writability. The code checks errorStream.Writable (capital W), but Node.js streams use the lowercase property writable (lowercase w) to check if a stream is writable. This check will always be falsy, causing the stream to never be properly closed. Should be errorStream.writable instead of errorStream.Writable.

common/datawarehouse/load.js#L317-L318

// close the error stream if open
if (errorStream && errorStream.Writable) {

Fix in Cursor Fix in Web


* @param error {string}
*/
function handleFailedValidation (ID, source, eventObj, error) {
function handleFailedValidation(ID, source, eventObj, error) {
Copy link

Choose a reason for hiding this comment

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

Bug: Incorrect Case-Sensitive Property Check Breaks Error Stream Initialization

Same incorrect property check as above. The code checks !errorStream.Writable but should check !errorStream.writable (lowercase w). This will cause the error stream initialization logic to be executed every time handleFailedValidation is called, potentially creating multiple pipelines for the same error stream.

Fix in Cursor Fix in Web

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.

5 participants