Menu

#3 Duplicate "new file" messages sent

v0.1-SNAPSHOT
closed
nobody
5
2007-08-09
2007-06-21
No

When the filescanner detects a set of new files, it will first publish messages to the notification system and then commit the scan results to its internal database.

However, if a concurrent modification exception occurs while committing the transaction then the "new file" notification(s) will have been successfully sent, but the scanner database has no record of this. The next time the scanning process executes, fresh notifications for the previously detected "new" files will be sent.

The offending commit call is here:
at uk.org.microbase.scanner.processes.ScannerServiceRunnable.run(ScannerServiceRunnable.java:112)

Possible solutions:
* Assume that subscribers are intelligent enough to notice that they have seen the data item before (i.e, do nothing)
* Implement a 2-stage commit system that commits the necessary scan data, publishes the necessary "new file" event notifications, and then commits to a log if all notifications were sent without error.

Discussion

  • Keith Flanagan

    Keith Flanagan - 2007-08-09

    Logged In: YES
    user_id=1749277
    Originator: YES

    Fixed

     
  • Keith Flanagan

    Keith Flanagan - 2007-08-09
    • status: open --> closed
     

Log in to post a comment.

MongoDB Logo MongoDB