Skip to content

NIFI-11655: Fixed float and double handling in GenerateRecord#7356

Closed
mattyb149 wants to merge 1 commit intoapache:mainfrom
mattyb149:NIFI-11655
Closed

NIFI-11655: Fixed float and double handling in GenerateRecord#7356
mattyb149 wants to merge 1 commit intoapache:mainfrom
mattyb149:NIFI-11655

Conversation

@mattyb149
Copy link
Contributor

Summary

NIFI-11655 This PR fixes how floats and doubles are generated when using the Schema Text property in GenerateRecord. The bug was that all types were coerced to DecimalDataType which is not compatible for float and double types. The PR handles each of the types separately, and test data was added to exercise this fix.

Tracking

Please complete the following tracking steps prior to pull request creation.

Issue Tracking

Pull Request Tracking

  • Pull Request title starts with Apache NiFi Jira issue number, such as NIFI-11655
  • Pull Request commit message starts with Apache NiFi Jira issue number, as such NIFI-11655

Pull Request Formatting

  • Pull Request based on current revision of the main branch
  • Pull Request refers to a feature branch with one commit containing changes

Verification

Please indicate the verification steps performed prior to pull request creation.

Build

  • Build completed using mvn clean install -P contrib-check
    • JDK 11
    • JDK 17

Licensing

  • New dependencies are compatible with the Apache License 2.0 according to the License Policy
  • New dependencies are documented in applicable LICENSE and NOTICE files

Documentation

  • Documentation formatting appears as expected in rendered files

Copy link
Contributor

@exceptionfactory exceptionfactory left a comment

Choose a reason for hiding this comment

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

Thanks for the correction @mattyb149! +1 merging

exceptionfactory pushed a commit that referenced this pull request Jun 8, 2023
This closes #7356

Signed-off-by: David Handermann <exceptionfactory@apache.org>
(cherry picked from commit 5e6f3ab)
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.

2 participants