You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "Muhammad-Ikhwan-Fathulloh (via GitHub)" <gi...@apache.org> on 2026/06/06 17:57:31 UTC
[PR] [IOTDB-FIX] Fix LimitNode Serialization and Prevent NullPointerException in Relational Engine [iotdb]
Muhammad-Ikhwan-Fathulloh opened a new pull request, #17857:
URL: https://github.com/apache/iotdb/pull/17857
This PR fixes an issue in `LimitNode` where `tiesResolvingScheme` was not fully integrated into the node lifecycle.
Previously, the field was ignored during serialization and deserialization, meaning its state could be lost when query plans were reconstructed. In addition, the deserialization logic passed `null` to an `Optional<OrderingScheme>` field, which could lead to potential `NullPointerException` issues. The field was also not included in `equals()` and `hashCode()`, resulting in incomplete object comparisons.
### Changes included
* Added serialization and deserialization support for `tiesResolvingScheme`.
* Replaced `null` assignments with proper `Optional.empty()` / `Optional.of(...)` handling to improve null safety.
* Updated `equals()` and `hashCode()` to include `tiesResolvingScheme`.
* Removed the outdated TODO comment since the field is now fully utilized.
### Impact
This change helps ensure that:
* Query plan state is preserved correctly during serialization and deserialization.
* Potential `NullPointerException` risks are eliminated.
* `LimitNode` comparisons accurately reflect the complete node state.
* Planner behavior remains consistent and reliable when `tiesResolvingScheme` is present.
### Verification
* Verified that serialization and deserialization follow the same field order.
* Compared the implementation pattern with similar relational planner nodes such as `SortNode`.
* Confirmed that `Optional<OrderingScheme>` is handled safely without using `null`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [IOTDB-FIX] Fix LimitNode Serialization and Prevent NullPointerException in Relational Engine [iotdb]
Posted by "Muhammad-Ikhwan-Fathulloh (via GitHub)" <gi...@apache.org>.
Muhammad-Ikhwan-Fathulloh commented on PR #17857:
URL: https://github.com/apache/iotdb/pull/17857#issuecomment-4645356933
> actually tiesResolvingScheme is never used in current implementation, so we didn't serialize it.
Thank you for the clarification, @JackieTien97. I misunderstood the purpose of tiesResolvingScheme and assumed it was an incomplete implementation that needed to be fully integrated. I apologize for the confusion and the breaking changes caused by this PR. I will revert the serialization and related changes to restore compatibility.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [IOTDB-FIX] Fix LimitNode Serialization and Prevent NullPointerException in Relational Engine [iotdb]
Posted by "JackieTien97 (via GitHub)" <gi...@apache.org>.
JackieTien97 commented on PR #17857:
URL: https://github.com/apache/iotdb/pull/17857#issuecomment-4644956558
actually tiesResolvingScheme is never used in current implementation, so we didn't serialize it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [IOTDB-FIX] Fix LimitNode Serialization and Prevent NullPointerException in Relational Engine [iotdb]
Posted by "Muhammad-Ikhwan-Fathulloh (via GitHub)" <gi...@apache.org>.
Muhammad-Ikhwan-Fathulloh closed pull request #17857: [IOTDB-FIX] Fix LimitNode Serialization and Prevent NullPointerException in Relational Engine
URL: https://github.com/apache/iotdb/pull/17857
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org