Skip to content

feat(datautils): Map deep copy + For Each#2245

Merged
Cobalt0s merged 2 commits into
mainfrom
cobalt0s/map-utils
Nov 5, 2025
Merged

feat(datautils): Map deep copy + For Each#2245
Cobalt0s merged 2 commits into
mainfrom
cobalt0s/map-utils

Conversation

@Cobalt0s
Copy link
Copy Markdown
Contributor

@Cobalt0s Cobalt0s commented Oct 31, 2025

Description

  • Extended ForEach to support error exit via ForEachWithErr.
  • ToAnySlice converts []myType to []any. Otherwise need to create slice and populate the usual way while it is simple conversion, in golang there is not OOB solution.
  • Map deep copy will be used for creating payload from each Record. To avoid modifying the same data structure, I am using deep copy.

Copy link
Copy Markdown
Contributor Author

Cobalt0s commented Oct 31, 2025

@Cobalt0s Cobalt0s self-assigned this Oct 31, 2025
@Cobalt0s Cobalt0s changed the title feat(datautils): Map deep copy feat(datautils): Map deep copy + For Each Oct 31, 2025
@Cobalt0s Cobalt0s force-pushed the cobalt0s/map-utils branch 2 times, most recently from efac609 to c8d4901 Compare October 31, 2025 02:48
@Cobalt0s Cobalt0s requested a review from laurenzlong October 31, 2025 02:53
@Cobalt0s Cobalt0s marked this pull request as ready for review October 31, 2025 02:53
@Cobalt0s Cobalt0s force-pushed the cobalt0s/batch-write-constructor branch from 3e781e6 to d5584d0 Compare November 3, 2025 21:57
@Cobalt0s Cobalt0s force-pushed the cobalt0s/batch-write-constructor branch from d5584d0 to 5625848 Compare November 4, 2025 17:33
@Cobalt0s Cobalt0s requested a review from anushat05 November 4, 2025 22:53
Copy link
Copy Markdown
Contributor

@anushat05 anushat05 left a comment

Choose a reason for hiding this comment

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

Have we tested these utils in someway to verify them, especially edge cases like empty and error scenarios?

Base automatically changed from cobalt0s/batch-write-constructor to main November 4, 2025 23:42
@Cobalt0s Cobalt0s requested a review from anushat05 November 5, 2025 00:20
@Cobalt0s Cobalt0s merged commit f8262da into main Nov 5, 2025
6 checks passed
@Cobalt0s Cobalt0s deleted the cobalt0s/map-utils branch November 5, 2025 00:45
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.

2 participants