Skip to content

Support OBJECT data type in table-model tablet writes - #64

Open
CritasWang wants to merge 1 commit into
apache:mainfrom
CritasWang:feat/tablet-object-write
Open

Support OBJECT data type in table-model tablet writes#64
CritasWang wants to merge 1 commit into
apache:mainfrom
CritasWang:feat/tablet-object-write

Conversation

@CritasWang

Copy link
Copy Markdown
Contributor

Summary

Ports the OBJECT data type write support from apache/iotdb-client-go#175 to the C# client.

  • Adds TSDataType.OBJECT = 12 and Client.GetDataTypeByStr("OBJECT")
  • Adds Tablet.BuildObjectValue / SetObjectValueAt with the Java-compatible segment frame: [1 byte isEOF][8 byte big-endian offset][content], including null-bit clearing after overwriting a null cell
  • Serializes OBJECT columns like BLOB in EstimateBufferSize / GetBinaryValues
  • Accepts OBJECT (and BLOB/STRING) in BinaryArrayColumnDecoder
  • Returns (Object) ... size summaries from RpcDataSet.GetObject/GetString/GetRow and rejects GetBinary for OBJECT columns

Tests

  • New tests/Apache.IoTDB.Tests/TabletObjectTests.cs covers segment framing, GenInsertTabletReq wire bytes, null bitmap behavior, and validation
  • Extended RpcDataSetTests for OBJECT read semantics and UtilsTests for size formatting

Verification: the solution builds; the full unit suite passes locally (59 tests) when run as net6:
dotnet test tests/Apache.IoTDB.Tests -p:TargetFramework=net6.0 --no-restore

Refs apache/iotdb-client-go#175

Add TSDataType.OBJECT (12) and table-model OBJECT write support:
- Tablet.BuildObjectValue / SetObjectValueAt with the Java-compatible 9-byte
segment header (isEOF + big-endian offset + content), including null-bit
clearing after a previously null cell is overwritten
- Serialize OBJECT columns like BLOB in EstimateBufferSize/GetBinaryValues
- Accept OBJECT (and STRING/BLOB) in BinaryArrayColumnDecoder
- Return "(Object) ..." summaries from RpcDataSet GetObject/GetString/GetRow
and reject GetBinary for OBJECT columns
- Add unit tests for segment framing, request bytes, null bitmap, read
semantics, and size formatting
Refs apache/iotdb-client-go#175
Sign up for freeto 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.

1 participant

@CritasWang