jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zhu zhu <howard.h...@gmail.com>
Subject Re: is there an easy way to migration a repository?
Date Wed, 04 Nov 2009 15:44:58 GMT
#########################################################<BEGIN>###############################################
Thank you for your kind reply.
Because i have a web application based on this repository,did you mean
that i should update my repository version from 1.4 to 1.6?

my cnd file looks like the following.
###########################################################################
<nt = 'http://www.jcp.org/jcr/nt/1.0'>
<jcr = 'http://www.jcp.org/jcr/1.0'>
<mix = 'http://www.jcp.org/jcr/mix/1.0'>
<nuke = 'http://www.intellitrans.com.cn/nuke'>

[mix:accessControlled]
- nuke:authUsersRead (string) multiple mandatory
- nuke:authUsersWrite (string) multiple mandatory
- nuke:authRolesRead (string) multiple mandatory
- nuke:authRolesWrite (string) multiple mandatory

[nuke:file] > nt:hierarchyNode, mix:versionable, mix:lockable
- nuke:fileID (string) primary mandatory
- nuke:author (string)
- nuke:name (string)
- nuke:size (long)
- nuke:contentType (string)
- nuke:keywords (string)
- nuke:modifyUser (string)
- nuke:modifyTime (date)
- nuke:notification (string)
- nuke:content (binary)

[nuke:folder] > nt:folder, mix:versionable, mix:lockable
- nuke:author (string)  mandatory
- nuke:name (string)
- nuke:notification (string)

[nuke:config] > nt:hierarchyNode, mix:versionable
- *

[nuke:navigation] > nt:hierarchyNode, mix:versionable
- nuke:navigationURL (string) = ' '  primary mandatory autocreated
- nuke:navigationTitle (string) = ' ' mandatory
- nuke:navigationPower (string) multiple
- nuke:navigationTemplete (string)
- nuke:navigationStyle (string)
- nuke:navigationClass (string)
- nuke:navigationSelectImage (string)
- nuke:navigationUnSelectImage (string)
- nuke:navigationParameter (string)
- nuke:navigationSystemWidth (string)
- nuke:navigationSystemHeight (string)
- nuke:navigationSystem (boolean) = false
- nuke:navigationGroup (boolean) = false
- nuke:navigationPulbic (boolean) = false
- *

[nuke:email] > nt:hierarchyNode, mix:versionable
- nuke:email_login_id (string) mandatory
- nuke:email_account (string) mandatory
- nuke:email_model_type (string) mandatory
- nuke:email_id (string) primary mandatory
- nuke:send_email_address (string)
- nuke:receive_email_address (string) multiple
- nuke:copy_send_email_address (string) multiple
- nuke:bcc_send_email_address (string) multiple
- nuke:transmit_send_email_address (string) multiple
- nuke:email_title (string)
- nuke:email_content (string)
- nuke:email_size (long)
- nuke:receive_email_time (long)
- nuke:send_email_time (long)
- *
###########################################################################
The old repository is based on jackrabbit 1.4.9  and store file with blobstore.
With the growth of file's size ,all files seems to be stored in one
file named "c400.dat",and this file is 50G now ....
In windows OS,it is horrible. i wouldnt even  backup or copy it .
So i need to migrate it to an new reporitory based on datastore.

the following is my solution:

step 0: deploy an new repository with datastore(has the same workspace
configuration) .
step 1: update jackrabbit core to 1.4.11
step 2: get remoteRepository instance from the old repository .
          "Repository remoteRepository
                         =
org.apache.jackrabbit.rmi.client.ClientRepositoryFactory.getRepository(remoteRmiURI);"
step 3: exportSystemView from  remoteRepository without binary info
(nuke:file) .
step 4: importXml to newRepository .
step 5: query all binary info with xquery "//element(*, nuke:file)"
from remoteRepository.
step 6: update localRepository ,update property "nuke:content"  with
"nuke:fileID" (primary mandatory).
difficult points: how to optimize the xquery ,
                   such as 'select *  from table01 where rownum < 10 '
and 'select count(*) from table01' in sql.

Can anyone help me ?
Thanks for your attention and hope to receive your reply.

#########################################################<END>###############################################



2009/11/4 Thomas Müller <thomas.mueller@day.com>

> Hi,
>
> The RepositoryCopier tool seems to be what you need.
> See http://wiki.apache.org/jackrabbit/BackupAndMigration
>
> Regards,
> Thomas
>
>
> On Tue, Nov 3, 2009 at 10:10 AM, terial <howard.huhu@gmail.com> wrote:
> >
> > Hi all ,
> > Can you show me an easy way to migration a repository to use the data
> > store .
> > In out production environment,the old repository use blobstore to store
> > file in it . and it is nearly 40G now .
> > Now i want to migrate it to use data store .can you show me the way how
> > you dit it ?
> > My solution is to export SystemView with binary info to an xml file
> > named "myData.xml",when i operate this file with session.importXml to
> > new repository with data store ,i got the error "OutOfMemoryError".
> > We look forward to your early replay ,thanks .
> > My jackrabbit core version is 1.4.11.
> >
> > I can also supply my environment, i could not resolve this problem...
> > --
> > View this message in context:
> http://old.nabble.com/is-there-an-easy-way-to-migration-a-repository--tp26160032p26160032.html
> > Sent from the Jackrabbit - Users mailing list archive at Nabble.com.
> >
> >
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message