From 5f3c374036f6b3f30659cd5a07938783ad2a9763 Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Wed, 16 Sep 2026 14:00:48 +0300 Subject: [PATCH 1/6] Stop installing and deploying boot jars, Windows zips and debs --- TEST_FAST.md | 2 +- msa/pom.xml | 11 ++++----- pom.xml | 65 +++++++++------------------------------------------- 3 files changed, 16 insertions(+), 62 deletions(-) diff --git a/TEST_FAST.md b/TEST_FAST.md index fbea72db9c..28f4b4059a 100644 --- a/TEST_FAST.md +++ b/TEST_FAST.md @@ -42,7 +42,7 @@ Use `-Dpkg.skip=true` to skip all packaging at once (equivalent to all four flag |----------------------------|-------------------------------------------|--------------------------------------------------------------| | `-Dpkg.skip=true` | All of the below (bootjar + deb + rpm + zip) | Yes | | `-Dpkg.skip.bootjar=true` | `spring-boot:repackage` (`*-boot.jar`) | Yes — tests use the regular `.jar`, not the fat boot jar | -| `-Dpkg.skip.deb=true` | Gradle `buildDeb` + Maven `attach-artifact` | Yes — MSA docker modules copy the DEB from `target/` directly | +| `-Dpkg.skip.deb=true` | Gradle `buildDeb` | Yes — MSA docker modules copy the DEB from `target/` directly | | `-Dpkg.skip.rpm=true` | Gradle `buildRpm` | Yes — no test depends on the RPM | | `-Dpkg.skip.zip=true` | `maven-assembly-plugin` Windows ZIP | Yes — no test depends on the ZIP | diff --git a/msa/pom.xml b/msa/pom.xml index 3ffd8ed28b..a44cbbb93c 100644 --- a/msa/pom.xml +++ b/msa/pom.xml @@ -55,10 +55,7 @@ - + skip-deb @@ -71,9 +68,9 @@ none - + skip-pkg diff --git a/pom.xml b/pom.xml index 6ecad4cd2c..0c563899c5 100755 --- a/pom.xml +++ b/pom.xml @@ -34,14 +34,13 @@ Individual flags below can be set independently for finer control. --> false - + false @@ -50,11 +49,6 @@ module depends on the ZIP artifact, so this flag can be toggled freely without breaking downstream modules. --> false - - ${pkg.package.phase} thingsboard ${project.name} /var/log/${pkg.name} @@ -215,26 +209,7 @@ - - - skip-deb - - - pkg.skip.deb - true - - - - none - - - - + skip-pkg @@ -248,7 +223,6 @@ true true true - none @@ -565,6 +539,8 @@ ${pkg.skip.bootjar} ${pkg.mainClass} boot + + false ZIP true true @@ -641,28 +617,9 @@ ${pkg.skip.zip} - - - - - - org.codehaus.mojo - build-helper-maven-plugin - - - attach-deb - ${pkg.deb.phase} - - attach-artifact - - - - - ${project.build.directory}/${pkg.name}.deb - deb - deb - - + + false From 87a6f3088181c5a91bcf512af3cc4e4a316d5abd Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Wed, 16 Sep 2026 14:02:33 +0300 Subject: [PATCH 2/6] Stop deploying the ui-ngx jar --- ui-ngx/pom.xml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/ui-ngx/pom.xml b/ui-ngx/pom.xml index 164ce0d056..42b0fac027 100644 --- a/ui-ngx/pom.xml +++ b/ui-ngx/pom.xml @@ -71,6 +71,14 @@ + + + org.apache.maven.plugins + maven-deploy-plugin + + true + + From 32fb97af7249a34eb9a38a1392713516c4aebb4f Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Fri, 21 Aug 2026 15:35:03 +0300 Subject: [PATCH 3/6] Honour skip.yarn in the JS module tests and packaging The yarn test execution in msa/js-executor declared its own skip flag, which overrode the mojo default of ${skip.yarn}, so a build run with -Dskip.yarn=true still invoked yarn run test with no node_modules installed. The two JS packaging modules had the same gap: the ZIP assembly requires a launcher binary produced by yarn run pkg, so it failed on a missing file rather than being skipped along with the yarn work that would have produced it. Both now follow skip.yarn while continuing to honour maven.test.skip. --- msa/js-executor/pom.xml | 26 +++++++++++++++++++++++++- msa/web-ui/pom.xml | 5 +++++ 2 files changed, 30 insertions(+), 1 deletion(-) diff --git a/msa/js-executor/pom.xml b/msa/js-executor/pom.xml index 5d28be03f8..8c35b773db 100644 --- a/msa/js-executor/pom.xml +++ b/msa/js-executor/pom.xml @@ -30,6 +30,18 @@ package ${project.build.directory}/package/linux ${project.build.directory}/package/windows + + ${skip.yarn} + + ${skip.yarn} pre-integration-test @@ -112,7 +124,7 @@ test - ${maven.test.skip} + ${yarn.test.skip} --mutex network run test @@ -206,6 +218,18 @@ + + skip-yarn-test + + + maven.test.skip + true + + + + true + + yarn-start diff --git a/msa/web-ui/pom.xml b/msa/web-ui/pom.xml index b2d148d5b2..f2f5e31309 100644 --- a/msa/web-ui/pom.xml +++ b/msa/web-ui/pom.xml @@ -32,6 +32,11 @@ package ${project.build.directory}/package/linux ${project.build.directory}/package/windows + + ${skip.yarn} pre-integration-test From 6172ca8963f6feffe4ddcf80dc079f1dbbdd0e3c Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Fri, 21 Aug 2026 15:54:50 +0300 Subject: [PATCH 4/6] Add a skip.ui.build flag that skips only the UI builds frontend-maven-plugin reads skip.yarn on its own, so -Dskip.yarn=true switches off every yarn invocation in the project at once. That is the right shortcut for a local backend build, but it is too blunt for CI: it also silences the msa/js-executor sandbox tests, which are the only yarn-driven tests worth keeping. skip.ui.build is declared once in the root pom and defaults to ${skip.yarn}. It is wired into the frontend-maven-plugin configuration of ui-ngx and msa/web-ui, and into the pkg.skip.zip of msa/web-ui, whose Windows ZIP bundles the launcher that `yarn run pkg` produces. It is deliberately NOT wired into msa/js-executor: with -Dskip.ui.build=true that module still runs its yarn install, its `yarn run pkg` and its sandbox tests. Behaviour: no flags everything builds and is tested as before -Dskip.ui.build=true ui-ngx and msa/web-ui skip; msa/js-executor still builds and runs its tests -Dskip.yarn=true everything skips, exactly as before The element is declared at plugin level rather than per execution so that it also covers the executions contributed by the yarn-build and yarn-start profiles, and so that node/yarn itself is no longer downloaded when there is nothing to run. --- msa/web-ui/pom.xml | 7 +++++-- pom.xml | 7 +++++++ ui-ngx/pom.xml | 3 +++ 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/msa/web-ui/pom.xml b/msa/web-ui/pom.xml index f2f5e31309..93d2ecff76 100644 --- a/msa/web-ui/pom.xml +++ b/msa/web-ui/pom.xml @@ -33,10 +33,10 @@ ${project.build.directory}/package/linux ${project.build.directory}/package/windows - ${skip.yarn} + ${skip.ui.build} pre-integration-test @@ -65,6 +65,9 @@ target ${basedir} + + ${skip.ui.build} diff --git a/pom.xml b/pom.xml index 0c563899c5..11c0e52c30 100755 --- a/pom.xml +++ b/pom.xml @@ -28,6 +28,13 @@ 17 17 ${basedir} + + ${skip.yarn} none none + ${skip.ui.build} From 21e5d93aeca3ffc038cee2f3290df0a59c86e826 Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Wed, 16 Sep 2026 15:05:42 +0300 Subject: [PATCH 5/6] Skip all packaging when the UI build is skipped Packages built without the UI are incomplete, so -Dskip.yarn=true and -Dskip.ui.build=true now imply -Dpkg.skip=true through dedicated profiles in the root pom and msa/pom.xml. This replaces the module-level pkg.skip.zip properties in msa/js-executor and msa/web-ui, which shadowed the root skip-pkg profile and made -Dpkg.skip=true build their Windows ZIPs again. --- TEST_FAST.md | 2 ++ msa/js-executor/pom.xml | 5 ----- msa/pom.xml | 25 +++++++++++++++++++++++++ msa/web-ui/pom.xml | 5 ----- pom.xml | 37 ++++++++++++++++++++++++++++++++++++- 5 files changed, 63 insertions(+), 11 deletions(-) diff --git a/TEST_FAST.md b/TEST_FAST.md index 28f4b4059a..11f8969fca 100644 --- a/TEST_FAST.md +++ b/TEST_FAST.md @@ -46,6 +46,8 @@ Use `-Dpkg.skip=true` to skip all packaging at once (equivalent to all four flag | `-Dpkg.skip.rpm=true` | Gradle `buildRpm` | Yes — no test depends on the RPM | | `-Dpkg.skip.zip=true` | `maven-assembly-plugin` Windows ZIP | Yes — no test depends on the ZIP | +`-Dskip.yarn=true` and `-Dskip.ui.build=true` imply `-Dpkg.skip=true`: packages built without the UI are incomplete. + ## Testcontainers compatibility with the Docker API workaround In case your tests failed to run testcontainers due to unsupported Docker API version diff --git a/msa/js-executor/pom.xml b/msa/js-executor/pom.xml index 8c35b773db..3a4a1ccda4 100644 --- a/msa/js-executor/pom.xml +++ b/msa/js-executor/pom.xml @@ -30,11 +30,6 @@ package ${project.build.directory}/package/linux ${project.build.directory}/package/windows - - ${skip.yarn} + + skip-pkg-without-yarn + + + skip.yarn + true + + + + none + + + + skip-pkg-without-ui-build + + + skip.ui.build + true + + + + none + + black-box-tests diff --git a/msa/web-ui/pom.xml b/msa/web-ui/pom.xml index 93d2ecff76..9e616482cf 100644 --- a/msa/web-ui/pom.xml +++ b/msa/web-ui/pom.xml @@ -32,11 +32,6 @@ package ${project.build.directory}/package/linux ${project.build.directory}/package/windows - - ${skip.ui.build} pre-integration-test diff --git a/pom.xml b/pom.xml index 11c0e52c30..77706d1627 100755 --- a/pom.xml +++ b/pom.xml @@ -33,7 +33,8 @@ cover msa/js-executor, whose yarn install and sandbox tests keep running. frontend-maven-plugin reads skip.yarn itself, so that property cannot be narrowed to a subset of the modules; this one can, and it defaults to skip.yarn so that - -Dskip.yarn=true still skips every yarn invocation in the project exactly as before. --> + -Dskip.yarn=true still skips every yarn invocation in the project exactly as before. + Either flag also skips all packaging (see the skip-pkg-without-* profiles). --> ${skip.yarn} none none @@ -233,6 +234,40 @@ + + + skip-pkg-without-yarn + + + skip.yarn + true + + + + true + true + true + true + + + + skip-pkg-without-ui-build + + + skip.ui.build + true + + + + true + true + true + true + + + packaging From ccf0581ac38f75461b8dc7511ddce557ef4701b2 Mon Sep 17 00:00:00 2001 From: Viacheslav Klimov Date: Wed, 16 Sep 2026 15:35:28 +0300 Subject: [PATCH 6/6] Generate build-info outside the packaging profile Activating any other root profile (skip-pkg, skip-pkg-without-*) switches off the activeByDefault packaging profile, which held the only build-info execution, so such builds had no build-info.properties and ProjectInfo failed at runtime. The jar plugin config (logback.xml exclusion, manifest) moves out of the profile for the same reason. --- pom.xml | 42 ++++++++++++++++++++++++++---------------- 1 file changed, 26 insertions(+), 16 deletions(-) diff --git a/pom.xml b/pom.xml index 77706d1627..0a46f54ab1 100755 --- a/pom.xml +++ b/pom.xml @@ -554,21 +554,6 @@ - - org.apache.maven.plugins - maven-jar-plugin - - - **/logback.xml - - - - ${pkg.implementationTitle} - ${project.version} - - - - org.springframework.boot spring-boot-maven-plugin @@ -597,7 +582,6 @@ repackage - build-info @@ -717,6 +701,18 @@ org.apache.maven.plugins maven-jar-plugin ${jar-plugin.version} + + + + **/logback.xml + + + + ${pkg.implementationTitle} + ${project.version} + + + org.apache.maven.plugins @@ -727,6 +723,20 @@ org.springframework.boot spring-boot-maven-plugin ${spring-boot.version} + + + + build-info + + build-info + + + + false + + + org.thingsboard