Shawn, there is a 3rd option... Create dedicated "post commit" variant contracts. One sub-option there would be like so:
public interface PostCommitInsertEventListener extends PostInsertEventListener {
public void insertFailed(PostInsertEvent event);
}
A slight variation of that sub-option which is more backwards compatible for all users would be a separate callback just for the failure...
public interface FailedPostCommitInsertEventListener { public void insertFailed(PostInsertEvent event); }
Here you'd check whether the listener implemented this optional contract in the failed case...
Just some ideas.
|