Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Fix Java client time column access throwing ArrayIndexOutOfBoundsException for non-long typed getters

オープン 初心者向け
#17,407 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
72/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
静か
技術スタック
java
領域
databases

調査の方向性

IoTDBRpcDataSet.java から開始し、影響を受ける6つの ByTsBlockColumnIndex getter メソッドを getLongByTsBlockColumnIndex および getStringByTsBlockColumnIndex と併せて調査します。ツリーモデルの時間列パスを確認し、利用可能であれば関連する Java クライアントテストを実行します。完了の条件は、列 -1 にアクセスする代わりに、列挙されたすべての non-long getter が明確な StatementExecutionException を報告することです。

索引モデルが issue の本文から書いたものです。

説明

Search before asking
  • I searched in the issues and found nothing similar.
Version

Master

Describe the bug and provide the minimal reproduce step

In IoTDBRpcDataSet.java, several ByTsBlockColumnIndex getter methods do not handle the tsBlockColumnIndex < 0 case (time pseudo-column in tree model). Only getLongByTsBlockColumnIndex and getStringByTsBlockColumnIndex correctly handle this case.

When tree model is used, column index 1 maps to tsBlockColumnIndex = -1 (time column). Accessing it through typed getters other than getLong or getString causes ArrayIndexOutOfBoundsException from TsBlock.getColumn(-1).

Affected methods:

  • getBooleanByTsBlockColumnIndex
  • getIntByTsBlockColumnIndex
  • getFloatByTsBlockColumnIndex
  • getDoubleByTsBlockColumnIndex
  • getBinaryByTsBlockColumnIndex
  • getObjectByTsBlockColumnIndex

This is the Java equivalent of the C++ client bug fixed in #17400.

What did you expect to see?

A clear StatementExecutionException with message like "Cannot read boolean from time column" instead of an opaque ArrayIndexOutOfBoundsException.

What did you see instead?

ArrayIndexOutOfBoundsException with index -1.

Anything else?

No response

Are you willing to submit a PR?
  • I'm willing to submit a PR!
主要言語
Java
スター
6.4k
フォーク
1.2k
平均マージ
1日 8時間
マージ済み PR(30日)
129

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

apache/iotdb のほかの issue

apache/iotdb の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。