On Wed, Jul 22, 2009 at 7:07 PM, daveg0<[email protected]> wrote: > Somehow my repository got corrupted and I started to get exceptions such as: > > failed to build path of 8522e60c-422b-43b8-9391-5146bd274298: > 23638bf1-ebb7-46ae-853c-9667b39ad458 has no child entry for > 8522e60c-422b-43b8-9391-5146bd274298 > > I tried to rebuild the indexes by shutting down the respository and removing > > workspace/default/index > repository/index > > and restarting the respository to rebuild the indexes with > consistencyCheck=true, forceConsistencyCheck=true etc in repository.xml
Please note that the search indexes (which are in workspace/default/index and repository/index) are only for search and optional. The above mentioned error is solely in the node data stored in the database. Also, the various consistency check flags exist both for the search index and the persistence managers. If you set force/enableConsistencyCheck on the search index, it has no effect if you deleted the search index before restart, as it will create a new search index anyway. What you probably want is to enable consistencyCheck and consistencyFix on the persistence managers. Note that you have to do it in the workspace.xml file and not the repository.xml (where the workspace element is only used as template for creating new workspaces). Here is a nice description: http://wiki.gxdeveloperweb.com/confluence/display/GXDEV/How+to+repair+a+'corrupt'+JCR Modifying the DB manually is hard, since the bundle pm stores nodes + its properties + its list of child nodes in a compact binary blob. > However it gets so far and then gives the Exception: > Caused by: javax.jcr.RepositoryException: Error indexing workspace: Error > indexing workspace: Error indexing workspace > at > org.apache.jackrabbit.core.SearchManager.initializeQueryHandler(SearchManager.java:555) > at > org.apache.jackrabbit.core.SearchManager.<init>(SearchManager.java:239) > Caused by: org.apache.jackrabbit.core.state.NoSuchItemStateException: > 80c25f39-9143-4174-a4be-91822a114c7c If this error gets you in the way during consistency check and repair of the persistence manager, you can disable the search index by simply commenting out the SearchIndex element in the repository.xml. Regards, Alex -- Alexander Klimetschek [email protected]
