On Sep 2, 2005, at 9:41 AM, Nenko Ivanov wrote:
> Hi all,
> I have a job which generates a lot of database changes and
> sometimes transaction commit time takes too long and
> I want to attach JProgressBar for monitoring the saving changes
> progress.
> Can I monitor each saving step finishing?
>
> Thanks in advance.
>
> Nenko
Here is one possible solution:
- replace DataNode with subclass (the easiest way is via a custom
ConfigLoaderDelegate that extends RuntimeLoaderDelegate overriding
"shouldLoadDataNode").
- override DataNode.performQueries(Collection,OperationObserver
resultConsumer,Transaction transaction) to wrap passed
OperationObserver in your own decorator that broadcasts each
operation to the Swing UI (delegating the actual processing to the
original Observer of course).
Warning: don't use DbAdapter.createDataNode() in step (1) - this
method is deprecated in 1.2 and is no longer invoked.
Andrus
This archive was generated by hypermail 2.0.0 : Fri Sep 02 2005 - 10:34:33 EDT