[JBoss JIRA] Created: (JGRP-457) Optimization: make threads return immediately if NAKACK has another active thread for the same sender
by Bela Ban (JIRA)
Optimization: make threads return immediately if NAKACK has another active thread for the same sender
-----------------------------------------------------------------------------------------------------
Key: JGRP-457
URL: http://jira.jboss.com/jira/browse/JGRP-457
Project: JGroups
Issue Type: Feature Request
Reporter: Bela Ban
Assigned To: Bela Ban
Priority: Minor
Fix For: 2.5
In NAKACK, when a thread places a message for sender S into the NakReceiverWindow NRW, it subsequently acquires a lock on NRW (lock by sender) and removes as many messages as possible and passes them up.
If many threads do this at the same time, all threads but one are blocked, and - when finally unblocked - usually return. This causes context switches and possibly cache flushing, so a better way would be to have the threads check whether another thread is already removing messages using a CAS operation *before* acquiring the lock.
The effect should be that no threads will wait on the lock unnecessarily, and thus fewer context switches, and more threads available to the pool.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
2 days, 11 hours
[JBoss JIRA] (JBLOGGING-94) JBoss Logging does not detect log4j 2.0
by Nicholas Williams (JIRA)
[ https://issues.jboss.org/browse/JBLOGGING-94?page=com.atlassian.jira.plug... ]
Nicholas Williams commented on JBLOGGING-94:
--------------------------------------------
I didn't realize JBoss Logging was on GitHub.
I have submitted a pull request.
> JBoss Logging does not detect log4j 2.0
> ---------------------------------------
>
> Key: JBLOGGING-94
> URL: https://issues.jboss.org/browse/JBLOGGING-94
> Project: JBoss Logging
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: jboss-logging-log4j
> Affects Versions: 3.1.2.GA
> Environment: Hibernate
> Reporter: Henry Clout
> Assignee: James Perkins
>
> The class org.jboss.logging.LoggerProviders checks for the presence of log4j using the code:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.Hierarchy", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> However, despite having the log4j-1.2-api-2.0.jar bridge included, this fails as the class org.apache.log4j.Hierarchy is not present in log4j 2.0.
> I worked around this by forcing JBoss logging to use slf4j (which is then proxied to log4j) by setting the -Dorg.jboss.logging.provider=slf4j option.
> As a proper fix, however, how about checking for a class that is included in log4j 1.2, 2.0 but not slf4j? org.apache.log4j.config.PropertySetter seems to tick the box.
> I tested changing the afore mentioned method to:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.config.PropertySetter", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> And indeed I started receiving logging messages from Hibernate (via JBoss logging.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 4 months
[JBoss JIRA] (JBLOGGING-94) JBoss Logging does not detect log4j 2.0
by James Perkins (JIRA)
[ https://issues.jboss.org/browse/JBLOGGING-94?page=com.atlassian.jira.plug... ]
James Perkins commented on JBLOGGING-94:
----------------------------------------
I have not looked much at log4j2 yet. We don't have much of a road map as JBoss Logging really does change all that much.
A high level overview of it is it's just a logging facade that works with the major log managers.
> JBoss Logging does not detect log4j 2.0
> ---------------------------------------
>
> Key: JBLOGGING-94
> URL: https://issues.jboss.org/browse/JBLOGGING-94
> Project: JBoss Logging
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: jboss-logging-log4j
> Affects Versions: 3.1.2.GA
> Environment: Hibernate
> Reporter: Henry Clout
> Assignee: James Perkins
>
> The class org.jboss.logging.LoggerProviders checks for the presence of log4j using the code:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.Hierarchy", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> However, despite having the log4j-1.2-api-2.0.jar bridge included, this fails as the class org.apache.log4j.Hierarchy is not present in log4j 2.0.
> I worked around this by forcing JBoss logging to use slf4j (which is then proxied to log4j) by setting the -Dorg.jboss.logging.provider=slf4j option.
> As a proper fix, however, how about checking for a class that is included in log4j 1.2, 2.0 but not slf4j? org.apache.log4j.config.PropertySetter seems to tick the box.
> I tested changing the afore mentioned method to:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.config.PropertySetter", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> And indeed I started receiving logging messages from Hibernate (via JBoss logging.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 4 months
[JBoss JIRA] (JBLOGGING-94) JBoss Logging does not detect log4j 2.0
by Nicholas Williams (JIRA)
[ https://issues.jboss.org/browse/JBLOGGING-94?page=com.atlassian.jira.plug... ]
Nicholas Williams commented on JBLOGGING-94:
--------------------------------------------
Actually I see now, while browsing through Maven Central, that 3.1.3.GA was released in March. Why has JIRA not been updated to reflect this? What's the next version going to be?
> JBoss Logging does not detect log4j 2.0
> ---------------------------------------
>
> Key: JBLOGGING-94
> URL: https://issues.jboss.org/browse/JBLOGGING-94
> Project: JBoss Logging
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: jboss-logging-log4j
> Affects Versions: 3.1.2.GA
> Environment: Hibernate
> Reporter: Henry Clout
> Assignee: James Perkins
>
> The class org.jboss.logging.LoggerProviders checks for the presence of log4j using the code:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.Hierarchy", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> However, despite having the log4j-1.2-api-2.0.jar bridge included, this fails as the class org.apache.log4j.Hierarchy is not present in log4j 2.0.
> I worked around this by forcing JBoss logging to use slf4j (which is then proxied to log4j) by setting the -Dorg.jboss.logging.provider=slf4j option.
> As a proper fix, however, how about checking for a class that is included in log4j 1.2, 2.0 but not slf4j? org.apache.log4j.config.PropertySetter seems to tick the box.
> I tested changing the afore mentioned method to:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.config.PropertySetter", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> And indeed I started receiving logging messages from Hibernate (via JBoss logging.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 4 months
[JBoss JIRA] (JBLOGGING-94) JBoss Logging does not detect log4j 2.0
by Nicholas Williams (JIRA)
[ https://issues.jboss.org/browse/JBLOGGING-94?page=com.atlassian.jira.plug... ]
Nicholas Williams edited comment on JBLOGGING-94 at 5/31/13 7:29 PM:
---------------------------------------------------------------------
Can we get an update on this? I'd really like to see this fixed for 3.1.3.
For that matter, what is the roadmap for 3.1.3? It has been almost a year since 3.1.2. It'd be nice to see this fixed and 3.1.3 released soon.
Finally, I don't know much about JBoss logging (other than that it's used by Hibernate and thus my applications use it), but would it make sense to add support in 3.2.0 for Log4j 2? The API is greatly extended, and thus there might be improvements/streamlines that can be made to the JBoss Logging/Log4j integration if Log4j 2 is used.
was (Author: beamerblvd):
Can we get an update on this? I'd really like to see this fixed for 3.1.3.
For that matter, what is the roadmap for 3.1.3? It has been almost a year since 3.1.2. It'd be nice to see this fixed and 3.1.3 released soon.
> JBoss Logging does not detect log4j 2.0
> ---------------------------------------
>
> Key: JBLOGGING-94
> URL: https://issues.jboss.org/browse/JBLOGGING-94
> Project: JBoss Logging
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: jboss-logging-log4j
> Affects Versions: 3.1.2.GA
> Environment: Hibernate
> Reporter: Henry Clout
> Assignee: James Perkins
>
> The class org.jboss.logging.LoggerProviders checks for the presence of log4j using the code:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.Hierarchy", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> However, despite having the log4j-1.2-api-2.0.jar bridge included, this fails as the class org.apache.log4j.Hierarchy is not present in log4j 2.0.
> I worked around this by forcing JBoss logging to use slf4j (which is then proxied to log4j) by setting the -Dorg.jboss.logging.provider=slf4j option.
> As a proper fix, however, how about checking for a class that is included in log4j 1.2, 2.0 but not slf4j? org.apache.log4j.config.PropertySetter seems to tick the box.
> I tested changing the afore mentioned method to:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.config.PropertySetter", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> And indeed I started receiving logging messages from Hibernate (via JBoss logging.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 4 months
[JBoss JIRA] (JBLOGGING-94) JBoss Logging does not detect log4j 2.0
by Nicholas Williams (JIRA)
[ https://issues.jboss.org/browse/JBLOGGING-94?page=com.atlassian.jira.plug... ]
Nicholas Williams commented on JBLOGGING-94:
--------------------------------------------
Can we get an update on this? I'd really like to see this fixed for 3.1.3.
For that matter, what is the roadmap for 3.1.3? It has been almost a year since 3.1.2. It'd be nice to see this fixed and 3.1.3 released soon.
> JBoss Logging does not detect log4j 2.0
> ---------------------------------------
>
> Key: JBLOGGING-94
> URL: https://issues.jboss.org/browse/JBLOGGING-94
> Project: JBoss Logging
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: jboss-logging-log4j
> Affects Versions: 3.1.2.GA
> Environment: Hibernate
> Reporter: Henry Clout
> Assignee: James Perkins
>
> The class org.jboss.logging.LoggerProviders checks for the presence of log4j using the code:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.Hierarchy", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> However, despite having the log4j-1.2-api-2.0.jar bridge included, this fails as the class org.apache.log4j.Hierarchy is not present in log4j 2.0.
> I worked around this by forcing JBoss logging to use slf4j (which is then proxied to log4j) by setting the -Dorg.jboss.logging.provider=slf4j option.
> As a proper fix, however, how about checking for a class that is included in log4j 1.2, 2.0 but not slf4j? org.apache.log4j.config.PropertySetter seems to tick the box.
> I tested changing the afore mentioned method to:
> {code}
> private static LoggerProvider tryLog4j(final ClassLoader cl) throws ClassNotFoundException {
> Class.forName("org.apache.log4j.LogManager", true, cl);
> // JBLOGGING-65 - slf4j can disguise itself as log4j. Test for a class that slf4j doesn't provide.
> Class.forName("org.apache.log4j.config.PropertySetter", true, cl);
> return new Log4jLoggerProvider();
> }
> {code}
> And indeed I started receiving logging messages from Hibernate (via JBoss logging.)
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
12 years, 4 months