Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Ralph Goers
I'm confused. I thought the changes made to use an annotation processor at compile time meant that the plugins.dat file would be generated then, so the file should be available on the classpath. Unless, of course, Eclipse is not actually using maven to compile. To be honest I have no idea if

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
But isn't that the trade off that was made with the plugin mechanism? Log4j2 will search for plugins in plugins.dat or in configured packages, but for performance reasons it won't search the entire classpath. The plugins.dat file is generated automatically during the build, so when run from t

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Gary Gregory
Updating all configuration files to fix IDE development seems wrong. It feels like we have a bug in our test infrastructure.  Gary Original message From: Remko Popma Date:05/31/2014 21:40 (GMT-05:00) To: Log4J Developers List Subject: Re: NPE in RandomAccessFileAppenderTe

Re: PluginAttribute#defaultEnum()?

2014-05-31 Thread Ralph Goers
1. That isn't consistent. 2. If someone wanted to set the default value of a Log4j component via a system property it wouldn't work. That said, I'm not sure how great a benefit that actually is. To be honest, I think I actually would prefer @PluginAttribute("foo") @IntParameterDefault(1) int fo

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
Specifying "packages" in config will work in both maven and Eclipse, I think (unless I'm missing something). Sent from my iPhone > On 2014/06/01, at 8:33, Gary Gregory wrote: > > No, but the test should run from Eclipse and Maven just the same. So... now > what? > > Gary > > >> On Sat, May

Re: PluginAttribute#defaultEnum()?

2014-05-31 Thread Gary Gregory
Well if you do not want strong typing, use a String for foo. Right? Gary Original message From: Ralph Goers Date:05/31/2014 20:38 (GMT-05:00) To: Log4J Developers List Subject: Re: PluginAttribute#defaultEnum()? Gary, I know you said you didn't like @PluginAttribute(na

Re: PluginAttribute#defaultEnum()?

2014-05-31 Thread Ralph Goers
Gary, I know you said you didn't like @PluginAttribute(name="foo", defaultValue="1") int foo But after looking at http://maven.apache.org/plugin-tools/maven-plugin-annotations/apidocs/org/apache/maven/plugins/annotations/Parameter.html I am wondering if that isn't the best way to go. Doing tha

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Gary Gregory
No, but the test should run from Eclipse and Maven just the same. So... now what? Gary On Sat, May 31, 2014 at 7:16 PM, Remko Popma wrote: > Have you tried specifying "packages" in the config file of the test? Then > no plugins.dat is necessary. > > Sent from my iPhone > > On 2014/06/01, at 2:

Re: PluginAttribute#defaultEnum()?

2014-05-31 Thread Ralph Goers
Why wouldn't you do @PluginAttributeInt(value="foo", defaultValue=1) int foo ? That said, I'm really not crazy about this. I wish you could do @PluginAttribute(value="foo", defaultValue=1) int foo Ralph Sent from my iPad > On May 31, 2014, at 12:50 PM, Gary Gregory wrote: > > So the bummer

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
Have you tried specifying "packages" in the config file of the test? Then no plugins.dat is necessary. Sent from my iPhone > On 2014/06/01, at 2:44, Gary Gregory wrote: > > So Eclipse cannot find the plugin dat file then? > > Adding the jar is not going to help if what I am doing is developi

Re: PluginAttribute#defaultEnum()?

2014-05-31 Thread Gary Gregory
So the bummer is that this redundant with the arg type in the signature: @PluginAttributeInt (value="foo", defaultInt=1) int foo We should also pick up the attribute name by reflection if it is missing from the annotation. But you'd only need it to spec a default value.  So could we keep Plugi

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Gary Gregory
So Eclipse cannot find the plugin dat file then? Adding the jar is not going to help if what I am doing is developing plugins... :-( I think there is some odd ball case where Maven copies the plugin dat file some place and then you do a refresh in Eclipse to pick it up. I've not found a reliable

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
I see the NullPointerException also when I run the test in Eclipse. If I revert back to the previous version of RandomAccessFileAppenderTest (before conversion to RuleChains) I don't see these NPEs. (However in the previous version the test still fails: [0], [1] and [3] cannot find the resulting

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Gary Gregory
I said from eclipse: right click on the class, run as, junit test. Gary Original message From: Remko Popma Date:05/31/2014 09:30 (GMT-05:00) To: Log4J Developers List Subject: Re: NPE in RandomAccessFileAppenderTests I just updated and ran mvn eclipse package and I did no

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
I just updated and ran mvn eclipse package and I did not have any issues. Build success. On Sat, May 31, 2014 at 4:37 PM, Remko Popma wrote: > I'll take a look later today. > > Sent from my iPhone > > On 2014/05/31, at 15:40, Gary Gregory wrote: > > When I run RandomAccessFileAppenderTests fro

Re: NPE in RandomAccessFileAppenderTests

2014-05-31 Thread Remko Popma
I'll take a look later today. Sent from my iPhone > On 2014/05/31, at 15:40, Gary Gregory wrote: > > When I run RandomAccessFileAppenderTests from Eclipse, I get an NPE. > > Does anyone else see this? > > Thank you, > Gary > > -- > E-Mail: [email protected] | [email protected] > Ja