Hello.

I set the primary node type of the new node to "mgnl:content", which
should declare this node also to be of "mix:versionable". When
changing the properties of a custom node, I always check it out, save
it and check it back in. So index changes should be made automatically
by the manager objects. Still, Magnolia does not recognize any
changes.

Perhaps the SharedItemStateManager is a good starting point for
further research, but I couldn't find out to make it aware of changes
cross-session wide.

Regards.

Wan-Hi Joh

2007/8/20, Capitaine Harold <[email protected]>:
> Hi,
>
> I'm not used with direct JCR modifications in repositories, so I won't
> answer.
> But I would have a question just to learn more about this:
> Does your method modify the jcr index? because if it doesn't, how
> Magnolia should be able to see the changes.
>
> Regards,
>
> CAPITAINE Harold
>
>
>
> Wan-Hi Joh a écrit :
> > Hello Harold,
> >
> > I'm using the JackRabbit / JCR API to get access to the Magnolia
> > repository to stay independent from Magnolia. So I connect to the
> > repository and add data like this:
> >
> > Repository repository = new TransientRepository(JCR_CONFIG_FILE_PATH,
> > JCR_REPOSITORY_HOME);
> > Session session = repository.login(new SimpleCredentials(JCR_LOGIN,
> > JCR_PASSWORD.toCharArray()), JCR_WORKSPACE_NAME);
> > Node child = session.getRootNode().addNode("someNode").;
> > child.setProperty("title", "sometext");
> > session.save();
> > session.logout();
> >
> > The child node is added and saved. But Magnolia does not detect the
> > changes and recognizes manipulated nodes only after a restart.
> > Magnolia's repository descriptor states observation to be allowed,
> > which implies that Magnolia uses observation. Perhaps I miss an
> > application specific detail. Any help is highly appreciated.
> >
> >
> > Regards,
> >
> > Wan-Hi Joh
> >
> >
> > 2007/8/16, Capitaine Harold <[email protected]>:
> >
> >> Hi,
> >>
> >> When you add a node are you using this kind of method:
> >>
> >> HierarchyManager hm = ContentRepository.getHierarchyManager();
> >> Content parentNode = hm.getNode("the/path");
> >> parentNode.createNode(needed_args);
> >> parentNode.save(); //don't forget to save the parent, I think that is
> >> the reason why you don't see the node.
> >>
> >>
> >> If you're not using this method can you describe steps by steps what
> >> you're doing.
> >>
> >> HTH
> >>
> >> CAPITAINE Harold
> >>
> >> Wan-Hi Joh a écrit :
> >>
> >>> Hello everyone,
> >>>
> >>> I'd like to know how to make Magnolia detect content changed on
> >>> repository level.
> >>>
> >>> Scenario: I use Magnolia 3.0.2 (Bundle) with mySQL as the backing
> >>> store. My goal is to add valid JCR nodes to the "website" repository,
> >>> while Magnolia detects these changes during runtime. I successfully
> >>> connect to the repository (author instance) using JackRabbit/JCR, and
> >>> add / persist a node to an existing one, but I still must restart
> >>> Magnolia to see the added node listed in the AdminInterface. This is
> >>> quite irritating because
> >>> Boolean.parseBoolean(repository.getDescriptor(Repository.OPTION_OBSERVATION_SUPPORTED))
> >>> returns true. info.magnolia.module.admininterface.Engine also adds
> >>> some EventListeners to the ObservationManager.
> >>>
> >>> What do I miss?
> >>>
> >>> Regards,
> >>>
> >>> Wan-Hi Joh
> >>>
> >>> P.S: Sorry for double posting. It was a long day.
> >>>
> >>> ----------------------------------------------------------------
> >>> for list details see
> >>> http://documentation.magnolia.info/docs/en/editor/stayupdated.html
> >>> ----------------------------------------------------------------
> >>>
> >>>
> >>
> >> ----------------------------------------------------------------
> >> for list details see
> >> http://documentation.magnolia.info/docs/en/editor/stayupdated.html
> >> ----------------------------------------------------------------
> >>
> >>
> >
> >
> >
>
>
>
> ----------------------------------------------------------------
> for list details see
> http://documentation.magnolia.info/docs/en/editor/stayupdated.html
> ----------------------------------------------------------------
>

----------------------------------------------------------------
for list details see
http://documentation.magnolia.info/docs/en/editor/stayupdated.html
----------------------------------------------------------------

Reply via email to