Skip to content

Commit 1e77bdf

Browse files
authored
SOLR-17609: Remove HDFS module (#2923)
Removed the module, and updated the various supporting config files across Solr code base like security policies, logj4 configurations, build tooling and test tooling. Removed HDFS specific content from Ref Guide. Existing "blockcache" Java code has been migrated into solr/core under org.apache.solr.blackcache package structure.
1 parent 698e405 commit 1e77bdf

File tree

159 files changed

+47
-16859
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

159 files changed

+47
-16859
lines changed

.github/labeler.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -125,11 +125,6 @@ module:gcs-repository:
125125
- any-glob-to-any-file:
126126
- solr/modules/gcs-repository/**
127127

128-
module:hdfs:
129-
- changed-files:
130-
- any-glob-to-any-file:
131-
- solr/modules/hdfs/**
132-
133128
module:jwt-auth:
134129
- changed-files:
135130
- any-glob-to-any-file:
@@ -197,9 +192,7 @@ cat:index:
197192
- changed-files:
198193
- any-glob-to-any-file:
199194
- '**/org/apache/solr/index/**'
200-
- '**/org/apache/solr/hdfs/index/**'
201195
- '**/org/apache/solr/update/**'
202-
- '**/org/apache/solr/hdfs/update/**'
203196
- '**/org/apache/solr/scripting/update/**'
204197
- '**/org/apache/solr/handler/loader/**'
205198

gradle/libs.versions.toml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@ apache-commons-math3 = "3.6.1"
3232
# @keep for version alignment
3333
apache-commons-text = "1.12.0"
3434
apache-curator = "5.7.1"
35-
apache-hadoop = "3.4.0"
36-
apache-hadoop-thirdparty = "1.2.0"
3735
apache-httpcomponents-httpclient = "4.5.14"
3836
apache-httpcomponents-httpcore = "4.4.16"
3937
apache-httpcomponents-httpmime = "4.5.14"
@@ -243,11 +241,6 @@ apache-curator-client = { module = "org.apache.curator:curator-client", version.
243241
apache-curator-framework = { module = "org.apache.curator:curator-framework", version.ref = "apache-curator" }
244242
apache-curator-recipes = { module = "org.apache.curator:curator-recipes", version.ref = "apache-curator" }
245243
apache-curator-test = { module = "org.apache.curator:curator-test", version.ref = "apache-curator" }
246-
apache-hadoop-client-api = { module = "org.apache.hadoop:hadoop-client-api", version.ref = "apache-hadoop" }
247-
apache-hadoop-client-minicluster = { module = "org.apache.hadoop:hadoop-client-minicluster", version.ref = "apache-hadoop" }
248-
apache-hadoop-client-runtime = { module = "org.apache.hadoop:hadoop-client-runtime", version.ref = "apache-hadoop" }
249-
apache-hadoop-hdfs = { module = "org.apache.hadoop:hadoop-hdfs", version.ref = "apache-hadoop" }
250-
apache-hadoop-thirdparty-shadedguava = { module = "org.apache.hadoop.thirdparty:hadoop-shaded-guava", version.ref = "apache-hadoop-thirdparty" }
251244
apache-httpcomponents-httpclient = { module = "org.apache.httpcomponents:httpclient", version.ref = "apache-httpcomponents-httpclient" }
252245
apache-httpcomponents-httpcore = { module = "org.apache.httpcomponents:httpcore", version.ref = "apache-httpcomponents-httpcore" }
253246
apache-httpcomponents-httpmime = { module = "org.apache.httpcomponents:httpmime", version.ref = "apache-httpcomponents-httpmime" }

gradle/solr/solr-forbidden-apis.gradle

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,5 @@
2121
configure(project(":solr:core")) {
2222
tasks.matching { it.name == "forbiddenApisMain" || it.name == "forbiddenApisTest" }.all {
2323
exclude "org/apache/solr/internal/**"
24-
exclude "org/apache/hadoop/**"
2524
}
26-
}
25+
}

gradle/testing/randomization/policies/solr-tests.policy

Lines changed: 4 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -103,16 +103,8 @@ grant {
103103
permission java.lang.RuntimePermission "closeClassLoader";
104104
// needed by HttpSolrClient
105105
permission java.lang.RuntimePermission "getFileSystemAttributes";
106-
// needed by hadoop hdfs (TODO: there is a cleaner way to handle this)
107-
permission java.lang.RuntimePermission "loadLibrary.jaas";
108-
permission java.lang.RuntimePermission "loadLibrary.jaas_unix";
109-
permission java.lang.RuntimePermission "loadLibrary.jaas_nt";
110-
// needed by hadoop common RawLocalFileSystem for java nio getOwner
111-
permission java.lang.RuntimePermission "accessUserInformation";
112-
// needed by hadoop hdfs
113-
permission java.lang.RuntimePermission "readFileDescriptor";
114-
permission java.lang.RuntimePermission "writeFileDescriptor";
115-
// needed by hadoop http
106+
107+
// needed by mockito http
116108
permission java.lang.RuntimePermission "getProtectionDomain";
117109
// SolrProcessMgr to list processes
118110
permission java.lang.RuntimePermission "manageProcess";
@@ -139,20 +131,11 @@ grant {
139131
permission javax.management.MBeanServerPermission "releaseMBeanServer";
140132
permission javax.management.MBeanTrustPermission "register";
141133

142-
// needed by hadoop hdfs
143-
permission javax.security.auth.AuthPermission "getSubject";
144-
permission javax.security.auth.AuthPermission "modifyPrincipals";
145-
permission javax.security.auth.AuthPermission "doAs";
146-
permission javax.security.auth.AuthPermission "modifyPrivateCredentials";
147-
permission javax.security.auth.AuthPermission "modifyPublicCredentials";
148-
permission javax.security.auth.PrivateCredentialPermission "org.apache.hadoop.security.Credentials * \"*\"", "read";
149-
150134
// needed by crossdc
151135
permission javax.security.auth.AuthPermission "getLoginConfiguration";
152136
permission javax.security.auth.AuthPermission "setLoginConfiguration";
153137

154-
// needed by hadoop security
155-
permission java.security.SecurityPermission "putProviderProperty.SaslPlainServer";
138+
// needed by benchmark
156139
permission java.security.SecurityPermission "insertProvider";
157140

158141
// Needed by JWT integration tests & S3 tests
@@ -219,10 +202,7 @@ grant {
219202

220203
// additional permissions based on system properties set by /bin/solr
221204
// NOTE: if the property is not set, the permission entry is ignored.
222-
grant {
223-
permission java.io.FilePermission "${hadoop.security.credential.provider.path}", "read,write,delete,readlink";
224-
permission java.io.FilePermission "${hadoop.security.credential.provider.path}${/}-", "read,write,delete,readlink";
225-
205+
grant {
226206
permission java.io.FilePermission "${solr.jetty.keystore}", "read,write,delete,readlink";
227207
permission java.io.FilePermission "${solr.jetty.keystore}${/}-", "read,write,delete,readlink";
228208

gradle/validation/forbidden-apis.gradle

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -130,11 +130,6 @@ allprojects { prj ->
130130
forbiddenApisMain.exclude("**/jmh_generated/**")
131131
}
132132

133-
// Disable checks on code copied from Hadoop
134-
if (prj.path == ":solr:modules:hdfs") {
135-
forbiddenApisTest.exclude("**/org/apache/hadoop/**")
136-
}
137-
138133
// We rely on resolved configurations to compute the relevant set of rule
139134
// files for forbiddenApis. Since we don't want to resolve these configurations until
140135
// the task is executed, we can't really use them as task inputs properly. This is a

gradle/validation/owasp-dependency-check/exclusions.xml

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -76,14 +76,4 @@
7676
<cpe>cpe:/a:eclipse:jetty</cpe>
7777
<cpe>cpe:/a:jetty:jetty</cpe>
7878
</suppress>
79-
<suppress>
80-
<notes><![CDATA[hadoop-shaded-guava-1.1.1.jar is not Apache Hadoop 1.1.1]]></notes>
81-
<packageUrl regex="true">^pkg:maven/org\.apache\.hadoop\.thirdparty/hadoop\-shaded\-guava@.*$</packageUrl>
82-
<cpe>cpe:/a:apache:hadoop:1.1.1</cpe>
83-
</suppress>
84-
<suppress>
85-
<notes><![CDATA[hadoop-client-runtime-3.*.jar is not Apache Hadoop 1.1.1]]></notes>
86-
<packageUrl regex="true">^pkg:maven/org\.apache\.hadoop/hadoop\-client\-runtime@3.*$</packageUrl>
87-
<cpe>cpe:/a:apache:hadoop:1.1.1</cpe>
88-
</suppress>
8979
</suppressions>

gradle/validation/rat-sources.gradle

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -106,12 +106,6 @@ allprojects {
106106
exclude "src/test-files/META-INF/services/*"
107107
break
108108

109-
case ":solr:modules:hdfs":
110-
exclude "src/test-files/**/*.aff"
111-
exclude "src/test-files/**/*.dic"
112-
exclude "src/test-files/**/*.incl"
113-
break
114-
115109
case ":solr:modules:langid":
116110
exclude "**/langdetect-profiles/*"
117111
break

gradle/validation/spotless.gradle

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,6 @@ configure(allprojects) { prj ->
6565
"src/java/org/apache/solr/parser/Token.java",
6666
"src/java/org/apache/solr/parser/TokenMgrError.java"
6767
break
68-
case ":solr:modules:hdfs":
69-
// Exclude Hadoop copied files to make upgrades easier
70-
targetExclude "src/**/org/apache/hadoop/**"
71-
break
7268
case ":solr:solr-ref-guide":
7369
// Apply to all example Java sources in the ref-guide
7470
target "modules/**/examples/*.java"

settings.gradle

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ include "solr:modules:cross-dc"
4949
include "solr:modules:opentelemetry"
5050
include "solr:modules:extraction"
5151
include "solr:modules:gcs-repository"
52-
include "solr:modules:hdfs"
5352
include "solr:modules:jwt-auth"
5453
include "solr:modules:langid"
5554
include "solr:modules:llm"

solr/CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,8 @@ Deprecation Removals
105105

106106
* SOLR-17540: Removed the Hadoop Auth module, and thus Kerberos authentication and other exotic options. (Eric Pugh)
107107

108+
* SOLR-17609: Removd the HDFS module and therefore support for storing indexes in HDFS. Existing "blockcache" code preserved by migrating it to core o.a.s.blackcache package.
109+
108110
Dependency Upgrades
109111
---------------------
110112
(No changes)

0 commit comments

Comments
 (0)