| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| Is it possible to configure jackrabbit to reindex the repository at startup? I know I could force this to happen by deleting the index files, but I would prefer not to do this manually or add more duplicate configuration to my application. I use an in memory repository that I import data into, but the data in the old index is still around. If all else fails, I'll have to duplicate some configuration and delete the files before I start the repo. Thanks, Jared |
|
#2
| |||
| |||
| No, there is no configuration or API for deleting the index. But it's a simple "rm -rf <workspace-path>/index". Regards, Alex On Mon, Jul 21, 2008 at 9:30 PM, Jared Graber <jared.graber@iaccap.com> wrote: > Is it possible to configure jackrabbit to reindex the repository at > startup? > > > > I know I could force this to happen by deleting the index files, but I > would prefer not to do this manually or add more duplicate configuration > to my application. I use an in memory repository that I import data > into, but the data in the old index is still around. > > > > If all else fails, I'll have to duplicate some configuration and delete > the files before I start the repo. > > > > Thanks, > > > > Jared > > -- Alexander Klimetschek alexander.klimetschek@day.com |
|
#3
| |||
| |||
| I found a way to do it automatically without duplicating configuration (in case anyone is interested): Extend from SearchIndex and override the doInit method (update the repository and workspace configuration accordingly). Delete/Rename the index directories (specified by the path variable) and then call super.doInit. If the files are missing, the index files will be recreated. Note: This will only work on startup of the app. If anyone sees a flaw in this, let me know. -Jared -----Original Message----- From: Alexander Klimetschek [mailto:aklimets@day.com] Sent: Monday, July 21, 2008 5:25 PM To: users@jackrabbit.apache.org Subject: Re: Clearing the index No, there is no configuration or API for deleting the index. But it's a simple "rm -rf <workspace-path>/index". Regards, Alex On Mon, Jul 21, 2008 at 9:30 PM, Jared Graber <jared.graber@iaccap.com> wrote: > Is it possible to configure jackrabbit to reindex the repository at > startup? > > > > I know I could force this to happen by deleting the index files, but I > would prefer not to do this manually or add more duplicate configuration > to my application. I use an in memory repository that I import data > into, but the data in the old index is still around. > > > > If all else fails, I'll have to duplicate some configuration and delete > the files before I start the repo. > > > > Thanks, > > > > Jared > > -- Alexander Klimetschek alexander.klimetschek@day.com |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.