Skip to content

GH-551: [Java] Add TimeStamp*TZ support to ComplexCopier - #1414

Open
henriquejsza wants to merge 1 commit into
apache:mainfrom
henriquejsza:gh-551-complexcopier-timestamp-tz
Open

henriquejsza wants to merge 1 commit into
apache:mainfrom
henriquejsza:gh-551-complexcopier-timestamp-tz

Conversation

@henriquejsza

Copy link
Copy Markdown

What's Changed

ComplexCopier skipped every minor type that has type parameters except
Decimal, so copying a vector containing TimeStampSecTZ, TimeStampMilliTZ,
TimeStampMicroTZ, or TimeStampNanoTZ threw UnsupportedOperationException.

This generates the copy and writer-lookup cases for the timezone-aware
timestamp types the same way as the other scalar types, and passes the
timezone through to the struct writer so it is preserved. The fix is in the
FreeMarker template vector/src/main/codegen/templates/ComplexCopier.java;
the generated ComplexCopier is produced from it.

Added list, struct, and map copy tests for TimeStampNanoTZ.

Closes #551.

ComplexCopier skipped every minor type that has type parameters except
Decimal, so copying a vector containing TimeStampSecTZ, TimeStampMilliTZ,
TimeStampMicroTZ, or TimeStampNanoTZ threw UnsupportedOperationException.

Generate the copy and writer-lookup cases for the timezone-aware timestamp
types the same way as the other scalar types, and pass the timezone through
to the struct writer so it is preserved. Add list, struct and map copy tests
for TimeStampNanoTZ.

Closes apache#551.

Signed-off-by: henriquejsza <henriquejsza@gmail.com>
@github-actions

Copy link
Copy Markdown

Thank you for opening a pull request!

Please label the PR with one or more of:

  • bug-fix
  • chore
  • dependencies
  • documentation
  • enhancement

Also, add the 'breaking-change' label if appropriate.

See CONTRIBUTING.md for details.

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.

ComplexCopier is missing cases for TimeStamp*TZ

1 participant