[JBoss JIRA] Created: (JBAS-7291) Reduce memory usuage
by Scott Marlow (JIRA)
Reduce memory usuage
--------------------
Key: JBAS-7291
URL: https://jira.jboss.org/jira/browse/JBAS-7291
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Affects Versions: JBossAS-5.2.0.Beta1
Reporter: Scott Marlow
Fix For: JBossAS-6.0.0.Alpha1
This is an umbrella jira for all projects that are part of the application server.
6mb of memory used by 109, 552 instances of org.jboss.logging.Logger (these numbers include objects referenced by the Logger instances)
65.5mb org.jboss.mx.server.MBeanServerImpl
30mb org.jboss.virtual.plugins.context.zip.ZipEntryContext$EntryInfo
Other details to be added
--
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
15 years, 7 months
[JBoss JIRA] Created: (JBRULES-2725) Business Rules may not be handling Java Enums Correctly, DRL Generated does not work and Running Test Scenarios fails
by Daniel Cruver (JIRA)
Business Rules may not be handling Java Enums Correctly, DRL Generated does not work and Running Test Scenarios fails
---------------------------------------------------------------------------------------------------------------------
Key: JBRULES-2725
URL: https://jira.jboss.org/browse/JBRULES-2725
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-guvnor
Affects Versions: 5.1.1.FINAL
Environment: Windows 7 (64 Bit)
Sun JDK 1.6.0 Update 21
Reporter: Daniel Cruver
Assignee: Mark Proctor
I have created POJO Model Jar for importing into Guvnor.
I can create A Business Rule (Guided Editor), it correctly allows me to set enumeration values and it validates correctly.
But when I go to view source:
In the when clause, it shows that it has converted the enumeration of VehicleType.AIR to "0" which is the cardinal value in quotes.
In the then clause, it shows that it has converted the enumeration of VehicleType.AIR to 0 which is the cardinal value as an integer.
Whenever I create a unit test with this rules and define facts I get this error:
Unable to run the scenario.
[Error: could not access/write property (type) in: com.example.model.Vehicle] [Near : {... __fact__.type = __val_ ....}] ^ [Line: 1, Column: 0]
I have taken these generated DRL as given be Guvnor and tried to run them in a test driver.
Using the rules as given it will not activate the rules, I have to replace the "0" and 0 with VehicleType.AIR in order for it to fire the rules.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months
[JBoss JIRA] Created: (JBRULES-2722) Bug in VariablePersistenceStrategy when chosing a Variable Persister
by Nicolas Loriente (JIRA)
Bug in VariablePersistenceStrategy when chosing a Variable Persister
--------------------------------------------------------------------
Key: JBRULES-2722
URL: https://jira.jboss.org/browse/JBRULES-2722
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: All
Affects Versions: 5.1.1.FINAL
Reporter: Nicolas Loriente
Assignee: Mark Proctor
drools-persistence-jpa-5.1.1 has a bug in VariablePersistenceStrategy.
When looking at "interfaces" to find a Variable Persister Drools currently doesn't find the persister for classes that extend a variable persister type.
e.g. java.language.Long which extends Number which implements Serializable. By inheritance Long is a Serializable and shold be persited with SerializableVariablePersister if the persister is registered.
The following block of code is found in the class "org.drools.persistence.processinstance.VariablePersistenceStrategy" in the method "private String getVariablePersistenceType(Object o)":
// at last for interfaces
Class<?>[] interfaces = o.getClass().getInterfaces();
if (interfaces != null) {
for (Class<?> clazz : interfaces) {
persisterFQN = types.get(clazz.getName());
if (persisterFQN != null && !persisterFQN.equals("")) {
return persisterFQN;
}
}
}
Problem:
This approach works ONLY when the interfaces are implemented directly but does NOT work when there is inheritance because o.getClass().getInterfaces() returns only the interfaces the class "o" implements directly but does NOT return the interfaces it's parent (and parent's parent, etc) implement.
For example in considering SerializableVariablePersister:
it WILL work when having a Serializable in the form of:
class DummySerializable implements Serializable {.....}
But it will NOT work if the serializable is in the form of:
class ChildDummySerializable extends DummySerializable {.....}
It will neither for any class that participates in the hierarchy (e.g. GrandChildDummySerializable extends ChildDummySerializable {.....}, etc.)
If the variable that doesn't implement the Variable Persisted Type directly it will NOT be persisted with the "expected" variable persister.
Suggested Fix:
Class<?> clazz = o.getClass();
do {
Class<?>[] interfaces = clazz.getInterfaces();
for(Class<?> interfaze : interfaces) {
persisterFQN = types.get(interfaze.getName());
if (persisterFQN != null && !persisterFQN.equals("")) {
System.out.println("Persistence strategy returns: " + persisterFQN);
return persisterFQN;
}
}
} while ( (clazz = clazz.getSuperclass() ) != null);
The fix pointed above will walk through each class in the inheritance chain and will pull ALL interfaces until it finds one that is of a Variable Persisted Type and has a corresponding Variable Persister
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
15 years, 7 months