As discussed previously on this list, I have implemented a prototype
script which does a md5 + length intelligent update to provide "rsync
like" features to push a directory of local files to a directory on a ML
server.

 

This requires the latest version (1.0.7) of xmlsh and the marklogic
connector

( http://www.xmlsh.org) 

 

If Interested,

Script attached.  I'm not sure if it will survive the list posting so if
not please send me offline email and I'll send it to you.

 

 

First time you run this is less then ideal performance, as it has
re-upload all your files and attach a md5 checksum property.

Faster results could be obtained by running "put -md5" with appropriate
arguments for the initial push, but running this script will do the same
thing (just less efficiently).

 

After that it runs very quickly.

 

I'd love it if anyone tried this and let me know how it works for them.
I've minimally tested it using a directory of xquery module files (my
intended use case).

 

Requires that the marklogic extension is pre-imported to the "ml"
prefix, and that the MLCONNECT environment variable is set.

                import module ml=marklogic

                MLCONNECT=xcc://.....

 

(let me know offline if you need help with this setup).

 

Usage: (from within xmlsh)

 

put_sync  local_dir  /remote_dir/

 

 

 

 

 

----------------------------------------

David A. Lee

Senior Principal Software Engineer

Epocrates, Inc.

[email protected]

812-482-5224

 

 

Attachment: put_sync.xsh
Description: put_sync.xsh

_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to