diff options
author | Cesar Andres <cesar.vera-bernal@lucidworks.com> | 2017-10-21 15:52:17 -0500 |
---|---|---|
committer | Decebal Suiu <decebal.suiu@gmail.com> | 2017-10-21 23:52:17 +0300 |
commit | 468abf3490028bbce5cf748d76cc22b73dab2d15 (patch) | |
tree | 47c6695bf579388858c789f7d71741247bf4cc18 /demo_gradle/app/src | |
parent | 42aaee15591e241add08323c76f4f813867f996b (diff) | |
download | pf4j-468abf3490028bbce5cf748d76cc22b73dab2d15.tar.gz pf4j-468abf3490028bbce5cf748d76cc22b73dab2d15.zip |
ISSUE-169: fix gradle demo (#177)
Diffstat (limited to 'demo_gradle/app/src')
-rw-r--r-- | demo_gradle/app/src/main/java/org/pf4j/demo/Boot.java | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/demo_gradle/app/src/main/java/org/pf4j/demo/Boot.java b/demo_gradle/app/src/main/java/org/pf4j/demo/Boot.java index 46261d6..9343f4a 100644 --- a/demo_gradle/app/src/main/java/org/pf4j/demo/Boot.java +++ b/demo_gradle/app/src/main/java/org/pf4j/demo/Boot.java @@ -16,6 +16,9 @@ package org.pf4j.demo; import org.apache.commons.lang3.StringUtils; +import org.pf4j.CompoundPluginDescriptorFinder; +import org.pf4j.ManifestPluginDescriptorFinder; +import org.pf4j.PropertiesPluginDescriptorFinder; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.pf4j.DefaultPluginManager; @@ -38,7 +41,16 @@ public class Boot { printLogo(); // create the plugin manager - final PluginManager pluginManager = new DefaultPluginManager(); + final PluginManager pluginManager = new DefaultPluginManager() { + @Override + protected CompoundPluginDescriptorFinder createPluginDescriptorFinder() { + return new CompoundPluginDescriptorFinder() + // Demo is using the Manifest file + // PropertiesPluginDescriptorFinder is commented out just to avoid error log + //.add(new PropertiesPluginDescriptorFinder()) + .add(new ManifestPluginDescriptorFinder()); + } + }; // load the plugins pluginManager.loadPlugins(); |