-
1. Re: Notification for removeData() calls
ben.wang Oct 31, 2005 1:03 PM (in response to martinluene)Are you running your op under a transaction? Currently, our notification does not distinguish the transaction context yet.
-Ben -
2. Re: Notification for removeData() calls
martinluene Nov 1, 2005 2:43 AM (in response to martinluene)Yes, I'am using Transactions. But the direct notification within the transaction is not my problem.
With the JBossCache, i now have to distinguish a "VisitedNotification", which indicates a Modification, from another, say normal, "VisitedNotification" which indicates a read access.
Now i debugged into the JBossCache-Sources (thanks for including them into the download!) and i found following snipped in method _removeData.
I don't understand the reason for the line, i marked with ">>>": Why sending "NodeVisited" as normal notification? I would expect "NodeModified", which is in the "else"-block.
Regards,
Martin
public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction)
throws CacheException {
[...]
if(eviction)
notifyNodeEvict(fqn, true);
else
notifyNodeModify(fqn, true);
n.clear();
if(eviction)
n.put(UNINITIALIZED, null); // required by cache loader to subsequently load the element again
>>> if(sendNodeEvent) {
notifyNodeVisited(fqn);
}
else { // FIXME Bela did this so GUI view can refresh the view after node is evicted. But this breaks eviction policy, especially AOP!!!!
if(eviction) {
notifyNodeEvicted(fqn);
notifyNodeEvict(fqn, false);
} else {
notifyNodeModified(fqn); // todo: merge these 2 notifications back into 1 !
notifyNodeModify(fqn, false);
}
} -
3. Re: Notification for removeData() calls
martinluene Nov 3, 2005 9:21 AM (in response to martinluene)Sorry for asking again.
Do you think, this is a bug?
I found no according JIRA Issue, i thought i ask here before opening an JIRA Issue.