SOLR-14026: Upgrade Jetty to 9.4.24.v20191120 and dropwizard to 4.1.2

This commit is contained in:
erick 2019-12-13 10:01:37 -05:00
parent e5df183a42
commit 8278886966
75 changed files with 56 additions and 48 deletions

View File

@ -62,7 +62,7 @@ com.sun.jersey.version = 1.19
/commons-logging/commons-logging = 1.1.3 /commons-logging/commons-logging = 1.1.3
/de.l3s.boilerpipe/boilerpipe = 1.1.0 /de.l3s.boilerpipe/boilerpipe = 1.1.0
io.dropwizard.metrics.version = 4.0.5 io.dropwizard.metrics.version = 4.1.2
/io.dropwizard.metrics/metrics-core = ${io.dropwizard.metrics.version} /io.dropwizard.metrics/metrics-core = ${io.dropwizard.metrics.version}
/io.dropwizard.metrics/metrics-graphite = ${io.dropwizard.metrics.version} /io.dropwizard.metrics/metrics-graphite = ${io.dropwizard.metrics.version}
/io.dropwizard.metrics/metrics-jetty9 = ${io.dropwizard.metrics.version} /io.dropwizard.metrics/metrics-jetty9 = ${io.dropwizard.metrics.version}
@ -260,7 +260,7 @@ org.codehaus.janino.version = 3.0.9
/org.codehaus.woodstox/stax2-api = 3.1.4 /org.codehaus.woodstox/stax2-api = 3.1.4
/org.codehaus.woodstox/woodstox-core-asl = 4.4.1 /org.codehaus.woodstox/woodstox-core-asl = 4.4.1
org.eclipse.jetty.version = 9.4.19.v20190610 org.eclipse.jetty.version = 9.4.24.v20191120
/org.eclipse.jetty.http2/http2-client = ${org.eclipse.jetty.version} /org.eclipse.jetty.http2/http2-client = ${org.eclipse.jetty.version}
/org.eclipse.jetty.http2/http2-common = ${org.eclipse.jetty.version} /org.eclipse.jetty.http2/http2-common = ${org.eclipse.jetty.version}
/org.eclipse.jetty.http2/http2-hpack = ${org.eclipse.jetty.version} /org.eclipse.jetty.http2/http2-hpack = ${org.eclipse.jetty.version}

View File

@ -1 +0,0 @@
4acddfa41f45790e43fe4be257c3c4bcf6b846ff

View File

@ -0,0 +1 @@
69125cf74b07f1b9d60b5c94da47cb04c098f654

View File

@ -1 +0,0 @@
b59ff8ecb0cf5d6234958f2404eabf0b72464e14

View File

@ -0,0 +1 @@
d3f0b0fb016ef8d35ffb199d928ffbcbfa121c86

View File

@ -1 +0,0 @@
7eb9a6be62d84e1691e5fdc99223e632485619a8

View File

@ -0,0 +1 @@
dcb6d4d505ef74898e3a64a38c40195c01e97119

View File

@ -1 +0,0 @@
55786f6e6649bd49425a7da1ac72cd85b8dd4bef

View File

@ -0,0 +1 @@
7885cc3d5d7701a444acada7ab97f89846514875

View File

@ -1 +0,0 @@
89e25610b3199fdf34a831c1b306f7e765928959

View File

@ -0,0 +1 @@
ca1803fde51b795c0a8346ca8bc6277d9d04d01d

View File

@ -1 +0,0 @@
2fd3cd40279280e8c56241f753d2c52d8d446d19

View File

@ -0,0 +1 @@
3095acb088f4ff9e3fd9aedf98db73e3c18ea849

View File

@ -101,7 +101,7 @@ Apache Tika 1.19.1
Carrot2 3.16.0 Carrot2 3.16.0
Velocity 2.0 and Velocity Tools 3.0 Velocity 2.0 and Velocity Tools 3.0
Apache ZooKeeper 3.5.5 Apache ZooKeeper 3.5.5
Jetty 9.4.19.v20190610 Jetty 9.4.24.v20191120
Upgrade Notes Upgrade Notes
--------------------- ---------------------
@ -179,6 +179,8 @@ Upgrade Notes
* SOLR-14065: VelocityResponseWriter has been deprecated and may be removed in a future version. * SOLR-14065: VelocityResponseWriter has been deprecated and may be removed in a future version.
* SOLR-14026: Upgrade Jetty to 9.4.24.v20191120 and dropwizard to 4.1.2 (Erick Erickson)
New Features New Features
--------------------- ---------------------
* SOLR-13821: A Package store to store and load package artifacts (noble, Ishan Chattopadhyaya) * SOLR-13821: A Package store to store and load package artifacts (noble, Ishan Chattopadhyaya)
@ -351,7 +353,7 @@ Apache Tika 1.19.1
Carrot2 3.16.0 Carrot2 3.16.0
Velocity 2.0 and Velocity Tools 3.0 Velocity 2.0 and Velocity Tools 3.0
Apache ZooKeeper 3.5.5 Apache ZooKeeper 3.5.5
Jetty 9.4.19.v20190610 Jetty 9.4.24.v20191120
Upgrade Notes Upgrade Notes
---------------------- ----------------------

View File

@ -67,7 +67,7 @@ public class SolrSlf4jReporter extends FilteringSolrMetricReporter {
final Map<String, String> mdcContext; final Map<String, String> mdcContext;
Slf4jReporterWrapper(String logger, Map<String, String> mdcContext, Slf4jReporter delegate, TimeUnit rateUnit, TimeUnit durationUnit) { Slf4jReporterWrapper(String logger, Map<String, String> mdcContext, Slf4jReporter delegate, TimeUnit rateUnit, TimeUnit durationUnit) {
super(null, logger, null, rateUnit, durationUnit); super(metricManager.registry(registryName), logger, null, rateUnit, durationUnit);
this.delegate = delegate; this.delegate = delegate;
this.mdcContext = mdcContext; this.mdcContext = mdcContext;
} }

View File

@ -37,6 +37,7 @@ import com.codahale.metrics.Gauge;
import com.codahale.metrics.Histogram; import com.codahale.metrics.Histogram;
import com.codahale.metrics.Meter; import com.codahale.metrics.Meter;
import com.codahale.metrics.MetricFilter; import com.codahale.metrics.MetricFilter;
import com.codahale.metrics.MetricRegistry;
import com.codahale.metrics.ScheduledReporter; import com.codahale.metrics.ScheduledReporter;
import com.codahale.metrics.Timer; import com.codahale.metrics.Timer;
import org.apache.http.client.HttpClient; import org.apache.http.client.HttpClient;
@ -301,12 +302,17 @@ public class SolrReporter extends ScheduledReporter {
} }
} }
// Recent dropwizard (found with version 4.1.2) requires that you _must_ call the superclass with a non-null registry.
// We delegate to registries anyway, so having a dummy registry is harmless.
private static final MetricRegistry dummyRegistry = new MetricRegistry();
public SolrReporter(HttpClient httpClient, Supplier<String> urlProvider, SolrMetricManager metricManager, public SolrReporter(HttpClient httpClient, Supplier<String> urlProvider, SolrMetricManager metricManager,
List<Report> metrics, String handler, List<Report> metrics, String handler,
String reporterId, TimeUnit rateUnit, TimeUnit durationUnit, String reporterId, TimeUnit rateUnit, TimeUnit durationUnit,
SolrParams params, boolean skipHistograms, boolean skipAggregateValues, SolrParams params, boolean skipHistograms, boolean skipAggregateValues,
boolean cloudClient, boolean compact) { boolean cloudClient, boolean compact) {
super(null, "solr-reporter", MetricFilter.ALL, rateUnit, durationUnit, null, true); super(dummyRegistry, "solr-reporter", MetricFilter.ALL, rateUnit, durationUnit, null, true);
this.metricManager = metricManager; this.metricManager = metricManager;
this.urlProvider = urlProvider; this.urlProvider = urlProvider;
this.reporterId = reporterId; this.reporterId = reporterId;

View File

@ -32,6 +32,7 @@ import org.apache.lucene.util.Constants;
import org.apache.solr.SolrTestCaseJ4; import org.apache.solr.SolrTestCaseJ4;
import org.apache.solr.client.solrj.SolrQuery; import org.apache.solr.client.solrj.SolrQuery;
import org.apache.solr.client.solrj.embedded.JettySolrRunner; import org.apache.solr.client.solrj.embedded.JettySolrRunner;
import org.apache.solr.client.solrj.impl.BaseHttpSolrClient;
import org.apache.solr.client.solrj.impl.HttpSolrClient; import org.apache.solr.client.solrj.impl.HttpSolrClient;
import org.apache.solr.client.solrj.request.CoreAdminRequest; import org.apache.solr.client.solrj.request.CoreAdminRequest;
import org.apache.solr.client.solrj.request.CoreStatus; import org.apache.solr.client.solrj.request.CoreStatus;
@ -190,12 +191,12 @@ public class CoreAdminHandlerTest extends SolrTestCaseJ4 {
CoreAdminParams.CoreAdminAction.STATUS.toString(), CoreAdminParams.CoreAdminAction.STATUS.toString(),
CoreAdminParams.CORE, "bogus_dir_core"), CoreAdminParams.CORE, "bogus_dir_core"),
resp); resp);
Map<String,Exception> failures = @SuppressWarnings("unchecked")
Map<String,Exception> failures =
(Map<String,Exception>) resp.getValues().get("initFailures"); (Map<String,Exception>) resp.getValues().get("initFailures");
assertNotNull("core failures is null", failures); assertNotNull("core failures is null", failures);
NamedList<Object> status = NamedList status = (NamedList)resp.getValues().get("status");
(NamedList<Object>)resp.getValues().get("status");
assertNotNull("core status is null", status); assertNotNull("core status is null", status);
assertEquals("wrong number of core failures", 1, failures.size()); assertEquals("wrong number of core failures", 1, failures.size());
@ -338,7 +339,7 @@ public class CoreAdminHandlerTest extends SolrTestCaseJ4 {
req.process(client); req.process(client);
} }
HttpSolrClient.RemoteSolrException rse = expectThrows(HttpSolrClient.RemoteSolrException.class, () -> { BaseHttpSolrClient.RemoteSolrException rse = expectThrows(BaseHttpSolrClient.RemoteSolrException.class, () -> {
try (HttpSolrClient client = getHttpSolrClient(runner.getBaseUrl() + "/corex", DEFAULT_CONNECTION_TIMEOUT, try (HttpSolrClient client = getHttpSolrClient(runner.getBaseUrl() + "/corex", DEFAULT_CONNECTION_TIMEOUT,
DEFAULT_CONNECTION_TIMEOUT * 1000)) { DEFAULT_CONNECTION_TIMEOUT * 1000)) {
client.query(new SolrQuery("id:*")); client.query(new SolrQuery("id:*"));
@ -346,7 +347,7 @@ public class CoreAdminHandlerTest extends SolrTestCaseJ4 {
runner.stop(); runner.stop();
} }
}); });
assertTrue(rse.getMessage(), rse.getMessage().contains("Problem accessing /solr/corex/select")); assertEquals("Should have received a 404 error", 404, rse.code());
} }
@Test @Test

View File

@ -135,8 +135,7 @@ public class JWTAuthPluginIntegrationTest extends SolrCloudAuthTestCase {
@Test @Test
public void infoRequestValidateXSolrAuthHeaders() throws IOException { public void infoRequestValidateXSolrAuthHeaders() throws IOException {
Map<String, String> headers = getHeaders(baseUrl + "/admin/info/system", null); Map<String, String> headers = getHeaders(baseUrl + "/admin/info/system", null);
assertEquals("401", headers.get("code")); assertEquals("Should have received 401 code", "401", headers.get("code"));
assertEquals("HTTP/1.1 401 Require authentication", headers.get(null));
assertEquals("Bearer realm=\"my-solr-jwt\"", headers.get("WWW-Authenticate")); assertEquals("Bearer realm=\"my-solr-jwt\"", headers.get("WWW-Authenticate"));
String authData = new String(Base64.base64ToByteArray(headers.get("X-Solr-AuthData")), UTF_8); String authData = new String(Base64.base64ToByteArray(headers.get("X-Solr-AuthData")), UTF_8);
assertEquals("{\n" + assertEquals("{\n" +

View File

@ -1 +0,0 @@
da335ee2e7d1439dcc7e11e89941edfad91e9e10

View File

@ -0,0 +1 @@
2f043b2b3b9d27c17f2a067521dfb69b41fea1b8

View File

@ -1 +0,0 @@
3b8c59c68d52a3d0de0d53f5b3588be3a5c05fb8

View File

@ -0,0 +1 @@
81ac98f3be6a902e39e3f48496c9790dd02d4950

View File

@ -1 +0,0 @@
3aaf2c8c9c781f10d4d9da6120c5195b2fcb2ad9

View File

@ -0,0 +1 @@
916f481032995159d062ffc44f566891872d8a07

View File

@ -1 +0,0 @@
95f58cd0cfa0c4553fc3901138cc6a03ece23b94

View File

@ -0,0 +1 @@
cde2b06c3134600309061a84759d1ef9087a7348

View File

@ -1 +0,0 @@
672891a1abbeef85192d137192e347872a6fc9c3

View File

@ -0,0 +1 @@
41365c22bc6046af6e1e10f1be0b4dbfe49902be

View File

@ -1 +0,0 @@
8c9283b8a04056a0fced23fc474e62aa39764c6b

View File

@ -0,0 +1 @@
4aa2da175202a62d62850ade7fb26a64fd451bc2

View File

@ -1 +0,0 @@
37eff0bd068adca090e14a0fbd9de258a871f9d9

View File

@ -0,0 +1 @@
d3e23487151f5393bdcef5449407c5ce29718cdc

View File

@ -1 +0,0 @@
7e7f62c2c03b74e59211eeeba0ddc067ad422ff7

View File

@ -0,0 +1 @@
7a999fbfb9905465c1494052b612b4a4bbb349b7

View File

@ -1 +0,0 @@
5dd67dacaf1eed80ab95493da840dab35c22ce9c

View File

@ -0,0 +1 @@
aaacd77f8073e98f8400d042e70538623b3924ed

View File

@ -1 +0,0 @@
4386c1f243042e0f78f2e4c3c6cd239967410d6e

View File

@ -0,0 +1 @@
09dd286abe644513305864453030e9c1631b5535

View File

@ -1 +0,0 @@
4acddfa41f45790e43fe4be257c3c4bcf6b846ff

View File

@ -0,0 +1 @@
69125cf74b07f1b9d60b5c94da47cb04c098f654

View File

@ -1 +0,0 @@
8b350466ff1fcb7030a7abc152eed458e086fac2

View File

@ -0,0 +1 @@
12d71fe6d671c635f1ae6fd3c31bc6578a293c4b

View File

@ -1 +0,0 @@
b59ff8ecb0cf5d6234958f2404eabf0b72464e14

View File

@ -0,0 +1 @@
d3f0b0fb016ef8d35ffb199d928ffbcbfa121c86

View File

@ -1 +0,0 @@
7eb9a6be62d84e1691e5fdc99223e632485619a8

View File

@ -0,0 +1 @@
dcb6d4d505ef74898e3a64a38c40195c01e97119

View File

@ -1 +0,0 @@
8dc81acdc4d3085c0b5f3c80b9a78cc9cb48bc4e

View File

@ -0,0 +1 @@
22be18a055850a6cf3b0efd56c789c3929c87e98

View File

@ -1 +0,0 @@
9b830886bd6098c613ed08d99574bbf300519506

View File

@ -0,0 +1 @@
7990b0f4e8cafe99b47148df9aa3276af336d4d5

View File

@ -1 +0,0 @@
bfe96e1e78719bdd446e063c3f45c132010237ce

View File

@ -0,0 +1 @@
9fa640d36c088cf55843900043d28aef830ade4d

View File

@ -1 +0,0 @@
55786f6e6649bd49425a7da1ac72cd85b8dd4bef

View File

@ -0,0 +1 @@
7885cc3d5d7701a444acada7ab97f89846514875

View File

@ -1 +0,0 @@
89e25610b3199fdf34a831c1b306f7e765928959

View File

@ -0,0 +1 @@
ca1803fde51b795c0a8346ca8bc6277d9d04d01d

View File

@ -1 +0,0 @@
b290c176abe2cd9274b9f794bf74497c4759359d

View File

@ -0,0 +1 @@
b7bb7913d7583ee8d877f1c20feeb0905f342ad5

View File

@ -1 +0,0 @@
2fd3cd40279280e8c56241f753d2c52d8d446d19

View File

@ -0,0 +1 @@
3095acb088f4ff9e3fd9aedf98db73e3c18ea849

View File

@ -1 +0,0 @@
945fc0c0fa69504c194e32c5330afa1df0be9574

View File

@ -0,0 +1 @@
968d70676fa16b3d62487987624dd4e9ce5db123

View File

@ -1 +0,0 @@
d25e67fbe0809cae777065b75b10ecfb5c1bd749

View File

@ -0,0 +1 @@
a5da43f9b72d2208b8f4d22ba0a16d176b328b91

View File

@ -1 +0,0 @@
b81ef162970cdb9f4512ee2da09715a856ff4c4c

View File

@ -0,0 +1 @@
bba231bbf3024c19e75622ec168821cbbd4261a4

View File

@ -1 +0,0 @@
76e8758356373d5aed5abacbda429b38f6e8fa98

View File

@ -0,0 +1 @@
c98a2821eeb9193001c131a6d742a8f4e67e3b10

View File

@ -1 +0,0 @@
87f3b49a7377e56f62046875d394ed0028b37690

View File

@ -0,0 +1 @@
96b3aefcd0544de7e0e1f72990968b48c3d04dd1

View File

@ -1 +0,0 @@
d7be4ddd7ba674ee8be1d23d883fb3ca68ee1d54

View File

@ -0,0 +1 @@
73a242395eadde5bc4cd16a43230531dccb3d0eb

View File

@ -1 +0,0 @@
09f6f1e6c1db440d9ad4c3114f17be40f66bb399

View File

@ -0,0 +1 @@
01c23f7c463f8f4e83209d83b0549cea5d51ec1c

View File

@ -1 +1 @@
6ab950be264e74803f12ba43ee5db434a74e6c0c ddb54190e858875fb681a6b9dd630a3609eaa513