|
1097 | 1097 | kind: Property |
1098 | 1098 | name: Configuration |
1099 | 1099 | package: io.konveyor.demo.ordermanagement.config |
1100 | | - - uri: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/config/WebConfig.java |
1101 | | - message: Annotation inspection 05 |
1102 | | - codeSnip: "\ 1 package io.konveyor.demo.ordermanagement.config;\n 2 \n 3 import org.springframework.boot.autoconfigure.EnableAutoConfiguration;\n 4 import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;\n 5 import org.springframework.context.annotation.Configuration;\n 6 \n 7 @Configuration\n 8 @EnableAutoConfiguration(exclude = { DataSourceAutoConfiguration.class })\n 9 public class WebConfig {\n10 \n11 }\n" |
1103 | | - lineNumber: 7 |
1104 | | - variables: |
1105 | | - file: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/config/WebConfig.java |
1106 | | - kind: Property |
1107 | | - name: Configuration |
1108 | | - package: io.konveyor.demo.ordermanagement.config |
1109 | 1100 | java-chaining-01: |
1110 | 1101 | description: There should only be one instance of this rule |
1111 | 1102 | category: mandatory |
1112 | 1103 | incidents: |
1113 | | - - uri: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/OrderManagementAppInitializer.java |
1114 | | - message: | |
1115 | | - Sample message. This rule checks that the chaining conditions are working. Should only get a single issue. |
1116 | | - codeSnip: " 3 import javax.servlet.ServletContext;\n 4 import javax.servlet.ServletException;\n 5 import javax.servlet.ServletRegistration;\n 6 \n 7 import org.springframework.web.WebApplicationInitializer;\n 8 import org.springframework.web.context.ContextLoaderListener;\n 9 import org.springframework.web.context.support.AnnotationConfigWebApplicationContext;\n10 import org.springframework.web.servlet.DispatcherServlet;\n11 \n12 \n13 public class OrderManagementAppInitializer implements WebApplicationInitializer {\n14 \n15 \t@Override\n16 \tpublic void onStartup(ServletContext container) throws ServletException {\n17 \t\tAnnotationConfigWebApplicationContext context = new AnnotationConfigWebApplicationContext();\n18 context.setConfigLocation(\"io.konveyor.demo.ordermanagement.config\");\n19 \n20 context.scan(\"io.konveyor.demo.ordermanagement\");\n21 container.addListener(new ContextLoaderListener(context));\n22 \n23 ServletRegistration.Dynamic dispatcher = container" |
1117 | | - lineNumber: 13 |
1118 | | - variables: |
1119 | | - file: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/OrderManagementAppInitializer.java |
1120 | | - kind: Class |
1121 | | - name: OrderManagementAppInitializer |
1122 | | - package: io.konveyor.demo.ordermanagement |
| 1104 | + - uri: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/OrderManagementAppInitializer.java |
| 1105 | + message: | |
| 1106 | + Sample message. This rule checks that the chaining conditions are working. Should only get a single issue. |
| 1107 | + codeSnip: " 3 import javax.servlet.ServletContext;\n 4 import javax.servlet.ServletException;\n 5 import javax.servlet.ServletRegistration;\n 6 \n 7 import org.springframework.web.WebApplicationInitializer;\n 8 import org.springframework.web.context.ContextLoaderListener;\n 9 import org.springframework.web.context.support.AnnotationConfigWebApplicationContext;\n10 import org.springframework.web.servlet.DispatcherServlet;\n11 \n12 \n13 public class OrderManagementAppInitializer implements WebApplicationInitializer {\n14 \n15 \t@Override\n16 \tpublic void onStartup(ServletContext container) throws ServletException {\n17 \t\tAnnotationConfigWebApplicationContext context = new AnnotationConfigWebApplicationContext();\n18 context.setConfigLocation(\"io.konveyor.demo.ordermanagement.config\");\n19 \n20 context.scan(\"io.konveyor.demo.ordermanagement\");\n21 container.addListener(new ContextLoaderListener(context));\n22 \n23 ServletRegistration.Dynamic dispatcher = container" |
| 1108 | + lineNumber: 13 |
| 1109 | + variables: |
| 1110 | + file: file:///examples/customers-tomcat-legacy/src/main/java/io/konveyor/demo/ordermanagement/OrderManagementAppInitializer.java |
| 1111 | + kind: Class |
| 1112 | + name: OrderManagementAppInitializer |
| 1113 | + package: io.konveyor.demo.ordermanagement |
1123 | 1114 | java-downloaded-maven-artifact: |
1124 | 1115 | description: | |
1125 | 1116 | This rule tests the application downloaded from maven artifact |
|
0 commit comments