Skip to content

Commit

Permalink
✨ update rulesets to include latest windup changes (#71)
Browse files Browse the repository at this point in the history
Signed-off-by: Pranav Gaikwad <[email protected]>
  • Loading branch information
pranavgaikwad authored Apr 24, 2024
1 parent ac07d60 commit d930baf
Show file tree
Hide file tree
Showing 331 changed files with 9,132 additions and 7,070 deletions.
12 changes: 11 additions & 1 deletion default/generated/00-discovery/0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
- License={{matchingText}}
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
or:
- builtin.filecontent:
Expand All @@ -30,6 +31,7 @@
description: "Hardcoded IP Address"
labels:
- konveyor.io/target=cloud-readiness
- konveyor.io/target=discovery
when:
builtin.filecontent:
pattern: ([0-9]{1,3}\.){3}[0-9]{1,3}
Expand All @@ -41,6 +43,7 @@
description: "Properties file"
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
builtin.file:
pattern: "^.*\\.properties$"
Expand All @@ -49,6 +52,7 @@
description: "Manifest file"
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
builtin.file:
pattern: "MANIFEST.MF"
Expand All @@ -57,6 +61,7 @@
description: "Java source files"
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
builtin.file:
pattern: "*.java"
Expand All @@ -65,13 +70,15 @@
description: "Maven XML file"
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
builtin.file:
pattern: "pom.xml"
tag: ["Maven XML"]
- ruleID: windup-discover-ejb-configuration
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
tag: ["EJB XML"]
when:
builtin.xml:
Expand All @@ -80,13 +87,15 @@
tag: ["Spring XML"]
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
builtin.xml:
xpath: "/beans"
- ruleID: windup-discover-jpa-configuration
tag: ["JPA XML"]
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
when:
or:
- builtin.xml:
Expand All @@ -98,8 +107,9 @@
- ruleID: windup-discover-web-configuration
labels:
- konveyor.io/include=always
- konveyor.io/target=discovery
tag: ["Web XML"]
when:
# TODO extract version as in rules-java-ee/addon/src/main/java/org/jboss/windup/rules/apps/javaee/rules/DiscoverWebXmlRuleProvider.java
builtin.xml:
xpath: /web-app
xpath: /web-app
19 changes: 11 additions & 8 deletions default/generated/azure/01-azure-aws-config.windup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
- konveyor.io/target=azure-container-apps
- AWS
links: []
message: "\n \n The application contains AWS credential configuration.\n \n "
message: The application contains AWS credential configuration.
ruleID: azure-aws-config-credential-01000
when:
or:
Expand All @@ -39,7 +39,7 @@
- konveyor.io/target=azure-container-apps
- AWS
links: []
message: "\n \n The application contains AWS region configuration.\n \n "
message: The application contains AWS region configuration.
ruleID: azure-aws-config-region-02000
when:
or:
Expand All @@ -66,8 +66,9 @@
- konveyor.io/target=azure-container-apps
- AWS
links: []
message: "\n \n The application contains AWS S3 configuration.\n Consider using
Azure Blob Storage instead.\n \n "
message: |-
The application contains AWS S3 configuration.
Consider using Azure Blob Storage instead.
ruleID: azure-aws-config-s3-03000
when:
or:
Expand All @@ -88,8 +89,9 @@
- konveyor.io/target=azure-container-apps
- AWS
links: []
message: "\n \n The application contains Amazon Simple Queue Service configuration.\n
Consider using Azure Service Bus instead.\n \n "
message: |-
The application contains Amazon Simple Queue Service configuration.
Consider using Azure Service Bus instead.
ruleID: azure-aws-config-sqs-04000
when:
or:
Expand All @@ -110,8 +112,9 @@
- konveyor.io/target=azure-container-apps
- AWS
links: []
message: "\n \n The application contains AWS Secrets Manager configuration.\n Consider
using Azure Key Vault instead.\n \n "
message: |-
The application contains AWS Secrets Manager configuration.
Consider using Azure Key Vault instead.
ruleID: azure-aws-config-secret-manager-05000
when:
or:
Expand Down
14 changes: 7 additions & 7 deletions default/generated/azure/02-azure-file-system.windup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
url: https://learn.microsoft.com/azure/developer/java/migration/migrate-spring-cloud-to-azure-spring-apps?pivots=sc-standard-tier#determine-whether-and-how-the-file-system-is-used
- title: Azure Spring Boot Starter for Azure Storage
url: https://search.maven.org/artifact/com.azure.spring/azure-spring-boot-starter-storage
message: "\n \n The application uses Java APIs to read/write from the file system.\n
\n Any usage of the file system on the application will require reconfiguration
or, in rare cases, architectural changes.\n \n "
message: "The application uses Java APIs to read/write from the file system.\n \n
Any usage of the file system on the application will require reconfiguration or,
in rare cases, architectural changes."
ruleID: azure-file-system-01000
when:
or:
Expand Down Expand Up @@ -46,8 +46,8 @@
links:
- title: Relative path found in the application
url: https://learn.microsoft.com/azure/developer/java/migration/migrate-spring-cloud-to-azure-spring-apps?pivots=sc-standard-tier#determine-whether-and-how-the-file-system-is-used
message: "\n \n Relative path found.\n \n Any usage of the file system on the application
will require reconfiguration or, in rare cases, architectural changes.\n \n "
message: "Relative path found.\n \n Any usage of the file system on the application
will require reconfiguration or, in rare cases, architectural changes."
ruleID: azure-file-system-02000
when:
builtin.filecontent:
Expand All @@ -69,8 +69,8 @@
links:
- title: Home path found in the application
url: https://learn.microsoft.com/azure/developer/java/migration/migrate-spring-cloud-to-azure-spring-apps?pivots=sc-standard-tier#determine-whether-and-how-the-file-system-is-used
message: "\n \n Home path found.\n \n Any usage of the file system on the application
will require reconfiguration or, in rare cases, architectural changes.\n \n "
message: "Home path found.\n \n Any usage of the file system on the application
will require reconfiguration or, in rare cases, architectural changes."
ruleID: azure-file-system-03000
when:
builtin.filecontent:
Expand Down
9 changes: 5 additions & 4 deletions default/generated/azure/03-azure-java-version.windup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
- konveyor.io/target=azure-container-apps
- version
links: []
message: "\n \n The application is using non-LTS version Java. \n JDK on LTS version
is recommended, i.e. JAVA_8, JAVA_11 or JAVA_17.\n \n "
message: "The application is using non-LTS version Java. \n JDK on LTS version is
recommended, i.e. JAVA_8, JAVA_11 or JAVA_17."
ruleID: azure-java-version-01000
when:
as: result
Expand All @@ -37,8 +37,9 @@
- konveyor.io/target=azure-container-apps
- version
links: []
message: "\n \n The application is using Java version lower than JAVA_8.\n JDK on
LTS version is recommended, i.e. JAVA_8, JAVA_11 or JAVA_17.\n \n "
message: |-
The application is using Java version lower than JAVA_8.
JDK on LTS version is recommended, i.e. JAVA_8, JAVA_11 or JAVA_17.
ruleID: azure-java-version-02000
when:
as: result
Expand Down
4 changes: 3 additions & 1 deletion default/generated/azure/04-azure-logging.windup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@
- konveyor.io/target=azure-container-apps
- logging
links: []
message: "Logging to the file system is not recommended when running applications
in the cloud. \n \n Instead, use a console appender to log to standard output."
ruleID: azure-logging-0000
tag:
- Logging to file system
Expand All @@ -22,7 +24,7 @@
pattern: (?i)((Daily)?Rolling)?FileAppender|type\s*=\s*((Daily)?Rolling)?File|<\/((Daily)?Rolling)?File>
- java.referenced:
location: IMPORT
pattern: org.apache*log4j*FileAppender*
pattern: org.apache.*log4j.*FileAppender*
- java.referenced:
location: IMPORT
pattern: java.util.logging.FileHandler*
Expand Down
6 changes: 4 additions & 2 deletions default/generated/azure/06-azure-password.windup.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,10 @@
url: https://docs.microsoft.com/azure/developer/java/spring-framework/configure-spring-boot-starter-java-app-with-azure-key-vault
- title: Azure Spring Boot Starter for Azure Key Vault Secrets
url: https://search.maven.org/artifact/com.azure.spring/azure-spring-boot-starter-keyvault-secrets
message: "\n \n Password found in configuration file.\n\n Consider using Azure Key
Vault and/or parameter injection with application settings where possible.\n \n "
message: |-
Password found in configuration file.
Consider using Azure Key Vault and/or parameter injection with application settings where possible.
ruleID: azure-password-01000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
- title: Migrate JBoss EAP applications to JBoss EAP on Azure App Service - Inventory
all certificates
url: https://docs.microsoft.com/en-us/azure/developer/java/migration/migrate-jboss-eap-to-jboss-eap-on-azure-app-service#inventory-all-certificates
message: Azure - The application loads certificates into a KeyStore
ruleID: eap-to-azure-appservice-certificates-001
tag:
- Azure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@
url: https://docs.microsoft.com/en-us/azure/developer/java/migration/migrate-jboss-eap-to-jboss-eap-on-azure-app-service#set-up-data-sources
- title: Datasource Management
url: https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.4/html/configuration_guide/datasource_management
message: "\n \n A datasource driver was found in a configuration file.\n\n There
are three core steps when registering a data source with JBoss EAP in Azure App
Service: uploading the JDBC driver, adding the JDBC driver as a module, and registering
message: "A datasource driver was found in a configuration file.\n\n There are three
core steps when registering a data source with JBoss EAP in Azure App Service:
uploading the JDBC driver, adding the JDBC driver as a module, and registering
the module.\n\n App Service is a stateless hosting service, so the configuration
commands for adding and registering the data source module must be scripted and
applied as the container starts.\n \n For more information, see Datasource Management
in the JBoss EAP documentation. \n \n "
in the JBoss EAP documentation."
ruleID: eap-to-azure-appservice-datasource-driver-01000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@
url: https://aka.ms/webapps-java-perf
- title: Environment variables and app settings in Azure App Service
url: https://aka.ms/webapps-env-vars
message: "\n \n App Service - The application reads environment variables.\n\n Any
environment variables used in the code will need to be defined as App Settings,
which are exposed\n as environment variables in App Service.\n\n Any System properties
that the code depends on will need to be provided either in a custom Startup Script\n
or by defining an App Setting with the name JAVA_OPTS and include any system properties
in it.\n \n "
message: |-
App Service - The application reads environment variables.
Any environment variables used in the code will need to be defined as App Settings, which are exposed
as environment variables in App Service.
Any System properties that the code depends on will need to be provided either in a custom Startup Script
or by defining an App Setting with the name JAVA_OPTS and include any system properties in it.
ruleID: eap-to-azure-appservice-environment-variables-001
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
url: https://aka.ms/webapps-deployment-apis
- title: Migrate JBoss EAP applications to JBoss EAP on Azure App Service
url: https://aka.ms/webapps-jboss-migrate-guide
message: "\n \n Get started with JBoss EAP on App Service with the CLI commands
below. Don't have the Azure CLI installed? Go to [https://aka.ms/azure-cli](https://aka.ms/azure-cli)\n
message: "Get started with JBoss EAP on App Service with the CLI commands below.
Don't have the Azure CLI installed? Go to [https://aka.ms/azure-cli](https://aka.ms/azure-cli)\n
\n <pre>\n # Customize these variables\n $resourceGroup=jboss-rg\n $location=eastus\n
$appName=jboss-app\n $appServicePlan=jboss-asp\n\n az group create --resource-group
$resourceGroup --location $location\n\n az appservice plan create --resource-group
Expand All @@ -26,7 +26,7 @@
az webapp deploy --resource-group $resourceGroup --plan $appServicePlan --name
$appName --type war --src-path app.war\n\n # To deploy EAR files:\n az webapp
deploy --resource-group $resourceGroup --plan $appServicePlan --name $appName
--type ear --src-path app.ear\n </pre>\n \n "
--type ear --src-path app.ear\n </pre>"
ruleID: eap-to-azure-appservice-pom-001
when:
java.dependency:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,10 @@
url: https://spring.io/projects/spring-data-redis/
- title: Azure Spring Cloud Starter Cache
url: https://search.maven.org/artifact/com.azure.spring/azure-spring-cloud-starter-cache
message: "\n \n The application uses a Redis Cache.\n\n Checkout Azure Cache for
Redis for a fully managed cache on Azure.\n \n "
message: |-
The application uses a Redis Cache.
Checkout Azure Cache for Redis for a fully managed cache on Azure.
ruleID: spring-boot-to-azure-cache-redis-01000
when:
or:
Expand Down Expand Up @@ -57,9 +59,10 @@
url: https://spring.io/projects/spring-data-redis/
- title: Azure Spring Cloud Starter Cache
url: https://search.maven.org/artifact/com.azure.spring/azure-spring-cloud-starter-cache
message: "\n \n Redis Cache connection string, username, or password used in this
application.\n\n Checkout Azure Cache for Redis for a fully managed cache on Azure.\n
\n "
message: |-
Redis Cache connection string, username, or password used in this application.
Checkout Azure Cache for Redis for a fully managed cache on Azure.
ruleID: spring-boot-to-azure-cache-redis-02000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,10 @@
url: https://docs.microsoft.com/azure/developer/java/spring-framework/configure-spring-data-jdbc-with-azure-postgresql
- title: Use Spring Data JDBC with Azure SQL Database
url: https://docs.microsoft.com/azure/developer/java/spring-framework/configure-spring-data-jdbc-with-azure-sql-server
message: "\n \n The application uses a JDBC connection string, username or password
in the configuration file.\n\n Checkout the different types of databases that
are fully managed on Azure.\n \n "
message: |-
The application uses a JDBC connection string, username or password in the configuration file.
Checkout the different types of databases that are fully managed on Azure.
ruleID: spring-boot-to-azure-database-jdbc-01000
when:
or:
Expand Down Expand Up @@ -78,8 +79,10 @@
url: https://docs.microsoft.com/azure/developer/java/spring-framework/configure-spring-data-mongodb-with-cosmos-db
- title: Spring Cloud Azure Starter Data Cosmos DB
url: https://search.maven.org/artifact/com.azure.spring/spring-cloud-azure-starter-data-cosmos
message: "\n \n The application uses a MongoDB connection string.\n\n Checkout the
different types of databases that are fully managed on Azure.\n \n "
message: |-
The application uses a MongoDB connection string.
Checkout the different types of databases that are fully managed on Azure.
ruleID: spring-boot-to-azure-database-mongodb-02000
when:
or:
Expand Down Expand Up @@ -118,9 +121,10 @@
url: https://learn.microsoft.com/azure/developer/java/spring-framework/configure-spring-data-r2dbc-with-azure-postgresql
- title: Use Spring Data R2DBC with Azure SQL Database
url: https://learn.microsoft.com/azure/developer/java/spring-framework/configure-spring-data-r2dbc-with-azure-sql-server
message: "\n \n The application uses a R2DBC connection string, username or password
in the configuration file.\n\n Checkout the different types of databases that
are fully managed on Azure.\n \n "
message: |-
The application uses a R2DBC connection string, username or password in the configuration file.
Checkout the different types of databases that are fully managed on Azure.
ruleID: spring-boot-to-azure-database-r2dbc-03000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@
url: https://learn.microsoft.com/azure/developer/java/migration/migrate-spring-cloud-to-azure-spring-apps?pivots=sc-standard-tier#identify-clients-that-bypass-the-service-registry
- title: Spring Cloud OpenFeign
url: https://spring.io/projects/spring-cloud-openfeign/
message: "\n \n The application uses Feign. Spring Cloud Service Registry uses OpenFeign
message: "The application uses Feign. Spring Cloud Service Registry uses OpenFeign
instead. When migrating to Spring Cloud Service Registry, the Feign invocations
will no longer be possible.\n \n Update the clients to use Spring Cloud OpenFeign
instead.\n \n "
instead."
ruleID: spring-boot-to-azure-feign-01000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@
url: https://docs.spring.io/spring-security/reference/index.html
- title: 'Spring Boot API: Authorization'
url: https://auth0.com/docs/quickstart/backend/java-spring-security5/01-authorization
message: "\n \n The application uses Spring security.\n\n Checkout Azure Active
Directory as an identity provider.\n \n "
message: |-
The application uses Spring security.
Checkout Azure Active Directory as an identity provider.
ruleID: spring-boot-to-azure-identity-provider-01000
when:
or:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
- konveyor.io/target=azure-container-apps
- JavaFX
links: []
message: "\n \n The application uses JavaFX.\n JavaFX is not cloud compatible and
requires the JRE on the remote device.\n \n "
message: |-
The application uses JavaFX.
JavaFX is not cloud compatible and requires the JRE on the remote device.
ruleID: spring-boot-to-azure-java-fx-01000
when:
java.referenced:
Expand Down
Loading

0 comments on commit d930baf

Please sign in to comment.