Skip to content

Conversation

@AngersZhuuuu
Copy link
Contributor

@AngersZhuuuu AngersZhuuuu commented Nov 23, 2021

What changes were proposed in this pull request?

Since Hive 2.3.9 start have function getWithoutRegisterFns, but user may use hive 2.3.8 or lower version.
Here we should use reflection to let user build with hive 2.3.8 or lower version

Why are the changes needed?

Support build with hive version lower than 2.3.9 since many user will build spark with it 's own hive code and their own jar (they may do some optimize or. other thing in their own code). This pr make it easier to integrate and won't hurt current logic.

Does this PR introduce any user-facing change?

User can build spark with hive version lower than 2.3.9

How was this patch tested?

build with command

./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8

Jars under dist
image

@github-actions github-actions bot added the SQL label Nov 23, 2021
@AngersZhuuuu
Copy link
Contributor Author

ping @sunchao @dongjoon-hyun @HyukjinKwon

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Test build #145542 has finished for PR 34690 at commit 04cddea.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50014/

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50014/

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50016/

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Test build #145543 has finished for PR 34690 at commit bdedc32.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Nov 23, 2021

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/50016/

@HyukjinKwon HyukjinKwon changed the title [SPARK-37446][SQL] When create Hie client, we should use reflection when call getWithoutRegisterFns [SPARK-37446][SQL] When create Hive client, we should use reflection when call getWithoutRegisterFns Nov 24, 2021
@HyukjinKwon HyukjinKwon changed the title [SPARK-37446][SQL] When create Hive client, we should use reflection when call getWithoutRegisterFns [SPARK-37446][SQL] Use reflection for getWithoutRegisterFns to allow different Hive versions for building Nov 24, 2021
Copy link
Member

@HyukjinKwon HyukjinKwon left a comment

Choose a reason for hiding this comment

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

@AngersZhuuuu, how did you test this? Can you share the command for build, and show that the build succeeded?

@AngersZhuuuu
Copy link
Contributor Author

@AngersZhuuuu, how did you test this? Can you share the command for build, and show that the build succeeded?

With command

./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8

Jars under dist
image

I make this change since many user will build spark with it's own hive code and their own jar (they may do some optimize or. other thing in their own code).

This pr make it easier to integrate and won't hurt current logic.

@HyukjinKwon
Copy link
Member

Let's fill up "How was this patch tested?" in the PR description.

@AngersZhuuuu
Copy link
Contributor Author

Let's fill up "How was this patch tested?" in the PR description.

Updated desc

Copy link
Member

@sunchao sunchao left a comment

Choose a reason for hiding this comment

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

LGTM, thanks @AngersZhuuuu !

@HyukjinKwon
Copy link
Member

HyukjinKwon commented Nov 25, 2021

Merged to master and branch-3.2.

HyukjinKwon pushed a commit that referenced this pull request Nov 25, 2021
…different Hive versions for building

### What changes were proposed in this pull request?
Since Hive 2.3.9  start have function `getWithoutRegisterFns`, but user may use hive 2.3.8 or lower version.
Here we should use reflection to let user build with hive 2.3.8 or lower version

### Why are the changes needed?
Support build with hive version lower than 2.3.9 since many user will build spark with it 's own hive code and their own jar (they may do some optimize or. other thing in their own code). This pr make it easier to integrate and won't hurt current logic.

### Does this PR introduce _any_ user-facing change?
User can build spark with hive version lower than 2.3.9

### How was this patch tested?

build with command
```
./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8
```

Jars under dist
![image](https://user-images.githubusercontent.com/46485123/143162194-d505b151-f23d-4268-af19-6dfeccea4a74.png)

Closes #34690 from AngersZhuuuu/SPARK-37446.

Authored-by: Angerszhuuuu <[email protected]>
Signed-off-by: Hyukjin Kwon <[email protected]>
(cherry picked from commit 04671bd)
Signed-off-by: Hyukjin Kwon <[email protected]>
sunchao pushed a commit to sunchao/spark that referenced this pull request Dec 8, 2021
…different Hive versions for building

### What changes were proposed in this pull request?
Since Hive 2.3.9  start have function `getWithoutRegisterFns`, but user may use hive 2.3.8 or lower version.
Here we should use reflection to let user build with hive 2.3.8 or lower version

### Why are the changes needed?
Support build with hive version lower than 2.3.9 since many user will build spark with it 's own hive code and their own jar (they may do some optimize or. other thing in their own code). This pr make it easier to integrate and won't hurt current logic.

### Does this PR introduce _any_ user-facing change?
User can build spark with hive version lower than 2.3.9

### How was this patch tested?

build with command
```
./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8
```

Jars under dist
![image](https://user-images.githubusercontent.com/46485123/143162194-d505b151-f23d-4268-af19-6dfeccea4a74.png)

Closes apache#34690 from AngersZhuuuu/SPARK-37446.

Authored-by: Angerszhuuuu <[email protected]>
Signed-off-by: Hyukjin Kwon <[email protected]>
(cherry picked from commit 04671bd)
Signed-off-by: Hyukjin Kwon <[email protected]>
catalinii pushed a commit to lyft/spark that referenced this pull request Feb 22, 2022
…different Hive versions for building

### What changes were proposed in this pull request?
Since Hive 2.3.9  start have function `getWithoutRegisterFns`, but user may use hive 2.3.8 or lower version.
Here we should use reflection to let user build with hive 2.3.8 or lower version

### Why are the changes needed?
Support build with hive version lower than 2.3.9 since many user will build spark with it 's own hive code and their own jar (they may do some optimize or. other thing in their own code). This pr make it easier to integrate and won't hurt current logic.

### Does this PR introduce _any_ user-facing change?
User can build spark with hive version lower than 2.3.9

### How was this patch tested?

build with command
```
./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8
```

Jars under dist
![image](https://user-images.githubusercontent.com/46485123/143162194-d505b151-f23d-4268-af19-6dfeccea4a74.png)

Closes apache#34690 from AngersZhuuuu/SPARK-37446.

Authored-by: Angerszhuuuu <[email protected]>
Signed-off-by: Hyukjin Kwon <[email protected]>
(cherry picked from commit 04671bd)
Signed-off-by: Hyukjin Kwon <[email protected]>
catalinii pushed a commit to lyft/spark that referenced this pull request Mar 4, 2022
…different Hive versions for building

### What changes were proposed in this pull request?
Since Hive 2.3.9  start have function `getWithoutRegisterFns`, but user may use hive 2.3.8 or lower version.
Here we should use reflection to let user build with hive 2.3.8 or lower version

### Why are the changes needed?
Support build with hive version lower than 2.3.9 since many user will build spark with it 's own hive code and their own jar (they may do some optimize or. other thing in their own code). This pr make it easier to integrate and won't hurt current logic.

### Does this PR introduce _any_ user-facing change?
User can build spark with hive version lower than 2.3.9

### How was this patch tested?

build with command
```
./dev/make-distribution.sh --tgz -Pyarn -Phive -Phive-thriftserver -Dhive.version=2.3.8
```

Jars under dist
![image](https://user-images.githubusercontent.com/46485123/143162194-d505b151-f23d-4268-af19-6dfeccea4a74.png)

Closes apache#34690 from AngersZhuuuu/SPARK-37446.

Authored-by: Angerszhuuuu <[email protected]>
Signed-off-by: Hyukjin Kwon <[email protected]>
(cherry picked from commit 04671bd)
Signed-off-by: Hyukjin Kwon <[email protected]>
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.

4 participants