Closed zqq90 closed 10 years ago
I get this error while try to integrate beetl into jodd-madvoc. now, i fix it by overloading the method configure(MadvocConfigurator configurator) in WebApplication like this :
public void configure(MadvocConfigurator configurator) {
AutomagicMadvocConfigurator auto = (AutomagicMadvocConfigurator)configurator;
auto.setExcludedJars("**/beetl.1.25.03.jar");
super.configure(configurator);
}
You can do as @javamonkey correctly said - to ignore problematic jars (btw, a suggestion: you can use "**/beetl*.jar"
pattern to make your code independent from the jar version:). Even better: to include jars only from your app, as that would speedup startup time.
Moreover, there is an option in ClassFinder
(i.e. in AutomagicMadvocConfigurator
): ignoreExceptions
. By default it is set to false
, but if you set it to true
, your exceptions should be ignored, as you asked for.
Please let me know if that helped!
Yes, ignoreExceptions
is just what i wanted.
webit-script
put all mvc-support(s) in one jar, including Jodd-Madvoc, SpringMVC, Struts2, JFinal, so, excludedJars=**/webit-script**.jar
shouldn't been use.
For some catechumen this will be a big trouble for them to try Jodd Madvoc + Webit Script
, so, I have renamed ..struts.WebitScriptResult
to ..struts.WebitScriptResultSupport
.
Thinks for your answer,@jodder,@javamonkey.
You are right, for webit-script
where you have all in one jar you can also use: excludedEntries
and includedEntries
instead of jars. This way you can scan only your classes, so that may be also a solution :)
I will leave this issue open not to forget to better document it.
For example, my project has a support named
webit.script.support.struts.WebitScriptResult
for struts2AutomagicMadvocConfigurator
will find and try to load it, unfortunately, it throws an errornow we can avoid this problem:
however, this will be simpler and better if there has a flag to ignore
NoClassDefFoundError
or not.