Hi Robert, With magnolia, because of the embedded JCR you need to do something in magnolia itself:
- either you use the existing UI to manually import XML files - or you write a small "receiver" in magnolia (eg a Servlet or Filter for magnolia's filter chain) which receives the data sent by an external source - or you write a small "fetcher" in magnolia (eg an App or a scheduled command) which fetches the data from an external source The XML import in magnolia == the Jackrabbit import. The XML format exported or imported by magnolia is actually the Jackrabbit "system view" of the JCR repository. So yes, a good (and simple) approach is to produce this format somewhere, and just import it into magnolia. It should also be quite trivial to write a small command or groovy script which you can then call using magnolia's scheduler module. As for updating content, there are several ways to handle it, this is given by Jackrabbit's import feature: Each node in JackRabbit has an identifier (or UUID). A UUID must be unique in a given workspace. When importing you can specify the behavior with respect to the UUIDs: - THROW - throw an error if the UUID already exists in the workspace, the node does not get exported - DELETE - if the UUID exists in the workspace, delete that node first, and then import the new node at the location given for the import (note that this could theoretically delete a huge subtree elsewhere in the workspace!) - REPLACE - if the UUID exists in the workspace, replace that node with the imported node at the location of the existing node (this will replace content originally imported at one location and then moved elsewhere in the workspace) - NEW - create new UUIDs for the imported content See also: http://www.javadocexamples.com/javax/jcr/javax.jcr.ImportUUIDBehavior.html The trick is also to generate "stable" UUIDs for your content: ie when you export the same content again, it should be generated with the same UUIDs as the last time, so that it can be matched up during the import process... Regards from Vienna, Richard > -----Ursprüngliche Nachricht----- > Von: [email protected] [mailto:user-list-owner@magnolia- > cms.com] Im Auftrag von robert stettler (via Magnolia Forums) > Gesendet: Dienstag, 07. Jänner 2014 15:24 > An: Magnolia User List > Betreff: [magnolia-user] Re: Content modeling > > Your answers have been helpful. Maybe you could help with one more. > Today we use Teamsite for content management and use weblogic's vcr for > the runtime content queries. We have a custom load process to export from > teamsite and import into the vcr. Unfortunately our use of Teamsite is not > changing anytime soon... > > With jackrabbit I wrote a small java app to read our custom manifests and to > import the content into the jcr. If we go the magnolia route what is likely to > be the best route? > > I am thinking we would need to create an XML import file that magnolia can > read? and use the magnolia import feature? > > That also brings up a question or two about existing content. If I import > content that has changed how does magnolia handle those scenarios? > > -- > Context is everything: http://forum.magnolia- > cms.com/forum/thread.html?threadId=e619846d-c348-4fff-97c3- > c6103468d5d8 > > > ---------------------------------------------------------------- > For list details, see http://www.magnolia-cms.com/community/mailing- > lists.html > Alternatively, use our forums: http://forum.magnolia-cms.com/ > To unsubscribe, E-mail to: <[email protected]> > ---------------------------------------------------------------- ---------------------------------------------------------------- For list details, see http://www.magnolia-cms.com/community/mailing-lists.html Alternatively, use our forums: http://forum.magnolia-cms.com/ To unsubscribe, E-mail to: <[email protected]> ----------------------------------------------------------------
