[JBoss JIRA] Created: (JBAS-5300) ClassLoader leaks in TimedCachePolicy through JAAS Auth Cache
by Arto Huusko (JIRA)
ClassLoader leaks in TimedCachePolicy through JAAS Auth Cache
-------------------------------------------------------------
Key: JBAS-5300
URL: http://jira.jboss.com/jira/browse/JBAS-5300
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: ClassLoading
Affects Versions: JBossAS-4.2.1.GA
Environment: JDK 1.6.0_04
Reporter: Arto Huusko
Assigned To: Scott M Stark
JAAS authentication cache is responsible for two classloader leaks through org.jboss.utils.TimedCachePolicy, causing classes of undeployed applications not be unloaded. The second is not a huge problem, but still real, and is related to JBAS-3986.
First problem is the creation of resolutionTimer. If TimedCachePolicy is used for the first time when my web application is accessed, the resolutionTimer object is created in the context of the web app, and the timer thread attached to the timer inherits the current context class loader, that is my web app's class loader. This results in a permanent reference to that class loader, and it can never be unloaded.
The second problem is the fact that the expired entries are purged from the cache only when they are accessed. If some credentials are once used, and then never used again, they remain in the cache, and these cached LoginContexts contain references to the web app class loaders.
First problem is fixable by temporarily changing current thread context class loader when first creating the resolutionTimer.
The second problem could be fixed by JBoss automatically flushing the authentication cache when the web app is undeployed.
--
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
17 years, 3 months
[JBoss JIRA] Created: (JBCOMMON-63) JDK to Log4j/JBoss logging handler
by Galder Zamarreno (JIRA)
JDK to Log4j/JBoss logging handler
----------------------------------
Key: JBCOMMON-63
URL: https://jira.jboss.org/jira/browse/JBCOMMON-63
Project: JBoss Common
Issue Type: Feature Request
Security Level: Public (Everyone can see)
Components: common-logging-jdk, common-logging-log4j
Reporter: Galder Zamarreno
Attachments: logging-jbcommon.zip
Certain 3rd party libraries log using JDK logging and customers want to
see these applications logging to where JBoss logs. We should provide
a JDK logging handler than logs using log4j or JBoss logging API. Please
find attached a handler I created to log to log4j. Creating a handler for log4j
was easier than creating one for JBoss logging because of the presence
of Logger.log(Level, String...) API in log4j.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
17 years, 3 months
[JBoss JIRA] Created: (JBCOMMON-50) TimedCachePolicy leaks classloader to timer thread
by Brian Stansberry (JIRA)
TimedCachePolicy leaks classloader to timer thread
--------------------------------------------------
Key: JBCOMMON-50
URL: http://jira.jboss.com/jira/browse/JBCOMMON-50
Project: JBoss Common
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: common-core
Affects Versions: 2.2.5.beta1, 2.2.4.GA
Reporter: Brian Stansberry
TimedCachePolicy has a static reference to a Timer, restartTimer. A timer creates a new thread when it is initialized; the thread inherits its TCCL from the TCCL of the thread that initializes it. Effect is that TCCL leaks to the restartTimer's thread.
Not sure the best solution here, since common-core is a general use library. In general I think the right solution is to set the TCCL to a "safe" classloader before creating the Timer, and restore the TCCL afterwards. But what is a "safe" classloader? If you use TimedCachePolicy.class.getClassLoader(), then that classloader is leaked. That's fine in JBoss AS, but may be bad in other use cases. Perhaps null or system classloader is the right choice; I don't know enough about how this class is used to have a good idea if the TimerTasks being used (seems to only be RestartTimer) need to load classes.
--
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
17 years, 3 months
[JBoss JIRA] Created: (JASSIST-62) make $type available in insertBefore
by Yanic Inghelbrecht (JIRA)
make $type available in insertBefore
------------------------------------
Key: JASSIST-62
URL: http://jira.jboss.com/jira/browse/JASSIST-62
Project: Javassist
Issue Type: Feature Request
Environment: javassist 3.7.1 (latest from cvs HEAD)
Reporter: Yanic Inghelbrecht
Assigned To: Shigeru Chiba
The tutorial explicitly mentions that $type is not available in CtMethod#insertBefore, which is why I did not file this as a bug.
The problem is that it is impossible to determine the return type without support from javassist, since there can be multiple methods in the same class with the same name and parameter types but different return types (because of bridge methods to support covariant return types).
The return type is to distinguish between the bridge methods and the originals. Again, this is for a tool that performs run-time analysis of execution events, so it is important it can accurately distinguish between method(calls). Currently the tool lumps together the originals and bridges for lack of information, which is incorrect. So for me this is a high priority bug / rfe.
A quick response as to whether or not this request is deemed feasible would be appreciated - even if the implementation will take a while.
Thanks in advance.
Best regards,
Yanic
--
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
17 years, 3 months
[JBoss JIRA] Created: (JBRULES-1632) DSL expander can't add a field constraint to a fact when a previous field constraint has parentheses
by Pierre De Swert (JIRA)
DSL expander can't add a field constraint to a fact when a previous field constraint has parentheses
----------------------------------------------------------------------------------------------------
Key: JBRULES-1632
URL: http://jira.jboss.com/jira/browse/JBRULES-1632
Project: JBoss Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Drl Parser/Builder
Affects Versions: 4.0.7
Reporter: Pierre De Swert
Assigned To: Mark Proctor
I have made a little example to reproduce the problem.
Let us assume we have a very simple Wine class...
public class Wine {
private int age;
private String type;
private String country;
private String vineyard;
....
I define the following in my DSL:
[condition][]Il existe un vin "{i}"={i} : Wine()
[condition][]- plus vieux que "{y}"=age > {y}
[condition][]- du crû "{c}"=vineyard == "{c}"
In the following rule, I can't add the last field constraint when the age of the prvious one is
"($y + 10)"
rule "Very Old Wine"
when
#conditions
# there is a wine 10 years older than a person
> Person($y : age)
Il existe un vin "$v"
- plus vieux que "($y + 10)"
# - plus vieux que "$y"
- du crû "Nuits-Saint-Georges"
then
#actions
End
--
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
17 years, 3 months