I was searching for solution quite long, but haven't found a real solution.
My applications has a EJB 2.1 part and EJB3 part. In some rare cases I have to write into EJB2 part using EJB3, so EJB2 commit-option-A caching doesn't get it. (JBOSS 4.0.5)
Is there an easy way to remove an instance from the cache, something like
session.evict() in Hibernate?
Commit-Option-B is not really an option, because it's much slower. Commit-Option-D is not an option too, because I need the changes to be registered by EJB2 in the same moment.
What I do now is mirroring of the EJB3 update but it's not a perfect solution, as long I need 2 updates every time I wan't to update.
I've tried the InvalidationManager solution, but it seems like I need a dependency on the jboss.jar and it's not so cool either.
Thank you in advance!