It _should_ never get an NPE over a missing configuration key. Given
our sparse testing resources it behooves us to make the code as
resilient as possible.
Could you submit a bug report about this (or, even better, a patch) --
ideally it could would *log an error* if the configuration property is
missing and set filternames to some default that may be illogical (i.e.
empty list of plugins) but at least won't blow up.
The error log entry explains the exact problem to the admin, who may not
have known about the new configuration key, but can now tell exactly
what to look for.
See org.dspace.core.PluginManager for an example; it has a lot of protection
against configuration errors because those are to be expected when
plugin configurations get changed at every site.
-- Larry
> I see that it blows up on:
>
> String enabledPlugins =
> ConfigurationManager.getProperty(MEDIA_FILTER_PLUGINS_KEY);
> filterNames = enabledPlugins.split(",\\s*");
>
> But when I check the dspace.cfg file I don't see a
> MEDIA_FILTER_PLUGINS_KEY
>
> Filter-media will need to be run as a cron job in 1.5, right?
>
> Thanks!
> Jose
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Blanco,
> Jose
> Sent: Friday, July 11, 2008 11:14 AM
> To: [email protected]
> Subject: [Dspace-tech] Filter-media in 15
>
> When I run filter-media in 1.5, I'm getting:
>
> -bash-3.2$ ./filter-media
> Applying Media Filters
> Exception in thread "main" java.lang.NullPointerException
> at
> org.dspace.app.mediafilter.MediaFilterManager.main(MediaFilterManager.ja
> va:240)
>
> ------------------------------------------------------------------------
> -
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> DSpace-tech mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
>
> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> DSpace-tech mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech