diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f02c356b6d5..fbb65595afc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -408,7 +408,7 @@ jobs: - name: Maven validate run: | export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}" - $RETRY $MAVEN validate ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -P disable-check-spi-dependencies -pl '!:trino-docs,!:trino-server,!:trino-server-rpm' + $RETRY $MAVEN validate ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -P disable-check-spi-dependencies -pl '!:trino-docs' - name: Set matrix id: set-matrix run: | @@ -658,10 +658,10 @@ jobs: - name: Map impacted plugins to features run: | export MAVEN_OPTS="${MAVEN_INSTALL_OPTS}" - $MAVEN validate ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -pl '!:trino-docs,!:trino-server-rpm' + $MAVEN validate ${MAVEN_FAST_INSTALL} ${MAVEN_GIB} -Dgib.logImpactedTo=gib-impacted.log -pl '!:trino-docs' # GIB doesn't run on master, so make sure the file always exist touch gib-impacted.log - testing/trino-plugin-reader/target/trino-plugin-reader-*-executable.jar -i gib-impacted.log -p core/trino-server/target/trino-server-*-hardlinks/plugin > impacted-features.log + testing/trino-plugin-reader/target/trino-plugin-reader-*-executable.jar -i gib-impacted.log -p core/trino-server/target/trino-server-*-hardlinks/plugin -a core/trino-server,core/trino-server-rpm > impacted-features.log echo "Impacted plugin features:" cat impacted-features.log - name: Product tests artifact @@ -766,7 +766,7 @@ jobs: EOF - name: Build PT matrix (all) if: | - github.event.name != 'pull_request' || + github.event_name != 'pull_request' || steps.filter.outputs.product-tests == 'true' || contains(github.event.pull_request.labels.*.name, 'tests:all') || contains(github.event.pull_request.labels.*.name, 'tests:all-product') @@ -775,7 +775,7 @@ jobs: ./.github/bin/build-pt-matrix-from-impacted-connectors.py -v -m .github/test-pt-matrix.yaml -o matrix.json - name: Build PT matrix (impacted-features) if: | - github.event.name == 'pull_request' && + github.event_name == 'pull_request' && steps.filter.outputs.product-tests == 'false' && !contains(github.event.pull_request.labels.*.name, 'tests:all') && !contains(github.event.pull_request.labels.*.name, 'product-tests:all') diff --git a/testing/trino-plugin-reader/src/main/java/io/trino/server/PluginReader.java b/testing/trino-plugin-reader/src/main/java/io/trino/server/PluginReader.java index 77262e667f0..bf123ad9678 100644 --- a/testing/trino-plugin-reader/src/main/java/io/trino/server/PluginReader.java +++ b/testing/trino-plugin-reader/src/main/java/io/trino/server/PluginReader.java @@ -86,6 +86,9 @@ public class PluginReader @Option(names = {"-r", "--root-pom"}, description = "Trino root module pom.xml") private File rootPom = new File("pom.xml"); + @Option(names = {"-a", "--allowed-non-plugins"}, split = ",", description = "Allowed non-plugin modules, before ignoring whole impacted modules list; usually dependents of plugins") + private List allowedNonPlugins = List.of(); + public static void main(String... args) { int exitCode = new CommandLine(new PluginReader()).execute(args); @@ -107,7 +110,9 @@ public Integer call() .collect(toMap(plugin -> plugin.getClass().getName(), identity())); Stream> modulesStream = requireNonNull(modulesToPlugins).entrySet().stream(); if (impactedModules.isPresent()) { - List nonPluginModules = impactedModules.get().stream().filter(module -> !modulesToPlugins.containsKey(module)).collect(Collectors.toList()); + List nonPluginModules = impactedModules.get().stream() + .filter(module -> !modulesToPlugins.containsKey(module) && !allowedNonPlugins.contains(module)) + .collect(Collectors.toList()); if (nonPluginModules.size() != 0) { log.warn("Impacted modules list includes non-plugin modules, ignoring it: %s", nonPluginModules); }