Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WINDUPRULE-404: eap 7.3 maven-artemis-jms-client rules #384

Merged
merged 1 commit into from Jan 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
39 changes: 39 additions & 0 deletions rules-reviewed/eap7/eap72/maven-artemis-jms-client.rhamt.xml
@@ -0,0 +1,39 @@
<?xml version="1.0"?>
<ruleset xmlns="http://windup.jboss.org/schema/jboss-ruleset" id="maven-artemis-jms-client"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://windup.jboss.org/schema/jboss-ruleset http://windup.jboss.org/schema/jboss-ruleset/windup-jboss-ruleset.xsd">
<metadata>
<description>
This ruleset provides analysis of Maven built applications that depend on Artemis JMS Client artifacts, which requires a dependency on wildfly-client-properties artifact too, starting with JBoss EAP 7.3.
</description>
<dependencies>
<addon id="org.jboss.windup.rules,windup-rules-javaee,3.0.0.Final" />
<addon id="org.jboss.windup.rules,windup-rules-java,3.0.0.Final" />
</dependencies>
<targetTechnology id="eap" versionRange="[7,8)" />
</metadata>
<rules>
<!-- https://issues.jboss.org/browse/WINDUPRULE-404 -->
<rule id="maven-artemis-jms-client-00001">
<when>
<not>
<project>
<artifact groupId="org.jboss.eap" artifactId="wildfly-client-properties" />
</project>
</not>
<and>
<project>
<artifact groupId="org.apache.activemq" artifactId="artemis-jms-client" />
</project>
</and>
</when>
<perform>
<hint title="Artemis JMS Client requires wildfly-client-properties" effort="1" category-id="potential">
<message>If you migrate your application to JBoss EAP 7.3 (or later), and want to ensure its Maven building, running or testing works as expected, if the application depends on Artemis JMS Client artifact then it should also depend on artifact with groupId `org.jboss.eap`, and artifactId `wildfly-client-properties`.</message>
<link title="Red Hat JBoss EAP 7.3: Messaging Application Changes Required for JBoss EAP 7.2" href="https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.3/html-single/migration_guide/index#migrate_messaging_application_changes_7_2"/>
<tag>JMS</tag>
</hint>
</perform>
</rule>
</rules>
</ruleset>
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.jboss.windup.rules.test</groupId>
<artifactId>windup-rulesets-test-pom</artifactId>
<version>4.2.1_SNAPSHOT</version>
</parent>

<artifactId>maven-artemis-jms-client</artifactId>

<dependencies>
<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>artemis-jms-client</artifactId>
</dependency>
</dependencies>

</project>
@@ -0,0 +1,24 @@
<?xml version="1.0"?>
<ruletest xmlns="http://windup.jboss.org/schema/jboss-ruleset"
id="maven-artemis-jms-client-test" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://windup.jboss.org/schema/jboss-ruleset http://windup.jboss.org/schema/jboss-ruleset/windup-jboss-ruleset.xsd">
<testDataPath>data/data-maven-artemis-jms-client/</testDataPath>
<rulePath>../maven-artemis-jms-client.rhamt.xml</rulePath>
<ruleset>
<rules>
<!--https://issues.jboss.org/browse/WINDUPRULE-404 -->
<rule id="maven-artemis-jms-client-00001-test">
<when>
<not>
<iterable-filter size="1">
<hint-exists message="If you migrate your application to JBoss EAP 7.3 \(or later\), and want to ensure its Maven building, running or testing works as expected, if the application depends on Artemis JMS Client artifact then it should also depend on artifact with groupId `org.jboss.eap`, and artifactId `wildfly-client-properties`." />
</iterable-filter>
</not>
</when>
<perform>
<fail message="No reference to `org.apache.activemq:artemis-jms-client`found in pom.xml" />
</perform>
</rule>
</rules>
</ruleset>
</ruletest>