Hi Armin,
The detection mechanism works, but i have a strange behaviour, i collected
some open-broker detections. So i had a look into code, and i saw my close
call in a finally clause. this is correct.
So, i don't doubt about "java" finally, but the implementation of my
closeBroker method. In
Yep. I did something like... with an immediate catched exception!! it
works...
I add a method into PersistenceBrokerFactory to artificially fire all the
finalize methods. This method call releaseAllInstances and System.gc(). then
Finalize are all fired. It works well.
Will release 1.0.5 come out
Hi Bruno,
below you can find #setClosed(...) and #finalize() of the modified PB
source (will check in this in a few days).
regards,
Armin
/**
* A stack trace of this broker user.
* Used when broker leak detection is enabled.
*/
protected String brokerStackTrace;
public void setClosed(bool
Hi Armin, thanks for solution , but i'm not sure i did get it all !!
Can you confirm solution?
Well, i understand i have to override setCLosed method to catch when broker
open (is borrowed), throw an exception to save a stacktrace with a catch.
So , PB remembers his last loan. that's it ?
When f
Bruno CROS wrote:
using proxies ?
Oh, i see now. Proxy opens and closes broker well. that's it ?
I didn't think to that. Tsss...
I'm sorry.
It seems that i'm looking for my lost brokers since too much time ago.
I guess i'm going to check all my DAOs and all my transactions again (or may
be
using proxies ?
Oh, i see now. Proxy opens and closes broker well. that's it ?
I didn't think to that. Tsss...
I'm sorry.
It seems that i'm looking for my lost brokers since too much time ago.
I guess i'm going to check all my DAOs and all my transactions again (or may
be someone else now ;-)
Hi Bruno,
Bruno CROS wrote:
Hi Armin,
Here's is a schematic example :
Consider a service method that returns an object "ProductBean". ProductBean
is not O/R mapped but the reading calls a second method that read O/R
mapped Product object. Then, relations are followed, to find description of
h
Hi Armin,
Here's is a schematic example :
Consider a service method that returns an object "ProductBean". ProductBean
is not O/R mapped but the reading calls a second method that read O/R
mapped Product object. Then, relations are followed, to find description of
his Category (Consider that a pr
Hi Bruno,
Bruno CROS wrote:
Hi,
It seems that read objects with a broker, can read related objects by
auto-retrieve set to "true" despite broker is closed.
I can't see what you mean. When OJB materialize an object with related
objects and auto-retrieve is 'true', the full materialized objec
Hi,
It seems that read objects with a broker, can read related objects by
auto-retrieve set to "true" despite broker is closed.
I suppose that a getDefaultBroker is done, and the borrowed broker is never
closed (because no reference on it).
Note : This occurred because, application has been writt
10 matches
Mail list logo