Class LockTimeoutException

  • All Implemented Interfaces:
    java.io.Serializable

    public class LockTimeoutException
    extends CacheException
    Indicates that a timeout has occured while attempting to obtain a lock using ReadWriteLockSync.tryLock(net.sf.ehcache.concurrent.LockType, long)

    This is a normal runtime exception which should be handled by calling code. It is possible that simply reattempting to obtain the lock may succeed. Timeouts are often caused by overloaded resources.

    The frequency of these Exceptions may be reduced by increasing the timeout if appropriate.

    Version:
    $Id$
    Author:
    Greg Luck
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      LockTimeoutException()
      Constructs a new runtime exception with null as its detail message.
      LockTimeoutException​(java.lang.String message)
      Constructs a new runtime exception with the specified detail message.
      LockTimeoutException​(java.lang.String message, java.lang.Throwable cause)
      Constructor for the LockTimeoutException object.
    • Method Summary

      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • LockTimeoutException

        public LockTimeoutException()
        Constructs a new runtime exception with null as its detail message. The cause is not initialized, and may subsequently be initialized by a call to Throwable.initCause(java.lang.Throwable).
      • LockTimeoutException

        public LockTimeoutException​(java.lang.String message)
        Constructs a new runtime exception with the specified detail message. The cause is not initialized, and may subsequently be initialized by a call to Throwable.initCause(java.lang.Throwable).
        Parameters:
        message - the detail message. The detail message is saved for later retrieval by the Throwable.getMessage() method.
      • LockTimeoutException

        public LockTimeoutException​(java.lang.String message,
                                    java.lang.Throwable cause)
        Constructor for the LockTimeoutException object.
        Parameters:
        message - the exception detail message
        cause - the cause of the exception