Hey guys,

I didn't know for sure where to put this question so thats why I am asking it 
in both Jackrabbit as in Sling, because both might have their own solution / 
proposal, and I have seen solutions that are pure Jackrabbit but some that also 
require Sling.

I was wondering about what some of you might achieve something like a daily 
content sync between different environments (Production to 
Acceptance/Development for example).

I have been investigating it for a while now, and the current solution we use 
is by use of the oak-migration tool, where every release that we have, we bring 
the repo down, do an export of all the paths that we need (mainly /content and 
some stuff in /etc and /conf), and do an import on all the other lower 
environments. But I am not sure if this is the ideal solution, definitely if we 
want to go to a daily content sync instead of a release bound content sync, 
seeing as this required the instance be put offline before it can run (unless 
this changed in a future version, please correct me if it did because that 
would be very nice).

The tools I have found that might be of use until are the following:
One could create a JCR content package of production, and copy it over to the 
different environments daily. The downside of this is that when the package 
becomes big, it gets problematic (for example when a lot of images/videos start 
to get involved).
One could use VLT RCP, I have tried this but it seems that it has a bug[1] that 
when there is an error in the vlt rcp, it actually retries infinite amount to 
fix it, making the actual sync impossible from the moment one error for a 
specific node pops up. A second problem, and also sort of a dealbreaker is that 
for VLT RCP to work, you would have to make the production environment network 
accessible to all the other environments, or a bit better, use some proxy that 
has access to both production and the test environments.
Time Warner seems to have run into the same issue, and created Grabbit[2] for 
this, but their tool has also two mayor drawbacks. The first drawback is 
related to the VLT RCP, where you would need to have access from production to 
all the other environments, but even worse is that you can't do it with a proxy 
in between, meaning they really need to have access to each other. A second 
drawback that I really dislike is that their tool is written in Spring OSGi. I 
have no idea why one would make a tool in OSGi and then use Spring for it, but 
they bring in like 30 bundles just to do a content sync between environments, 
mainly outdated Spring 3.X bundles.
Lastly of course there is the oak migration tool, which is super fast in doing 
an export and import, it is the current one we use, but the drawback being that 
you have to bring down the environment.
The solutions that I am currently thinking of are one of the next two, which 
are almost similar, but it would be nice to hear some opinions from other 
people.

We could write a service that just specifies a list of node paths that have 
been altered in the current day, for example based on the jcr:lastModified date.
From this list, one could do one of the following this:
Create a dynamic jcr content package, based on the list provided by this 
service. The drawback being if there are a lot of new images/videos that 
specific day, the content package might get slow / be too big / time out
Create a dynamic list of include and merge paths for the oak-migration tool 
based on this service. The drawback being you would have to bring down your 
repo after this

Another solution when going for the second part would be to expand the 
oak-migration tool to optionally specify which paths it should export based on 
a specific date property being larger/smaller than the one you pass as parameter

Any opinions / suggestions on this are more than welcome.

Greets,
Roy Teeuwen

[1] 
http://jackrabbit.510166.n4.nabble.com/Filevault-OakConstraint0021-Exception-td4666959.html
 
<http://jackrabbit.510166.n4.nabble.com/Filevault-OakConstraint0021-Exception-td4666959.html>
[2] https://github.com/TWCable/grabbit <https://github.com/TWCable/grabbit>

Attachment: signature.asc
Description: Message signed with OpenPGP

Reply via email to