Arjun Dhar wrote:
You cannot insert data over time into a stateless session, all data is 
added at the same time. When the engine has finished processing it w ill 
return and is finished, at this point as soon as the stateless session 
is available for garbage collection the objects will be removed. There 
is no life cycle other than the standard GC one.
    

  
Shadows are created on non-final classes unless you tell the system not 
to, if you are sure you don't need them you can turn them off. They can 
be turned of for all object, or specific objectsor packages.
    

  
no.
    

Am sorry I got confused with the statement "All data is added at the same time. 
When engine has finshed processing it will return finish" --> Isn't this 
applicable for a single "execute" only?
  
Each time you call execute(....) the previous inserted data references are nulled and thus able to GC. If you lose the referene to the stateless
session, that too is nulled and GCd. Look at the code, that will easiest help you understand:
http://fisheye.jboss.org/browse/JBossRules/branches/Branch_4_0_2_SOA_4_2/drools-core/src/main/java/org/drools/reteoo/ReteooStatelessSession.java?r=HEAD
A fresh execute would imply a 'new usage' of the same session (Since it is 
stateless, else I could use new stateful sessions also each time I had to 
execute). And for this reason I cant understand why can't a stateless session 
be used indefinitely?! As each "execute" is stateless!

So what you are saying is as long a stateless session is not garbage collected, 
it will retain references too all objects asserted to it (even over multiple 
execute calls)?

i.e. session.execute(<Object>) A reference to that object or its shadow will be 
maintained till GC of the session?!









_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users