Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Berkeley DB Java Edition version 4.0.103
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sleepycat.je
Class SecondaryIntegrityException

    java.lang.Object
      java.lang.Throwable
          java.lang.Exception
              java.lang.RuntimeException
                  com.sleepycat.je.DatabaseException
                      com.sleepycat.je.OperationFailureException
                          com.sleepycat.je.SecondaryReferenceException
                              com.sleepycat.je.SecondaryIntegrityException

All Implemented Interfaces:
  Serializable

    public class SecondaryIntegrityException

extends SecondaryReferenceException

Thrown when an integrity problem is detected while accessing a secondary database, including access to secondaries while writing to a primary database. Secondary integrity problems are normally caused by the use of secondaries without transactions.

The `Transaction` handle is invalidated as a result of this exception.

Some possible causes of a secondary integrity exception are listed below. Note that only the first item -- the use of a non-transactional store -- is applicable when using the `DPL`. All other items below do not apply to the use of the DPL, because the DPL ensures that secondary databases are configured and managed correctly.

1. The use of non-transactional databases or stores can cause secondary corruption as described in Special considerations for using Secondary Databases with and without Transactions. Secondary databases and indexes should always be used in conjunction with transactional databases and stores.
2. Secondary corruption can be caused by an incorrectly implemented secondary key creator method, for example, one which uses mutable state information or is not properly synchronized. When the DPL is not used, the application is responsible for correctly implementing the key creator.
3. Secondary corruption can be caused by failing to open a secondary database before writing to the primary database, by writing to a secondary database directly using a `Database` handle, or by truncating or removing primary database without also truncating or removing all secondary databases. When the DPL is not used, the application is responsible for managing associated databases correctly.

Since:
  4.0
See Also:
  Serialized Form

Method Summary

Methods inherited from class com.sleepycat.je.SecondaryReferenceException
`getPrimaryKey, getSecondaryDatabaseName, getSecondaryKey`

Methods inherited from class com.sleepycat.je.DatabaseException
`getMessage`

Methods inherited from class java.lang.Throwable
`fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Berkeley DB Java Edition version 4.0.103
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (c) 2004-2010 Oracle. All rights reserved.