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

[CARBONDATA-1596] Fixed IntermediateFileMerger for decimal types #1420

Closed
wants to merge 1 commit into from

Conversation

kunal642
Copy link
Contributor

Analysis: casting bigdecimal to byte[] was throwing ClassCastException in IntermediateFileMerger.

Solution: Use DataType#bigDecimalToByte to convert bigdecimal to byte[].

@kunal642 kunal642 changed the title Fixed IntermediateFileMerger for decimal types [CARBONDATA-1596] Fixed IntermediateFileMerger for decimal types Oct 19, 2017
@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/483/

@CarbonDataQA
Copy link

Build Success with Spark 1.6, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/358/

@jackylk
Copy link
Contributor

jackylk commented Oct 19, 2017

Can you add a testcase to verify?

@ravipesala
Copy link
Contributor

SDV Build Success , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1111/

@kunal642
Copy link
Contributor Author

@jackylk test case added..Please review

sortParameters.setPrefetch(false);
sortParameters.setSortFileCompressionEnabled(false);
sortParameters.setFileWriteBufferSize(2);
sortParameters.setMeasureDataType(new DataType[] { DataTypes.DECIMAL });
Copy link
Contributor

Choose a reason for hiding this comment

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

I mean to add a testcase to reproduce the error.
Is it a error when compaction a table having decimal type?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes. While merging the sort temp files the following code was throwing the error.
(byte[]) NonDictionaryUtil.getMeasure(fieldIndex, row);
The fix is to use the DataTypeUtil.bigDecimalToByte to convert bigDecimal value to byte[].

Copy link
Contributor

Choose a reason for hiding this comment

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

So can you add a testcase to do compaction on table having decimal type instead of using mock.

@CarbonDataQA
Copy link

Build Failed with Spark 1.6, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/362/

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/487/

@ravipesala
Copy link
Contributor

SDV Build Success , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1115/

@kunal642
Copy link
Contributor Author

@jackylk added integration test instead of unit test.

@CarbonDataQA
Copy link

Build Failed with Spark 1.6, Please check CI http://88.99.58.216:8080/job/ApacheCarbonPRBuilder/367/

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/492/

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1119/

@jackylk
Copy link
Contributor

jackylk commented Oct 20, 2017

retest this please

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/509/

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1137/

@kunal642
Copy link
Contributor Author

retest this please

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/523/

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1153/

@jackylk
Copy link
Contributor

jackylk commented Oct 20, 2017

It seems some SDV tests are failed

@kunal642
Copy link
Contributor Author

retest this please

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1157/

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/527/

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1172/

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/541/

@ravipesala
Copy link
Contributor

retest this please

@CarbonDataQA
Copy link

Build Failed with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/740/

@ravipesala
Copy link
Contributor

SDV Build Success , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1377/

@ravipesala
Copy link
Contributor

@kunal642 please check the test failure

@kunal642
Copy link
Contributor Author

@ravipesala This test is passing on my local

@CarbonDataQA
Copy link

Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder1/794/

@ravipesala
Copy link
Contributor

SDV Build Fail , Please check CI http://144.76.159.231:8080/job/ApacheSDVTests/1427/

@kunal642
Copy link
Contributor Author

kunal642 commented Nov 2, 2017

@ravipesala @jackylk Please review.. The build is randomly failing.

@jackylk
Copy link
Contributor

jackylk commented Nov 8, 2017

LGTM

@asfgit asfgit closed this in fd28b15 Nov 8, 2017
jatin9896 pushed a commit to jatin9896/incubator-carbondata that referenced this pull request Jan 5, 2018
Analysis: casting bigdecimal to byte[] was throwing ClassCastException in IntermediateFileMerger.

Solution: Use DataType#bigDecimalToByte to convert bigdecimal to byte[].

This closes apache#1420
anubhav100 pushed a commit to anubhav100/incubator-carbondata that referenced this pull request Jun 22, 2018
Analysis: casting bigdecimal to byte[] was throwing ClassCastException in IntermediateFileMerger.

Solution: Use DataType#bigDecimalToByte to convert bigdecimal to byte[].

This closes apache#1420
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

4 participants