Directory

Minifinder Maven Plug-In - Vaadin Add-on Directory

Vaadin Minifinder Maven Plug-In Minifinder Maven Plug-In - Vaadin Add-on Directory
Utility to generate a summarized report for V8 Upgrade Automation Minifinder Maven Plug-In can check in advance how well your applications can be transformed into the latest Vaadin version were you to use V8 Upgrade Automation -- a Vaadin semi-automated modernization service. Minifinder works by parsing your project’s Java code, resolving as many of your application’s references to Vaadin libraries as it can, and outputting the high-level results to the console. You can then copy the report it generates to share with others to discuss. This allows you to make an informed decision as to whether to proceed with V8 Upgrade Automation. ## Limitations To satisfy organizations with strict security policies on installing tools in their network, Minifinder is limited as follows: * It doesn’t change your code. * It writes all output to the console, not the disk. ## Requirements * JDK 17: Your JAVA_HOME for Maven must be JDK 17 or later.
**It is not necessary to change your actual project's target Java runtime, whether it is below JDK 17 or not.** * Maven 3.9.3, or later. ## Usage Include Vaadin addons repository as Maven plugin repository: ``` vaadin-addons https://maven.vaadin.com/vaadin-addons ``` Add Minifinder as a plugin: ``` com.vaadin.addons.modernization minifinder-maven-plugin 1.4.6 . . . ``` If your project have test classes and have dependencies with **test** scope, change those dependencies to **provided** in order to calculate the coverage for Vaadin components in test classes. Otherwise those dependencies will not be added to classpath in type resolution and coverage results will not be accurate. Check your JAVA_HOME points to a JDK 17 or later and Maven 3.9.3 or later, If your project requires older Java and Maven versions, see the next section. ``` mvn -v ``` ``` Apache Maven 3.9.3 (21122926829f1ead511c958d89bd2f672198ae9f) Maven home: C:\dev\mvn\apache-maven-3.9.3 Java version: 17.0.8, vendor: Oracle Corporation, runtime: C:\dev\jdks\jdk-17.0.8 ``` Before running Minifinder, make sure your project is compiled without any compile errors. Minifinder requires compiled classes in order to resolve type dependencies. ``` mvn clean install ``` Run: ``` mvn minifinder:minifinder ``` ### If your projects require older Java and Maven versions Compiling projects and running Minifinder are two seperate processes. You can compile projects with older Java and Maven versions, and then run Minifinder with new Java and Maven versions. 1. Download JDK 17 and extract it to a suitable directory. [https://jdk.java.net/archive/](https://jdk.java.net/archive/) 2. Download maven 3.9.3 (or newer) and extract it to a suitable directory. [https://maven.apache.org/download.cgi](https://maven.apache.org/download.cgi) Alternatively, you can use Maven wrapper: `mvn wrapper:wrapper -Dmaven=3.9.5` 3. Switch to new maven directory. 4. In your current terminal, set JAVA_HOME:
Mac/Linux: `export JAVA_HOME=/home/deb/jdk-17.0.2`
Windows: `set JAVA_HOME=C:/users/deb/jdk-17.0.2` 5. Make sure that the project is already compiled with older JDK before running Minifinder 6. Run: `mvn minifinder:minifinder` When execution completes, you will see the summarized report in Maven output.