Skip to content

Spark: Extend commit unknown exception handling to SparkPositionDeltaWrite#4800

Merged
rdblue merged 5 commits intoapache:masterfrom
singhpk234:fix/mor-commit-unkown-exp
May 29, 2022
Merged

Spark: Extend commit unknown exception handling to SparkPositionDeltaWrite#4800
rdblue merged 5 commits intoapache:masterfrom
singhpk234:fix/mor-commit-unkown-exp

Conversation

@singhpk234
Copy link
Contributor

@singhpk234 singhpk234 commented May 18, 2022

About the change

Extend the handling for #4687 for SparkPositionDeltaWriter used in MOR.

Testing Done

Added an E2E UT as done in earlier PR.


cc @RussellSpitzer @aokolnychyi @flyrain

@github-actions github-actions bot added the spark label May 18, 2022
@singhpk234 singhpk234 changed the title Spark: Extend commit unknown exception handling to SparkPositionDeltaWriter Spark: Extend commit unknown exception handling to SparkPositionDeltaWrite May 18, 2022
@RussellSpitzer
Copy link
Member

@singhpk234 you probably saw how I wrote the test in the other suite, it is not pretty but I think you maybe be able to pull something off like that as well. Although this probably won't be easy unless it is coupled with a Spark version that natively supports the merge operations (3.3 I believe @aokolnychyi has it merged in) since at the moment we would need custom plan rules as well I think ...

I'm getting close to thinking we need byteman or some other bytecode fault injector :(.

@singhpk234
Copy link
Contributor Author

since at the moment we would need custom plan rules as well I think

+1, I was also thinking in these lines, we need here analyzer rules so that we could get a DSV2Relation which hold our mocked table object (which would throw our CommitUnknowEx when commit is called). The main problem as you highlighted is the same, it supported in SQL via our Extensions :(.

@singhpk234 singhpk234 marked this pull request as ready for review May 19, 2022 19:28
@singhpk234
Copy link
Contributor Author

@RussellSpitzer , I went one step above and used catalog to manipulate and return the spy table I want. Used static prop to manipulate to get the spy spark table instead :) !!!

@RussellSpitzer
Copy link
Member

@singhpk234 Thats a great solution! Maybe i'l rework my PR later to do the same thing!

@rdblue
Copy link
Contributor

rdblue commented May 29, 2022

Thanks, @singhpk234!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants