Commit 991457c
committed
### What changes were proposed in this pull request?
This PR aims to validate and update the Gradle build dependencies in terms of `okhttp3` library usage.
```
gradle/libs.versions.toml
spark-operator-api/build.gradle
spark-operator/build.gradle
```
### Why are the changes needed?
- As of now, `okhttp3` is a test dependency. So, we need to move `okhttp` to the test dependency section like `junit`.
https://github.com/apache/spark-kubernetes-operator/blob/b0d7d9592ba15b37c067657c929d44f9c2ff5d88/gradle/libs.versions.toml#L21-L27
- Since SPARK-52005, `Apache Spark K8s Operator` is using `Apache Spark 4` dependency which has no direct dependency to `okhttp3` library. So, we don't need the following exclusion.
https://github.com/apache/spark-kubernetes-operator/blob/b0d7d9592ba15b37c067657c929d44f9c2ff5d88/spark-operator/build.gradle#L69
- Since `Fabric8` v7.0.0, `VertxHttpClientFactory` is the default so that we don't need to exclude `okhttp3`. In addition, we migrated to use `VertxHttpClientFactory` via SPARK-53648.
https://github.com/apache/spark-kubernetes-operator/blob/b0d7d9592ba15b37c067657c929d44f9c2ff5d88/spark-operator-api/build.gradle#L20-L23
### Does this PR introduce _any_ user-facing change?
No behavior change.
### How was this patch tested?
Pass the CIs and manual check.
**BEFORE**
```
$ git grep okhttp
gradle/libs.versions.toml:okhttp = "4.12.0"
gradle/libs.versions.toml:okhttp = { group = "com.squareup.okhttp3", name = "okhttp", version.ref = "okhttp" }
gradle/libs.versions.toml:mockwebserver = { group = "com.squareup.okhttp3", name = "mockwebserver", version.ref = "okhttp" }
spark-operator-api/build.gradle: exclude group: 'com.squareup.okhttp3'
spark-operator/build.gradle: exclude group: 'com.squareup.okhttp3'
spark-operator/build.gradle: exclude group: 'com.squareup.okhttp3'
spark-operator/build.gradle: exclude group: 'com.squareup.okhttp3'
```
**AFTER**
```
$ git grep okhttp
gradle/libs.versions.toml:okhttp = "4.12.0"
gradle/libs.versions.toml:mockwebserver = { group = "com.squareup.okhttp3", name = "mockwebserver", version.ref = "okhttp" }
```
### Was this patch authored or co-authored using generative AI tooling?
No.
Closes #329 from dongjoon-hyun/SPARK-53650.
Authored-by: Dongjoon Hyun <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
1 parent 7bad413 commit 991457c
File tree
3 files changed
+2
-10
lines changed- gradle
- spark-operator-api
- spark-operator
3 files changed
+2
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
| |||
27 | 26 | | |
28 | 27 | | |
29 | 28 | | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
48 | 47 | | |
49 | 48 | | |
50 | 49 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | | - | |
23 | | - | |
| 21 | + | |
24 | 22 | | |
25 | 23 | | |
26 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
52 | | - | |
53 | 51 | | |
54 | 52 | | |
55 | 53 | | |
| |||
62 | 60 | | |
63 | 61 | | |
64 | 62 | | |
65 | | - | |
66 | 63 | | |
67 | 64 | | |
68 | | - | |
69 | | - | |
70 | 65 | | |
71 | 66 | | |
72 | 67 | | |
| |||
0 commit comments