elastic / elastic/elasticsearch-java

tasks.get endpoint fails to deserialize response when .response.failures array contains objects

オープン
#331 コメント 1 件 リアクション 10 件 担当者 0 名 GitHub で見る
Area: Specification
主要言語
Java
スター
524
フォーク
300
平均マージ
1日 11時間
マージ済み PR(30日)
16

説明

### Java API client version

8.2.3

### Java version

11

### Elasticsearch Version

8.2.0

### Problem description

When a response from the tasks.get endpoint includes a list of failures, `co.elastic.clients.elasticsearch.tasks.TaskStatus#failures` does not deserialize, and causes a `co.elastic.clients.json.UnexpectedJsonEventException` error. The response from the server is a list of Objects, but TaskStatus is expecting a list of Strings.
When it is deserialized, the following error message emitted:

> Unexpected JSON event 'START_OBJECT' instead of '[KEY_NAME, VALUE_STRING, VALUE_NUMBER, VALUE_TRUE, VALUE_FALSE]'

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

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

調査の方向性

tasks.get endpoint と co.elastic.clients.elasticsearch.tasks.TaskStatus#failures から始め、failures array にオブジェクトを含むレスポンスを使ってデシリアライゼーションを再現します。想定されるリスト要素の型を追跡し、文書化されたレスポンスが UnexpectedJsonEventException なしでデシリアライズされることを確認します。

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

評価

技術スタック
elasticsearch, java
領域
api, backend-api-design
issue の種類
バグ
難易度
3/5
見積もり時間
1〜2日
活発さ
停滞
明瞭さ
明確に書かれている
初心者へのやさしさ
35/100

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

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