Re: redefining existing levels?

2015-08-26 Thread Xen
Op 26-8-2015 om 5:43 schreef Gary Gregory: On Tue, Aug 25, 2015 at 7:59 PM, Remko Popma wrote: How are users currently able to set the log level to OFF? Do they modify the config? Right, isn't the only way to enforce this is to override the config file programatically? Gary And are you no

Re: redefining existing levels?

2015-08-26 Thread Xen
I think it is still unclear what you mean by "below". Normally I would consider "trace" to be at the low end and "fatal" to be at the high end, but I don't think there is a low and high in Log4J. When you say "below" I take it you mean DEBUG and TRACE, but the only thing that makes sense to me

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
Thank you, it seems everything is so flexible that in the end it might not even matter? As long as you are willing to use the slf4j bridge / abstraction for example ?. ?. Right. Op 14-8-2015 om 22:06 schreef Douglas Wegscheid: No I meant my thing might need to run on older platforms. E.g. I

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
No I meant my thing might need to run on older platforms. E.g. I might want to run it on shell hosts or general cheap places, or interest other people in running it. People are sometimes... idiosynchratic. I had (and have) a Debian based shell host that ran Java 1.5 after which they got rid of

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
Op 14-8-2015 om 19:10 schreef Douglas Wegscheid: That's clearly a lie. You wouldn't say these things if you were really happy and really convinced it'd be a replacement. That is make believe. In that case you'd say something like easy there. that's pretty harsh treatment of other list participa

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
It's hard to argue with that. Maybe there is a flaw in my mind ;-). I just take the long-term perspective. I couldn't for the life of me write differently because it would F with my Mind. I have trouble as it is staying sane. Doing exactly what I want to do seems to be the best way to avoid th

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
e on making them shorter and more to the point (same functionality in fewer lines of code is better, no)? On Sat, Aug 15, 2015 at 1:17 AM, Xen wrote: In response to Jinhong Lu: "but all my projects, including spark, hadoop, kafka, they all use log4j1.x " I came across a proje

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
d hesitatingly is a wrong note. A wrong note played with conviction is interpretation." On Fri, Aug 14, 2015 at 12:15 PM, Xen wrote: Then why do you need to persuade people? Why are they unwilling? Obviously they stand to lose something or they would 'comply' of their own. ;-). Seriously

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
In response to Jinhong Lu: "but all my projects, including spark, hadoop, kafka, they all use log4j1.x " I came across a project as well, it was /TeamPostgreSQL, /using 1.2 or whatever, it is the only jar on its classpath. I must say though: "We are so happy with the quality and stabili

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
015 om 16:19 schreef Mikael Ståldal: I don't agree with you that Log4j 2 is worse than Log4j 1. Log4j 2 is a huge improvement. On Fri, Aug 14, 2015 at 4:05 PM, Xen wrote: That is precisely the sort of stuff you get when your application or newer version is actually worse than your older versio

Re: java.lang.NoSuchFieldError: errorHandler

2015-08-14 Thread Xen
That is precisely the sort of stuff you get when your application or newer version is actually worse than your older version, and now you need to do effort to "persuade" others in joining you when you have not really improved things ;-). I was writing some longer email I guess, I will send it

Re: Multi thread initialization problem

2015-08-13 Thread Xen
Op 13-8-2015 om 20:39 schreef Gary Gregory: Where? Why? Gary Ha, do you need to know? I am often very critical and I also don't hold my mouth when they tell me to. I feel like many people in OSS treat you very badly and I speak out about that. If someone is acting like an asshole I say so. M

Re: Multi thread initialization problem

2015-08-13 Thread Xen
ara because I've been banned on so many places :D ;-). Regards. Op 13-8-2015 om 13:58 schreef Ralph Goers: We are seeing your emails. The users list is just generally pretty quiet. Go ahead and create a Jira and attach something that will reproduce the problem. Ralph On Aug 13, 2

re: Multi thread initialization problem

2015-08-13 Thread Xen
I get the same result from your code. Only thread-2 outputs something, thread-1 comes before but the call comes up empty.: write thread-1 done thread-1 write thread-2 [TEST] [INFO ] thread-2 - message done thread-2 Any call to LogManager makes it succeed: LogManager.getContext(false); th1.star

Re: my results thus far

2015-08-12 Thread Xen
f parameters. Ralph On Aug 11, 2015, at 2:27 PM, Xen wrote: Op 11-8-2015 om 21:07 schreef Gary Gregory: Some appenders use the builder patten, for example org.apache.logging.log4j.core.appender.ConsoleAppender.Builder. I'm not sure why this appender has both a builder and a create metho

Re: my results thus far

2015-08-11 Thread Xen
Op 11-8-2015 om 21:07 schreef Gary Gregory: Some appenders use the builder patten, for example org.apache.logging.log4j.core.appender.ConsoleAppender.Builder. I'm not sure why this appender has both a builder and a create method. Does anyone? Gary Builders are nice, I guess. I don't really l

my results thus far

2015-08-11 Thread Xen
Hi, I just wanted to give a little back of what I've been doing. I can say programmatic configuration the way it is is *really* hard. Mostly it is hard because of - having to import a million different things from different packages, and you can never guess or remember which package it is goin

Re: programmatic config (not working)

2015-08-10 Thread Xen
I was not speaking of LoggerConfig.getLoggers(). There are two methods that I referenced: Configuration.getLoggers() returns a Map of LoggerContext.getLoggers() returns a Collection of Logger. --- Maybe You meant LoggerContext.getLoggers(). However, when I do it after I have obta

programmatic config (not working)

2015-08-10 Thread Xen
Hi again. So. I managed to get a new ConfigurationFactory running (just so as to avoid the ERROR level message given by the StatusLogger when no config file is found) that returns a DefaultConfiguration() for now. I happened to have overriden the wrong method. "getConfiguration(Configuration

Re: dynamic configuration

2015-08-10 Thread Xen
wanted answered in there? Ralph On Aug 9, 2015, at 6:05 AM, Xen wrote: I have a JIRA account now. At least, I hope I will have one for long, I am thinking of cancelling my main account (email) for a short while to start over with a clean slate. Including its domain ;-). Might get a lot of bou

Re: dynamic configuration

2015-08-09 Thread Xen
se. Without a Jira ticket we can't do that. Ralph On Aug 9, 2015, at 2:28 AM, Gary Gregory wrote: Patch applied. TY. In the future, please create a JIRA for patches. Keep them coming :-) Cheers, Gary On Sun, Aug 9, 2015 at 1:11 AM, Xen wrote: I've seen the commit. I will check it ou

Re: dynamic configuration

2015-08-09 Thread Xen
alled * last if no configuration has been returned. */ "I will check it out." Now isn't that ambiguous :P. Regards.. Quoting Gary Gregory : Pushed to Git master. Xen: Please see the setLevel methods in Configurator. Gary On Sat, Aug 8, 2015 at 4:24 PM, Gary Gregory wro

Re: dynamic configuration

2015-08-08 Thread Xen
dding a new LoggerConfig, cannot be done safely to the current configuration, and so the only way to do that is to create a new Configuration. Of course that isn’t as simple as it was with Log4j 1, but it also avoids a whole pile of threading issues. Ralph On Aug 8, 2015, at 9:51 AM,

Re: dynamic configuration

2015-08-08 Thread Xen
Heh, it seems more like you went out of your way to close off a configuration method on purpose that you would know would still be in high demand by a lot of people. The choice to have only configuration per external file would definitely have raised a lot of eyebrows. And I bet, still does

Re: dynamic configuration

2015-08-07 Thread Xen
Quoting Ralph Goers : To achieve what you want just get the LoggerConfig you want to modify, change its level and then call the updateLoggers() method of the LoggerContext. I'm sorry. Maybe this seems lazy or unwarranted, but... The only quick resource I could find was StackOverflow. And I

dynamic configuration

2015-08-06 Thread Xen
Hey, I just read the manual at https://logging.apache.org/log4j/2.0/log4j-users-guide.pdf. A reasonably good manual I must say, compared to some products out there. It doesn't really mention the public API though, only sparsely throughout the examples. I skipped through the remainder of t