Plugfy: A Java byte code compatibility analyser
Plugfy checks whether all dependencies of an extension are met. It pays special attention to method signatures and can detect incompatible byte code changes even if they are compatible at the source code level.
- Java dependency checker
- Signature compatibility of called methods
- Spring bean dependency checker
Commandline ExamplePlugfy can be used on the command line:
java -cp plugfy.jar;baseclasspath net.sf.plugfy.verifier.Main plugin.jarPlugfy will check that the dependencies of plugin.jar are met in the base classpath.
Code ExamplePlugfy can be embedded into your application to check plugins before they are loaded:
URL url = new File("plugin.jar").toURI().toURL(); VerificationContext context = new VerificationContext(null, this.getClass().getClassLoader(), url); new JarVerifier().verify(url, context); System.out.println(context.getResult());For simplicity, this example just prints the results to the console. The result is a list of Violation objects, that can be easily processed in your code.
Download & change log
- Fix verification of spring configurations located in a directory structure and not in a jar
- Added missing close of opened streams during Spring verification
- Fix recursion of directory structures
- Fix naming of classes while traversing a directory structure
- Verification of directory structures fixed
- Verification of directory structures added
- Close the checked file on Java 7