<?xml version="1.0"?>
<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">
-
+
<parent>
<groupId>ro.fortsoft.pf4j.demo</groupId>
<artifactId>pf4j-demo-parent</artifactId>
<properties>
<main.class>ro.fortsoft.pf4j.demo.Boot</main.class>
- <slf4j.version>1.6.4</slf4j.version>
+ <slf4j.version>1.7.5</slf4j.version>
</properties>
-
+
<build>
- <plugins>
+ <plugins>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.3</version>
</execution>
</executions>
</plugin>
-
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
</archive>
</configuration>
</plugin>
-
+
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
<configuration>
<groupId>ro.fortsoft.pf4j</groupId>
<artifactId>pf4j</artifactId>
<version>${project.version}</version>
- </dependency>
+ </dependency>
<dependency>
<groupId>ro.fortsoft.pf4j.demo</groupId>
<artifactId>pf4j-demo-api</artifactId>
<version>${project.version}</version>
- </dependency>
+ </dependency>
<!-- Logs -->
<dependency>
<dependency>
<groupId>org.slf4j</groupId>
- <artifactId>jul-to-slf4j</artifactId>
+ <artifactId>slf4j-log4j12</artifactId>
<version>${slf4j.version}</version>
</dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
- <version>${slf4j.version}</version>
- </dependency>
-
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<version>2.4</version>
</dependency>
</dependencies>
-
+
</project>
<?xml version="1.0"?>
<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">
-
+
<parent>
<groupId>ro.fortsoft.pf4j</groupId>
<artifactId>pf4j-parent</artifactId>
</plugin>
</plugins>
</build>
-
+
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
- <version>1.6.4</version>
+ <version>1.7.5</version>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.8.1</version>
+ <scope>test</scope>
</dependency>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>4.8.1</version>
- <scope>test</scope>
- </dependency>
</dependencies>
</project>
throw new IllegalArgumentException(String.format("Unknown pluginId %s", pluginId));
}
-
PluginWrapper pluginWrapper = getPlugin(pluginId);
PluginDescriptor pluginDescriptor = pluginWrapper.getDescriptor();
PluginState pluginState = pluginWrapper.getPluginState();
PluginWrapper pluginWrapper = getPlugin(pluginId);
if (!isPluginValid(pluginWrapper)) {
- log.warn("Plugin '{}:{}' can not be enabled",
- pluginWrapper.getPluginId(),
+ log.warn("Plugin '{}:{}' can not be enabled", pluginWrapper.getPluginId(),
pluginWrapper.getDescriptor().getVersion());
return false;
}
return true;
}
- log.warn(String.format("Plugin '%s:%s' requires a minimum system version of %s",
+ log.warn("Plugin '{}:{}' requires a minimum system version of {}",
pluginWrapper.getPluginId(),
pluginWrapper.getDescriptor().getVersion(),
- requires));
+ requires);
+
return false;
}