Hung Tu | 1 Sep 2010 10:14
Picon
Favicon

Repository configuration


  Hi all,

I have a question about how to configure repository. At the time I have 
a project, which uses jackrabbit as repository. We need two folders on 
jcr, let's say "raw_material" and "output". The requirement is,  each 
folder should be configured in separate mounted local directory. So what 
should I do to separate the repository?
Thanks in advance.

Hung Tu

Robin Wyles | 1 Sep 2010 11:38
Picon

Re: Problems migrating from 1.6.0 to 2.1.0

An update on this...

Stefan was indeed correct and it a charset/encoding issue that was causing Jackrabbit to ignore the
existing repository content.

However, now that I have manage to get our existing repository running under 2.1.0 I have a new problem and
that is that all the nt:file nodes whose content is stored in the datastore (FileDataStore) are missing.
The small nt:file nodes that are stored in the database are visible, just not those in the FileDataStore.

When starting up our newly migrated repository for the first time I get a few "Record not found" datastore
exceptions and some associated Tika exceptions for those missing datastore records - would those errors
prevent the entire datastore from being used? The number of errors are far less than the 3000 or so items in
the datastore, so it would suggest that it's either ignoring most of the datastore contents, or at start up
at least they are recognised as valid.

As before, once our repository has started I am able to add new nodes to the datastore, and these behave has expected.

Any help, gratefully received - I'm really keen to get our repos onto 2.10 as some of its new query
functionality is much needed!

Robin

On 27 Aug 2010, at 16:03, Robin Wyles wrote:

> Hi Stefan
> 
> On 27 Aug 2010, at 13:11, Stefan Guggisberg wrote:
> 
>> On Fri, Aug 27, 2010 at 2:02 PM, Stefan Guggisberg
>> <stefan.guggisberg <at> day.com> wrote:
(Continue reading)

Stefan Guggisberg | 1 Sep 2010 11:44
Favicon

Re: Problems migrating from 1.6.0 to 2.1.0

On Wed, Sep 1, 2010 at 11:38 AM, Robin Wyles <robin <at> jacaranda.co.uk> wrote:
> An update on this...
>
> Stefan was indeed correct and it a charset/encoding issue that was causing Jackrabbit to ignore the
existing repository content.

thanks for the information. can you please provide more details about
the exact nature of the problem?

cheers
stefan

>
> However, now that I have manage to get our existing repository running under 2.1.0 I have a new problem and
that is that all the nt:file nodes whose content is stored in the datastore (FileDataStore) are missing.
The small nt:file nodes that are stored in the database are visible, just not those in the FileDataStore.
>
> When starting up our newly migrated repository for the first time I get a few "Record not found" datastore
exceptions and some associated Tika exceptions for those missing datastore records - would those errors
prevent the entire datastore from being used? The number of errors are far less than the 3000 or so items in
the datastore, so it would suggest that it's either ignoring most of the datastore contents, or at start up
at least they are recognised as valid.
>
> As before, once our repository has started I am able to add new nodes to the datastore, and these behave has expected.
>
> Any help, gratefully received - I'm really keen to get our repos onto 2.10 as some of its new query
functionality is much needed!
>
> Robin
>
(Continue reading)

Carl Hall | 1 Sep 2010 15:45
Favicon
Gravatar

Converting XPath to JCR-SQL2

Since XPath has been deprecated for searching, I'm working to change over
some XPath queries to JCR-SQL2.  I have this one that is killing
performance.    Translating the query below to JCR-SQL2 caused a performance
problem (0.072s -> 5s+).

Am I doing something wrong or is the JCR-SQL2 engine still coming along?

XPath::
//*[ <at> sling:resourceType="sakai/group-profile" and
jcr:contains(.,'g-test-group')] order by  <at> jcr:score descending

JCR-SQL2::
SELECT * FROM [nt:base] as n WHERE [sling:resourceType] =
"sakai/group-profile" and contains(n.*,'g-test-group') order by score() desc
Jukka Zitting | 1 Sep 2010 15:54
Picon
Gravatar

Re: Converting XPath to JCR-SQL2

Hi,

On Wed, Sep 1, 2010 at 3:45 PM, Carl Hall <carl <at> hallwaytech.com> wrote:
> Since XPath has been deprecated for searching, I'm working to change over
> some XPath queries to JCR-SQL2.  I have this one that is killing
> performance.    Translating the query below to JCR-SQL2 caused a performance
> problem (0.072s -> 5s+).
>
> Am I doing something wrong or is the JCR-SQL2 engine still coming along?

The current JCR-SQL2 implementation is not yet optimized for performance.

I'm currently working on improving the JCR-SQL2 implementation, see
JCR-2715 [1]. I expect to make JCR-SQL2 query performance comparable
to XPath and SQL1 performance in time for the 2.2 release.

[1] https://issues.apache.org/jira/browse/JCR-2715

BR,

Jukka Zitting

Robin Wyles | 1 Sep 2010 16:15
Picon

Re: Problems migrating from 1.6.0 to 2.1.0

Hi Stefan,

On 1 Sep 2010, at 10:44, Stefan Guggisberg wrote:

> On Wed, Sep 1, 2010 at 11:38 AM, Robin Wyles <robin <at> jacaranda.co.uk> wrote:
>> An update on this...
>> 
>> Stefan was indeed correct and it a charset/encoding issue that was causing Jackrabbit to ignore the
existing repository content.
> 
> thanks for the information. can you please provide more details about
> the exact nature of the problem?
> 

Sure, it seems that mysqldump has a habit of corrupting charsets other than latin1. We forced the use of
latin1 using following commands to export/import our repository data:

mysqldump -u username -p --default-character-set=latin1 -N database > backup.sql
mysql -u username -p --default-character-set=latin1 database < backup.sql

There's more info here:

http://docforge.com/wiki/Mysqldump

Even though this appears to work we're still unable to see any nt:file nodes whose binary data is stored in
the datastore, I'm not sure whether this is a related or separate issue...

Robin

> cheers
(Continue reading)

Carl Hall | 1 Sep 2010 16:16
Favicon
Gravatar

Re: Converting XPath to JCR-SQL2

Hi Jukka,

Thanks for the response and your continued work on JR.  I look forward using
your improvements!

Carl

On Wed, Sep 1, 2010 at 9:54 AM, Jukka Zitting <jukka.zitting <at> gmail.com>wrote:

> Hi,
>
> On Wed, Sep 1, 2010 at 3:45 PM, Carl Hall <carl <at> hallwaytech.com> wrote:
> > Since XPath has been deprecated for searching, I'm working to change over
> > some XPath queries to JCR-SQL2.  I have this one that is killing
> > performance.    Translating the query below to JCR-SQL2 caused a
> performance
> > problem (0.072s -> 5s+).
> >
> > Am I doing something wrong or is the JCR-SQL2 engine still coming along?
>
> The current JCR-SQL2 implementation is not yet optimized for performance.
>
> I'm currently working on improving the JCR-SQL2 implementation, see
> JCR-2715 [1]. I expect to make JCR-SQL2 query performance comparable
> to XPath and SQL1 performance in time for the 2.2 release.
>
> [1] https://issues.apache.org/jira/browse/JCR-2715
>
> BR,
>
(Continue reading)

Thomas Müller | 1 Sep 2010 16:22
Favicon

Re: Problems migrating from 1.6.0 to 2.1.0

Hi,

The FileDataStore stores the data in the file system. When migrating
data, you need to copy those files to the right directory, or you need
to change the repository configuration so it points to the old
directory. See also
http://wiki.apache.org/jackrabbit/DataStore#Configuration

Please let us know if this doesn't solve the problem.

Regards,
Thomas

Robin Wyles | 1 Sep 2010 16:33
Picon

Re: Problems migrating from 1.6.0 to 2.1.0

Hi Thomas,

The datastore has been copied, and the repository knows where it is. I know this because after startup I am
able to add new nt:file nodes, and can see the new datastore directories being created on the file system.
The newly added nt:file nodes can be seen, just none of the existing ones unless their binary data is stored
in the persistence manager (MySQL).

Thanks,

Robin

On 1 Sep 2010, at 15:22, Thomas Müller wrote:

> Hi,
> 
> The FileDataStore stores the data in the file system. When migrating
> data, you need to copy those files to the right directory, or you need
> to change the repository configuration so it points to the old
> directory. See also
> http://wiki.apache.org/jackrabbit/DataStore#Configuration
> 
> Please let us know if this doesn't solve the problem.
> 
> Regards,
> Thomas

Thomas Müller | 1 Sep 2010 17:09
Favicon

Re: Problems migrating from 1.6.0 to 2.1.0

Hi,

In Jackrabbit 1.6, did you always use the data store, or did you add
the data store configuration after you already added data? Do you have
any files in the blob store (workspaces/*/blob directory) in the old
repository?

Maybe it's easier to migrate the data using a tool from
http://wiki.apache.org/jackrabbit/BackupAndMigration - for example the
"Repository Copier Tool". Unfortunately, I don't have any experience
using it.

Regards,
Thomas


Gmane