Skip to content

feat: introduce basic data types including decimal, blob and timestamp#10

Merged
leaves12138 merged 1 commit into
apache:mainfrom
lszskye:p1-2
May 25, 2026
Merged

feat: introduce basic data types including decimal, blob and timestamp#10
leaves12138 merged 1 commit into
apache:mainfrom
lszskye:p1-2

Conversation

@lszskye
Copy link
Copy Markdown
Contributor

@lszskye lszskye commented May 25, 2026

Purpose

Introduce the basic data types module including:

  • Decimal: A 128-bit decimal type compatible with Java Paimon's DecimalData.
  • Blob: A binary large object type that supports reading from file paths or blob descriptors.
  • Timestamp: An immutable timestamp type representing milliseconds + nanos-of-millisecond since epoch.
  • Logger: A pluggable logging framework with a default glog-based adapter, supporting custom logger registration and thread-safe initialization.

Internal utilities added:

  • BlobDescriptor: Serializable descriptor for blob references with versioned binary format (v1/v2 compatible with Java).
  • BlobDefs: Constants for blob file format (magic number, header layout, etc.).
  • BlobUtils: Helper functions for separating blob/non-blob fields in Arrow schemas and arrays.

Tests

  • BlobTest
  • BlobDescriptorTest
  • BlobUtilsTest
  • DecimalTest
  • TimestampTest
  • LoggerTest

API and Format

This change adds new public headers under include/paimon/data/:

  • blob.hBlob class
  • decimal.hDecimal class
  • timestamp.hTimestamp class

And extends include/paimon/logging.h with the Logger interface.

No existing API or storage format is changed.

Copy link
Copy Markdown

@leaves12138 leaves12138 left a comment

Choose a reason for hiding this comment

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

Thanks for migrating the basic data types and logging utilities. I compared the added files with the source snapshot; they match the staged migration with ASF header normalization. The PR is based on the current main and merges cleanly. I also checked line endings/trailing whitespace and ran a lightweight public-header syntax smoke check; no blocker found.

Non-blocking note: some implementation/test files still depend on components expected to arrive in later migration PRs, such as filesystem, IO streams, string/decimal utilities, and executor futures. That looks fine for the staged migration.

LGTM.

@leaves12138 leaves12138 merged commit 6968ab8 into apache:main May 25, 2026
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