PluginAttribute choice

2014-06-01 Thread Gary Gregory
How do I tell my plugin that it can have attribute1 or 2, but not both? IOW I want the config framework to do the validation for me. How about: @PluginAttribute(choice="group1") int foo, @PluginAttribute(choice="group1") int bar Same thing for elements. Thoughts? Gary -- E-Mail: garydgreg..

Config clean up for AppenderRef

2014-06-01 Thread Gary Gregory
In the following: ${pattern} ... I propose to change: to: It seems easier to read and connect these dots: Thoughts? Gary -- E-Mail: [email protected] | [email protected] Java Persistence with Hibernate, Second Edition

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Matt Sicker
The reason why there's two ways to do it right now is because I was looking for feedback to see if we'd like to use builders instead. If so, we can go ahead and continue porting things (I've been working on that) to switch over to builders instead and get rid of the factory methods. The visitor st

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Ralph Goers
With regard to the default values, I believe the factory methods used to handle that by checking for a null String being passed. Even after switching to types this could have been handled similarly by using objects instead of primitives. Yes, that is not as automated but neither is what you have

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Ralph Goers
Yes I see it now. I’ve got to say that the code now sure looks a lot more complicated then before you started cleaning it up. You don’t happen to work for the IRS on tax code simplification do you? ;-) Seriously, i don’t mind separating the plugin building to a separate class, but the builders

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Matt Sicker
It's mostly concentrated in the PluginBuilder class. And in PluginBuilder, the strategy used for each annotation is determined by that annotation's annotation which specifies a PluginVisitor class. A plugin class is still scanned for a static method annotated with @PluginFactory, but it's also sca

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Ralph Goers
I have to admit I no longer have a clue how the plugins are created. The javadoc in AbstractConfiguration still talks about the original annotations but i’m not really sure where the code that constructs the factory or builder parameter lists moved to. can you provide a little help? Ralph On

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Matt Sicker
Alright, I've committed what I was talking about before in regard to builder classes and fields. The new @PluginBuilderAttribute annotation could be extended to allow using a setter method as well, but I think it's fine for now to just use fields. Anyway, using this idea, there's no longer a need

Re: NPE in RandomAccessFileAppenderTests

2014-06-01 Thread Matt Sicker
Annotation processing is a standard feature of the JDK compiler. I don't know about Eclipse's compiler, but I'd imagine that should support them, too. On 1 June 2014 08:12, Gary Gregory wrote: > Or have eclipse call our annotation processor on demand or on a compile... > There must be a way to

Re: PluginAttribute#defaultEnum()?

2014-06-01 Thread Gary Gregory
On Sat, May 31, 2014 at 9:48 PM, Ralph Goers wrote: > 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

Re: NPE in RandomAccessFileAppenderTests

2014-06-01 Thread Gary Gregory
Or have eclipse call our annotation processor on demand or on a compile... There must be a way to do that... Gary Original message From: Remko Popma Date:06/01/2014 03:00 (GMT-05:00) To: Log4J Developers List Subject: Re: NPE in RandomAccessFileAppenderTests I've just se

[jira] [Commented] (LOG4J2-461) ERROR StatusLogger Unable to locate a logging implementation, using SimpleLogger

2014-06-01 Thread Abid (JIRA)
[ https://issues.apache.org/jira/browse/LOG4J2-461?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14014963#comment-14014963 ] Abid commented on LOG4J2-461: - Sorry for the delay Ralph...was on vacation... I will test it s

Bug report for Log4j [2014/06/01]

2014-06-01 Thread bugzilla
+---+ | Bugzilla Bug ID | | +-+ | | Status: UNC=Unconfirmed NEW=New ASS=Assigned

Re: NPE in RandomAccessFileAppenderTests

2014-06-01 Thread Remko Popma
I've just set up a recent version of Eclipse and if you make a project a Maven project it is possible to run the Maven build from Eclipse. I haven't explored this in depth yet. By default Eclipse just compiles the modified classes when you save them and does not run a full build, maven or otherwise