Skip to content

Conversation

erezrokah
Copy link
Member

Summary

Related to https://github.com/cloudquery/cloud/pull/4919 (internal issue).
Adds some useful helpers to deal with adding CQ internal columns


Use the following steps to ensure your PR is ready to be reviewed

  • Read the contribution guidelines 🧑‍🎓
  • Run go fmt to format your code 🖊
  • Lint your changes via golangci-lint run 🚨 (install golangci-lint here)
  • Update or add tests 🧪
  • Ensure the status checks below are successful ✅
@erezrokah erezrokah requested review from a team, Copilot and savme and removed request for savme March 31, 2025 10:28
@github-actions github-actions bot added the feat label Mar 31, 2025
Copy link

@Copilot 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 pull request adds helper functions to add internal columns to Apache Arrow records, supporting internal CQ columns functionality. Key changes include the implementation of new functions (e.g., hashRecord, nullUUIDsForRecord, StringArrayFromValue, TimestampArrayFromTime, ReplaceFieldInRecord, and AddInternalColumnsToRecord) in schema/arrow.go and corresponding tests in schema/arrow_test.go.

Reviewed Changes

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

File Description
schema/arrow_test.go Adds test records and unit tests for new internal columns helpers.
schema/arrow.go Implements helper functions for internal column handling.
@kodiakhq kodiakhq bot merged commit 1dea99c into main Mar 31, 2025
11 checks passed
@kodiakhq kodiakhq bot deleted the feat/add_arrow_record_utils branch March 31, 2025 12:28
kodiakhq bot pushed a commit that referenced this pull request Mar 31, 2025
🤖 I have created a release *beep* *boop* --- ## [4.75.0](v4.74.2...v4.75.0) (2025-03-31) ### Features * Add internal columns helpers ([#2105](#2105)) ([1dea99c](1dea99c)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
kodiakhq bot pushed a commit to cloudquery/cloudquery that referenced this pull request Mar 31, 2025
#### Summary Goes with cloudquery/plugin-sdk#2105 For Cloud syncs we should replace the internal columns if exist so we can trace back the synced data to the correct source name, sync time and sync group id (otherwise we'd get the ones of the original sync, e.g. `AWS->S3`)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

2 participants