## What changed
- make `run-regression-test.sh` select and validate JDK 17 before
invoking Maven
- prefer a valid `JAVA_HOME` or `JDK_17`, with Linux and macOS discovery
fallbacks
- build the regression framework and Java UDF case jar with the same JDK
17
- compile `java-udf-src` with `maven.compiler.release=17`
## Why
The regression build depended on the caller to prepare `JAVA_HOME`, and
newer branches also switched to JDK 8 only for the Java UDF module. This
split ownership between CI and the Doris build script and could produce
incomplete case artifacts when the framework required JDK 17.
Keeping Java selection in `run-regression-test.sh` makes local and CI
builds follow the same contract and removes the Java 8-only UDF build
path.
## Validation
- `bash -n run-regression-test.sh`
- `git diff --check`
- ran `./run-regression-test.sh --clean` while the incoming `JAVA_HOME`
pointed to JDK 22; the script selected JDK 17 and Maven reported Java 17
- built `regression-test/java-udf-src` with JDK 17 successfully
- verified `Echo$EchoInt` has class major version 61 and the expected
UDF classes are present in the assembled jar
The regression framework truncated the remaining time
before an hour or day boundary to whole seconds. Sleeping for that
truncated value could resume in the final fractional second before the
boundary, allowing a boundary-sensitive case to cross it and fail
intermittently. This change computes the wait in milliseconds and sleeps
one additional millisecond so execution resumes strictly after the
boundary. It also adds focused coverage for fractional, exact, and safe
boundary windows and aligns the JUnit API with the engine already
provided by Groovy.
## Proposed changes
Align the regression-test framework's dependency versions with fe-core
(`fe/pom.xml`):
- `arrow.version`: `17.0.0` -> `19.0.0`
- `netty-all`: `4.1.104.Final` -> `4.2.15.Final`
- `maven.compiler.source/target`: `1.8` -> `17` (Arrow 18+ requires JDK
17, and the regression build already runs on JDK 17)
This is a **dependency-alignment / JDK17-target change only**. It keeps
the framework's Arrow Flight SQL JDBC driver and netty in lockstep with
fe-core instead of drifting on older versions.
### Scope / risk
- Only `regression-test/framework/pom.xml` is touched.
- Raising `maven.compiler.target` to 17 affects the compiled output of
the whole regression framework, so this needs full regression CI to
validate, not just a local build.
- It does **not** fix the intermittent `arrow_flight_sql_p0` close-time
buffer leak — that has a separate root cause and will be handled in a
follow-up.
---------
Co-authored-by: Dongyang Li <lidongyang@selectdb.com>
### What problem does this PR solve?
Issue Number: None
Related PR: None
Problem Summary: Align FE-side protobuf and Arrow Java dependencies for
the protobuf 4 / Arrow 19 evaluation, add the required Gson exclusion
for protobuf 4 builders, and cover the behavior with a focused FE unit
test.
### Release note
None
Problem Summary:
try to reduce issue like below:
[ERROR] Failed to execute goal on project regression-test: Could not
resolve dependencies for project
org.apache.doris:regression-test:jar:1.0-SNAPSHOT: Could not transfer
artifact com.azure:azure-core:jar:1.49.0 from/to central
(https://repo.maven.apache.org/maven2): GET request of:
com/azure/azure-core/1.49.0/azure-core-1.49.0.jar from central failed:
Premature end of Content-Length delimited message body (expected:
842,694; received: 278,057) -> [Help 1]
### What problem does this PR solve?
1. support -f parameter to run specified case file
./run-regression-test.sh --run -f
regression-test/suites/tpch_sf0.1_p1/sql/q01.sql
is equivalent to
./run-regression-test.sh --run -f
regression-test/suites/tpch_sf0.1_p1/sql -s q01
2. print regression log in log file
the end of log file looks like this:
2025-10-10 18:10:26.819 INFO [main] (RegressionTest.groovy:478) - Test 1
suites, failed 1 suites, fatal 0 scripts, skipped 0 scripts
2025-10-10 18:10:26.820 INFO [main] (RegressionTest.groovy:130) - Test
finished
2025-10-10 18:10:26.820 INFO [main] (RegressionTest.groovy:153) -
================================================================================
2025-10-10 18:10:26.821 INFO [main] (RegressionTest.groovy:154) - Log
file:
/xxx/doris/output/regression-test/log/doris-regression-test.20251010.180949.log
2025-10-10 18:10:26.821 INFO [main] (RegressionTest.groovy:155) -
================================================================================
2025-10-10 18:10:26.969 INFO [Thread-0]
(plugin_query_timeout_debugger.groovy:93) - stop worker
1. Make docker suite no need external doris cluster:
a. run docker suite according to ClusterOptions.cloudMode = true/false;
b. if ClusterOptions.cloudMode = null, user can set it with cmd: `sh
run-regression-test.sh --run docker_action -runMode=cloud/not_cloud`
2. refactor database.py, simplifier its logic;
3. doris compose add cmd options -v for debug log.
4. doris compose print flush buffer.
If many docker suites run parallel, the docker containers take a lot
memory, so use independent executor for them to control the memory
usage.
Use options or config dockerSuiteParallel to set the docker suite
parallel, default is 1.
## Proposed changes
./run-regression.sh accept -d parameter with "./regression-test/suites/"
or “regression-test/suites/" prefix
for example:
./run-regression-test.sh --run -d
regression-test/suites/nereids_tpch_shape_sf1000_p0/shape -s q1
with the prefix, we could use command completion (supported by shell) to
indicate with directory to run
Issue Number: close #xxx
<!--Describe your changes.-->
when use java udf , we can put its jars in custom_lib of FE and BE in advance, and then we can create function without file property:
```
CREATE FUNCTION java_udf_add_one(int) RETURNS int PROPERTIES (
"symbol"="org.apache.doris.udf.AddOne",
"always_nullable"="true",
"type"="JAVA_UDF"
);
```
and we can use file property for custom jar:
```
CREATE FUNCTION java_udf_add_one(int) RETURNS int PROPERTIES (
"file"="file:///path/to/java-udf-demo.jar",
"symbol"="org.apache.doris.udf.AddOne",
"always_nullable"="true",
"type"="JAVA_UDF"
);
```
on FE, we use null location if the 'file' property is not set
on BE, we get jar path if both file path location and checksum are null
--add-opens=java.base/java.nio=ALL-UNNAMED, see: https://arrow.apache.org/docs/java/install.html#java-compatibility
groovy use flight sql connection to execute query SUM(MAX(c1) OVER (PARTITION BY)) report error: AGGREGATE clause must not contain analytic expressions, but no problem in Java execute it with jdbc::arrow-flight-sql.
groovy not support print arrow array type, throw IndexOutOfBoundsException.
"arrow_flight_sql" not support two phase read
./run-regression-test.sh --run --clean -g arrow_flight_sql
Introduced a new function non_nullable to BE, which can extract concrete data column from a nullable column. If the input argument is already not a nullable column, raise an error.
json reader DCHECK fail because of missing TYPE_STRING
fix bug that if no file is found, the tvf will throw NPE.
The predicate conjuncts can not be pushed down to parquet reader if this is a load task.
Because the predicate should be applied on column of dest table, not on column of source file.
Add a temp property "use_new_load_scan_node" of broker load to make regression test happy.
So that we can use new load scan node for a certain job and avoid setting global FE config.
support suite block to specify multiple groups.
TestAction support compare result to iterator, local file and http stream.
support print teamcity service message.
abandon the logical: generate groovy file for sql file
support 3 levels parrallel: script file, suite block, thread action
support specify JAVA_OPTS for boot shell
avoid jvm metaspace oom
use -d to run the suite in some directories, instead of -g. and -g is used to specify groups
Add scalable regression testing framework(#7584)
contains
- Test framework making by groovy, and support built-in **readable DSL** named as `Action`
- Demo exists in `${DORIS_HOME}/regression-test/data/demo`
- Chinese doc exist in `${DORIS_HOME}/docs/zh-CN/developer-guide/regression-testing.md`
English document coming soon