You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "janhoy (via GitHub)" <gi...@apache.org> on 2026/05/30 18:46:22 UTC
[PR] Speed up BATS tests [solr]
janhoy opened a new pull request, #4478:
URL: https://github.com/apache/solr/pull/4478
The BATS test suite was taking longer and longer, now about 40 mins on GH CI. This PR makes targeted, low-risk reductions without removing meaningful coverage.
**Total estimated CI time saving: ~6 minutes**
## Changes
### Gate OpenNLP test behind `OPENNLP_TESTS=true` (~90 s saved)
`test_opennlp.bats` downloads ONNX models from the network and its own comment describes it as exploratory rather than a regular CI test. It now skips unless `OPENNLP_TESTS=true` is set.
### `test_status.bats` — one shared Solr startup (~200 s saved)
Four of six tests independently started and stopped their own Solr instance. Restructured with `setup_file`/`teardown_file` so all tests share a single startup (~3 Solr startups saved).
CI timing showed "status with --short format" at 197 s — almost certainly caused by `solr stop` in teardown hanging when each test managed its own Solr lifecycle. The new structure uses a single
`teardown_file` stop which eliminates this.
### `test_healthcheck.bats` — cheaper collection setup (~15 s saved)
Both tests used `solr start -e films`, which loads and indexes the full films dataset. Replaced with `solr start` + `solr create -c healthcheck_test -d _default` for the cloud test, and plain `solr
start --user-managed` for the standalone test (which fails before any collection is needed).
### `test_packages.bats` → `PackageToolTest.java` (~25 s saved, delete BATS file)
`PackageToolTest` already exercises the full package lifecycle (list-available, add-repo, install, deploy, undeploy). Added `testDeployValidationMessages()` to cover the two specific BATS assertions
not previously tested in JUnit: collection exists but package does not → correct error message; undeploy of never-deployed package → correct error message.
### `test_compression.bats` → `GzipCompressionTest.java` (~23 s saved, delete BATS file)
The per-test times (154 ms, 72 ms, 77 ms) looked cheap, but the `setup_file` that ran `solr start -e films` cost ~22 s before any test ran. Added `GzipCompressionTest` to `solr/core`
(`SolrCloudTestCase`) verifying Jetty's GzipHandler via the same Jetty `HttpClient` pattern used by `CacheHeaderTest` and `SecurityHeadersTest`. Sets `jetty.gzip.minGzipSize=1` as a system property
before cluster start so that any non-empty response body is eligible for compression.
### `test_zk.bats` — remove/replace unnecessary `sleep` calls (~7 s saved)
Removed six `sleep 1` calls that were redundant: `solr start` already waits until Solr is ready before returning, and `solr zk cp` is synchronous. Replaced one `sleep 1` after `solr zk upconfig` with
`wait_for` that polls the configsets REST endpoint instead of relying on a fixed delay.
## Testing
```bash
# JUnit
./gradlew :solr:core:test --tests "*.PackageToolTest"
./gradlew :solr:core:test --tests "*.GzipCompressionTest"
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "KhushJain (via GitHub)" <gi...@apache.org>.
KhushJain commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4640716364
Noticed `PackageToolTest.testDeployValidationMessages` fails. @dsmiley can we get that PR merged.
Thanks for fixing it!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3330337473
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
Solrcloud is the default now, why not - it's a 1-node "cluster". Is there some overhead with SolrCloudTestCase that we don't have with a simpler JettySolrRunner?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "epugh (via GitHub)" <gi...@apache.org>.
epugh commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3357980426
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
Could we split this and merge whats working?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3330790125
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
My point is the principle of using the leanest test infrastructure to accomplish the testing goal. Default doesn't matter.
Where is the gzip support in the SolrCloudTestCase/MiniSolrCloudCluster you speak of?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3359006300
##########
solr/packaging/test/README.md:
##########
@@ -55,6 +55,24 @@ Some tests will start clusters or create collections,
It is recommended that you install and run `shellcheck` to verify your test scripts and catch common mistakes before committing your changes.
+## Nightly Tests
+
+Some BATS tests are slow or require network access (e.g. downloading models) and are
+excluded from regular runs by default. These tests use BATS native tagging via
+`# bats test_tags=nightly` and are filtered out with `--filter-tags !nightly`.
+
+To include nightly tests, pass the Gradle property `solr.bats.nightly`:
+
+ ./gradlew integrationTests -Psolr.bats.nightly=true
Review Comment:
I have configured all integration test jobs in Jenkins with this Gradle property
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "epugh (via GitHub)" <gi...@apache.org>.
epugh commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4586990724
An interesting things about the AI generated code comments is that I really like them to help me understand "this is the migraiton, this is what was before, this is how we do it now", but that the life span of that comment is that of the PR, once the PR is merged, I wish the comment disappeared. I think that some of the "self review" comments people put into PR's accomplish that same goal.
I also expect at some point that in a `git diff` you will someday see files that are added/changed/removed, and then a set of files that are marked to be deleted WHEN the PR is merged. I know I often have a `notes.md` file that accidentally gets committed that is my notes to myself when working on the code. It would be nice if we could label files as only lasting as long as the PR is open!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy merged PR #4478:
URL: https://github.com/apache/solr/pull/4478
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4635139748
> ./gradlew :solr:core:test --tests "org.apache.solr.cli.PackageToolTest.testDeployValidationMessages" "-Ptests.jvmargs=-XX:TieredStopAtLevel=1 -XX:+UseParallelGC -XX:ActiveProcessorCount=1 -XX:ReservedCodeCacheSize=120m" -Ptests.seed=1857D9F7F40D1569 -Ptests.useSecurityManager=true -Ptests.file.encoding=ISO-8859-1
Claude Opus's analysis:
----
The new `testDeployValidationMessages` test is broken. It fails with `AssertionError: Should report missing package`.
**Root cause:** `PackageManager.deploy()` outputs the error message via `printRed()` → `SolrCLI.print()` → `CLIO.out()`, which writes directly to stdout. But the test captures output through `CLITestHelper.TestingRuntime`, which only captures calls to its own `print()`/`println()` methods. Since `printRed()` bypasses the `TestingRuntime` entirely, `captureRuntime.getOutput()` is empty and the assertion at line 405 fails.
Additionally, after `printRed()`, `runtime.exit(1)` throws `RuntimeException("exit() not allowed in tests")`, which `ToolBase.runTool()` catches and prints to `CLIO.err()` — also not captured by the runtime.
The fix would be to route error output in `PackageManager` through the `ToolRuntime` instead of the static `CLIO.out()`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3330337473
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
Solrcloud is the default now, why not - it's a 1-node "cluster". Is there some overhead with SolrCloudTestCase that we don't have with a simpler JettySolrRunner?
I also tried to refactor to `JettySolrRunner` but it has no GZip handler as the cloud setup does.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "epugh (via GitHub)" <gi...@apache.org>.
epugh commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3330360027
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,96 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
I miss the succinteness of the .bats test and how easy it is to read (to my eyes at least!), but totally understand the overhead.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3330320776
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
Review Comment:
Agree.Our `AGENTS.md` explicitly says not to document changes but facts, but maybe we need to give more examples or state it even more clear for LLMs to respect it?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3331041579
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,96 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
If we keep adding BATS tests in the pace we have been doing lately, we'll surpass 60m run time very soon. So we should probably reserve BATS for testing our bin/solr shell script, plus mechanisms that won't kick in in unit tests. The java-agent is an example of such. And "realistic" jetty setup is probably another.
But I'd hope that as we succeed in slimming down bin/solr even more and move things into java-land, we should be able to migrate more BATS tests to JUnit since the logic is no longer done in bash.
We have already delegated lots of SolrCLI arg parsing to java-land. There is still some glue in script that construct the java cmdline, which do need to be tested, but the cmdline arg/opts parsing for each tool should not need full bats coverage if we know we have separate junit coverage of such parsing.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4625160375
@epugh I think this is ready for merge now. Then we can do new improvement PRs later.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4860694241
Feel free to snipe this.. 🤣
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3353354555
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
As I expected, this doesn't work:
```
java.lang.AssertionError: Expected gzip Content-Encoding when Accept-Encoding: gzip was requested
Expected :gzip
Actual :null
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3358172953
##########
solr/packaging/test/test_healthcheck.bats:
##########
@@ -29,22 +29,18 @@ teardown() {
}
@test "healthcheck on cloud solr" {
- solr start -e films
- run solr healthcheck -c films
+ solr start
+ solr create -c healthcheck_test -d _default
+ # Local
+ run solr healthcheck -c healthcheck_test
refute_output --partial 'error'
-
-}
-
-@test "healthcheck on remote cloud solr" {
- solr start -e films
- run solr healthcheck -c films --solr-connection http://localhost:${SOLR_PORT}/solr
+ # Remote
+ run solr healthcheck -c healthcheck_test --solr-connection http://localhost:${SOLR_PORT}/solr
Review Comment:
@epugh I merged the local and remote test in the same solr invocation
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3329666269
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
Why would use need SolrCloud for only a jetty level thing?
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
Review Comment:
we shouldn't have comments like this. Document things as they are, not what they were before.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3331045410
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
I'd have to dive into the test setup to answer. I thought we used same JettySolrRunner as in standalone, and that Jetty is configured in java instead of xml, but still not 100% identical. I have not verified that the new Gzip test actually tests what it claims to. Will have to do a manual dive to verify. I had my hopes up when Claude selected it as a low hanging fruit.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4628824707
The focus for this PR was to rewrite tests to speed up as much as possible.
Then came the wish to remove or disable the opennlp test fully, which morphed into the tagging infra for vats tests.
As I answered epugh , we should do both. Make tests as fast as possible as well as moving certain kinds of tests to nightly.
The criteria for nightly could be discussed, and this PR was not aiming to do it all but to fix the worst and kickstart what will hopefully be more PRs?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3358038158
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
Reverted Gzip "improvements" 😂🥳
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4631646825
ok... then strange to introduce solr.bats.nightly here as then it's off-topic to your topic of only making tests faster. Any way, no problem.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4860266433
@janhoy Note: this has not been ported to branch_10x yet. According to Hossman, if I were to do so, I'd be "sniping" your PR ;-) -- his point is really opt-in to another person's attempt to backport stuff en-masse.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4860422666
BTW I added `-Psolr.bats.nightly=true` to Solr-TestIntegration-main Jenkins job. Didn't touch others. I assume the "nightly" aspect isn't necessarily literally but more about opt-in / infrequent. Definitely not for the PR GHA workflow.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4585067225
Estimated speedup was 10min, i.e. from 40 to 39 minutes. Reality for last run was
```
BUILD SUCCESSFUL in 24m 49s
```
So that's almost 50% improvement!
Now 10 slowest are:
<img width="1472" height="1024" alt="image" src="https://github.com/user-attachments/assets/3fba0d91-c426-421f-b67d-456a85f7d667" />
Anyone see more bats tests that could be improved?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3357961836
##########
solr/core/src/test/org/apache/solr/servlet/GzipCompressionTest.java:
##########
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.servlet;
+
+import org.apache.solr.client.solrj.request.CollectionAdminRequest;
+import org.apache.solr.client.solrj.request.UpdateRequest;
+import org.apache.solr.cloud.SolrCloudTestCase;
+import org.apache.solr.common.SolrInputDocument;
+import org.eclipse.jetty.client.ContentResponse;
+import org.eclipse.jetty.client.HttpClient;
+import org.eclipse.jetty.http.HttpHeader;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+/**
+ * Verifies that Solr's Jetty GzipHandler correctly compresses HTTP responses when the client sends
+ * {@code Accept-Encoding: gzip} and omits compression when that header is absent.
+ *
+ * <p>Replaces the BATS integration test {@code test_compression.bats}.
+ */
+public class GzipCompressionTest extends SolrCloudTestCase {
Review Comment:
😟 Ok, thanks, makes sense. Will put this in DRAFT until I get to fix this..
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4627253802
Glad to see `solr.bats.nightly=true` but why didn't this PR actually tag our slowest integration tests (according to the bar chart)?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on code in PR #4478:
URL: https://github.com/apache/solr/pull/4478#discussion_r3358164778
##########
solr/packaging/test/README.md:
##########
@@ -55,6 +55,24 @@ Some tests will start clusters or create collections,
It is recommended that you install and run `shellcheck` to verify your test scripts and catch common mistakes before committing your changes.
+## Nightly Tests
+
+Some BATS tests are slow or require network access (e.g. downloading models) and are
+excluded from regular runs by default. These tests use BATS native tagging via
+`# bats test_tags=nightly` and are filtered out with `--filter-tags !nightly`.
+
+To include nightly tests, pass the Gradle property `solr.bats.nightly`:
+
+ ./gradlew integrationTests -Psolr.bats.nightly=true
Review Comment:
> @dsmiley wrote: Sounds like we should have a general concept of "nightly" BATS.
Did some research and wired in BATS concept of test tagging. So now we can tag slow tests as done for `test_opennlp.bats` and they will only run when gradle is invoked with `-Psolr.bats.nightly=true`.
Thus we can configure Jenkins with this prop...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org
Re: [PR] Speed up BATS tests [solr]
Posted by "janhoy (via GitHub)" <gi...@apache.org>.
janhoy commented on PR #4478:
URL: https://github.com/apache/solr/pull/4478#issuecomment-4640709703
Good catch. Refactored PackageManager to print thorugh `runtime` in #4502
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org