Announcement Announcement Module
Collapse

Spring Modules forum decommissioned in favor of Spring Extensions

As the Spring Modules project has been replaced by the Spring Extensions (http://www.springsource.org/extensions) project, this forum has been decommissioned in favour of Spring Extensions one at:
http://forum.springsource.org/forumdisplay.php?f=44

Please see the Spring Extensions home page for a complete list of current projects in Java, .NET and ActionScript. You can also propose one if you want.

Cheers,
Costin Leau
SpringSource - http://www.SpringSource.com- Spring Training, Consulting, and Support - "From the Source"
http://twitter.com/costinl
See more
See less
Jackrabbit exception Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Jackrabbit exception

    Hi.
    My jackrabbit spring config:

    Code:
    <bean id="jcrSessionFactory" class="org.springmodules.jcr.JcrSessionFactory">
            <property name="repository" ref="repository"/>
            <property name="credentials">
                <bean class="javax.jcr.SimpleCredentials">
                    <constructor-arg index="0" value="acula"/>
                    <constructor-arg index="1">
    			<bean factory-bean="repoPassword" factory-method="toCharArray"/>
                    </constructor-arg>
                </bean>
            </property>
        </bean>
    
        <!-- create the password to return it as a char[] -->
        <bean id="repoPassword" class="java.lang.String">
            <constructor-arg index="0" value="passw"/>
        </bean>
    
        <bean id="jcrTransactionManager" class="org.springmodules.jcr.jackrabbit.LocalTransactionManager">
            <property name="sessionFactory" ref="jcrSessionFactory"/>
        </bean>
    
        <bean id="repository" class="org.springmodules.jcr.jackrabbit.RepositoryFactoryBean">
            <!-- normal factory beans params -->
            <property name="configuration" value="classpath:jackrabbit-repo.xml"/>
            <!-- use the target folder which will be cleaned  -->
            <!--property name="homeDir" value="file:./repo"/-->
        </bean>
    
        <!-- transaction proxy for Jcr services/facades -->
        <bean id="txProxyTemplate" abstract="true"
              class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
            <property name="proxyTargetClass" value="true"/>
            <property name="transactionManager" ref="jcrTransactionManager"/>
            <property name="transactionAttributes">
                <props>
                    <prop key="save*">PROPAGATION_REQUIRED</prop>
                    <prop key="*">PROPAGATION_REQUIRED, readOnly</prop>
                </props>
            </property>
        </bean>
    
        <bean id="jcrTemplate" class="org.springmodules.jcr.JcrTemplate">
            <property name="sessionFactory" ref="sessionFactory"/>
            <property name="allowCreate" value="true"/>
        </bean>
        <bean id="jcrService" parent="txProxyTemplate">
            <property name="target">
                <bean class="com.acula.dao.jackrabbit.JackrabbitDaoImpl">
                    <property name="template" ref="jcrTemplate"/>
                </bean>
            </property>
        </bean>
    Error:

    Code:
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jcrSessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Cannot create inner bean 'javax.jcr.SimpleCredentials#f6d9ca' while setting bean property 'credentials'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'javax.jcr.SimpleCredentials#f6d9ca' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Cannot create inner bean 'password$created#c1abcf' while setting constructor argument with index 1; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'password$created#c1abcf' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Initialization of bean failed; nested exception is org.aspectj.weaver.BCException: Do not call nameToSignature with something that looks like a signature (descriptor): '[C' 
        Caused by: 
        org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'javax.jcr.SimpleCredentials#f6d9ca' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Cannot create inner bean 'password$created#c1abcf' while setting constructor argument with index 1; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'password$created#c1abcf' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Initialization of bean failed; nested exception is org.aspectj.weaver.BCException: Do not call nameToSignature with something that looks like a signature (descriptor): '[C' 
        Caused by: 
        org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'password$created#c1abcf' defined in ServletContext resource [/WEB-INF/applicationContext-jcr.xml]: Initialization of bean failed; nested exception is org.aspectj.weaver.BCException: Do not call nameToSignature with something that looks like a signature (descriptor): '[C' 
        Caused by: 
        org.aspectj.weaver.BCException: Do not call nameToSignature with something that looks like a signature (descriptor): '[C' 
         at org.aspectj.weaver.UnresolvedType.nameToSignature(UnresolvedType.java:741) 
         at org.aspectj.weaver.UnresolvedType.forName(UnresolvedType.java:311) 
         at org.aspectj.weaver.World.resolve(World.java:313) 
         at org.aspectj.weaver.internal.tools.PointcutExpressionImpl.couldMatchJoinPointsInType(PointcutExpressionImpl.java:76) 
         at org.springframework.aop.aspectj.AspectJExpressionPointcut.matches(AspectJExpressionPointcut.java:179) 
         at org.springframework.aop.support.AopUtils.canApply(AopUtils.java:171) 
         at org.springframework.aop.support.AopUtils.canApply(AopUtils.java:231) 
    ...
    Anybody can help me?

  • #2
    I'm not sure what the problem but it doesn't seem to be jackrabbit. I assume that the bean definition for doing the conversion between the String and a char array (if you're using Spring 1.2.8+ there is not need for it since there is already a a property editor which does the conversion) raises some problems but I'm not sure why exactly.

    What is your AOP config ? btw, isolate the problem (defining just 1-2 beans) and try also the AOP forum.

    Comment

    Working...
    X