Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Commit

Permalink
Throw exceptions if unable to instantiate plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
vigyasharma committed Jul 27, 2020
1 parent 1364afd commit c3d4169
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ private void loadFrameworkPlugins() {
plugins.add((Plugin) constructors[0].newInstance());
LOG.info("loaded plugin: [{}]", plugins.get(plugins.size() - 1).name());
} catch (InstantiationException | IllegalAccessException | InvocationTargetException e) {
e.printStackTrace();
LOG.error("Failed to instantiate plugin", e);
throw new IllegalStateException("Failed to instantiate plugin: [" + pluginClass.getName() + "]", e);
}
}
}
Expand Down

0 comments on commit c3d4169

Please sign in to comment.