Just FYI, because I came across the sources for the spring modules:

The implementation of JackrabbitSessionFactory.registerNodetypes() (in
spring modules 0.9, see [1]) does not catch the
InvalidNodeTypeDefException that is thrown when a nodetype already
exists. It should be fixed by surrounding
nodeTypeManager.registerNodeTypes(resource.getInputStream(),
contentType); with a try-catch statement.

Someone should send a patch to the spring modules guys. In the
meantime, you can simply extend from JackrabbitSessionFactory and
overwrite the registerNodetypes() method that catches the exception.

[1] 
https://springmodules.dev.java.net/source/browse/springmodules/projects/jcr/src/java/org/springmodules/jcr/jackrabbit/JackrabbitSessionFactory.java?hideattic=0&rev=1.3&view=markup

Regards,
Alex

-- 
Alexander Klimetschek
[EMAIL PROTECTED]

Reply via email to