Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix/2312 database join meta conversion fix #3656

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

vdwals
Copy link
Contributor

@vdwals vdwals commented Feb 21, 2024

Addresses #2312 in case of using SQLite database join. While the driver returns column type NUMERIC, when fetching data it can either return Long or Double values. This is not supported by Hop. This fix should do the required conversion. Additionally, the expected Type in convertNumberToString is changed from Double to Number.


Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Run mvn clean install apache-rat:check to make sure basic checks pass. A more thorough check will be performed on your pull request automatically.
  • If you have a group of commits related to the same change, please squash your commits into one and force push your branch using git rebase -i.
  • Mention the appropriate issue in your description (for example: addresses #123), if applicable.

To make clear that you license your contribution under the Apache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.

@usbrandon
Copy link
Contributor

When I ran the compile and tests in a github workspace, I saw a failure in the engine compilation test

INFO] Tests run: 18, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.031 s - in org.apache.hop.workflow.WorkflowMetaTest
[INFO] Running org.apache.hop.execution.ExecutionDataTest
[ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.243 s <<< FAILURE! - in org.apache.hop.execution.ExecutionDataTest
[ERROR] org.apache.hop.execution.ExecutionDataTest.testSerialization Time elapsed: 0.238 s <<< ERROR!
com.fasterxml.jackson.databind.JsonMappingException:

Unable to locate value meta plugin of type (id) 5

at [Source: (String)"{
"executionType" : null,
"dataSetMeta" : null,
"finished" : false,
"collectionDate" : 1712687262948,
"parentId" : "parentId",
"ownerId" : "ownerId",
"setMetaData" : {
"firstRows" : {
"setKey" : "firstRows",
"logChannelId" : "12345-logchannel-id",
"name" : "transformName",
"fieldName" : null,
"sampleDescription" : null,
"copyNr" : "0",
"description" : "First rows of transform"
}
},
"rowsBinaryGzipBase64Encoded" : "H4sIAAAAAAAAAG"[truncated 589 chars]; line: 19, column: 35] (through reference chain: org.apache.hop.execution.ExecutionData["rowsBinaryGzipBase64Encoded"])
at org.apache.hop.execution.ExecutionDataTest.testSerialization(ExecutionDataTest.java:130)
Caused by: org.apache.hop.core.exception.HopPluginException:

Unable to locate value meta plugin of type (id) 5

    at org.apache.hop.execution.ExecutionDataTest.testSerialization(ExecutionDataTest.java:130)

[INFO] Running org.apache.hop.www.HopServerPipelineStatusTest
[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.988 s - in org.apache.hop.www.HopServerPipelineStatusTest

When I get time I will try on a different machine, but we need to have the build tests passed.

@vdwals
Copy link
Contributor Author

vdwals commented Apr 12, 2024

I will have a look into it. I did not want to create additional work of course. And I'm going to implement some kind of test for this issue.

@vdwals vdwals force-pushed the bugfix/2312_meta_conversion_fix branch from ba0520c to dba187b Compare May 8, 2024 08:04
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.

None yet

3 participants