Package javax.cache.event

This package contains event listener interfaces.

See: Description

Package javax.cache.event Description

This package contains event listener interfaces. These may be registered for callback notification of the cache events. The specific interface should be implemented for each event type a callback is desired on.

Event notifications occur synchronously in the line of execution of the calling thread. The calling thread blocks until the listener has completed execution or thrown a CacheEntryCreatedListener.

Listeners are invoked after the cache is updated. If the listener throws an CacheEntryCreatedListener this will propagate back to the caller but it does not affect the cache update as it already completed before the listener was called. If the cache is transactional, transactions must commit before listeners are called. If an exception is thrown by a listener this does not affect the transaction as the transaction has already completed.

Greg Luck, Yannis Cosmadopoulos

Copyright © 2013. All Rights Reserved.