Skip to content

IGNITE-16181 SQL Calcite: Implement integer overflow#10802

Open
ivandasch wants to merge 3 commits intoapache:masterfrom
ivandasch:ignite-16181
Open

IGNITE-16181 SQL Calcite: Implement integer overflow#10802
ivandasch wants to merge 3 commits intoapache:masterfrom
ivandasch:ignite-16181

Conversation

@ivandasch
Copy link
Copy Markdown
Contributor

Thank you for submitting the pull request to the Apache Ignite.

In order to streamline the review of the contribution
we ask you to ensure the following steps have been taken:

The Contribution Checklist

  • There is a single JIRA ticket related to the pull request.
  • The web-link to the pull request is attached to the JIRA ticket.
  • The JIRA ticket has the Patch Available state.
  • The pull request body describes changes that have been made.
    The description explains WHAT and WHY was made instead of HOW.
  • The pull request title is treated as the final commit message.
    The following pattern must be used: IGNITE-XXXX Change summary where XXXX - number of JIRA issue.
  • A reviewer has been mentioned through the JIRA comments
    (see the Maintainers list)
  • The pull request has been checked by the Teamcity Bot and
    the green visa attached to the JIRA ticket (see TC.Bot: Check PR)

Notes

If you need any help, please email dev@ignite.apache.org or ask anу advice on http://asf.slack.com #ignite channel.

ilhomu and others added 2 commits June 22, 2023 12:03
Fix cases when data overflow does not raise exception on arithmetic operations and data insert.

/** */
@Test
public void testArithmeticOverflow() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This test class should only check basic operator usage (one test for each operator) and should not be overloaded with other checks. Let's move this test to another class. For example, DataTypesTest.


if (fromPrimitive != null) {
// E.g. from "float" to "double"
// check overflow for 'integer' subtypes
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm afraid this cover only non boxed privitives. In case of boxed primitives we will get something like longVal.intValue() without any checks.

@sonarqubecloud
Copy link
Copy Markdown

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 8 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

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.

3 participants