Results 1 to 4 of 4

Thread: xslt transformer

  1. #1

    Default xslt transformer

    Hi guys,
    I have a problem using transformer.
    I have to apply a xslt transformation. I got it with stylesheet version 1.0 in the following way:

    <int-xml:xslt-transformer input-channel="input-channel"
    output-channel="output-channel" xsl-resource="classpath:/my.xsl" />

    but if I have a stylesheet 2.0 I receive an error because spring integration behind the scene uses xalan that doesn't support xpath2.
    To avoid that I tried to use a different transformer, saxon that is xslt 2.0 compliant, but I received the following error.
    <int-xml:xslt-transformer input-channel="input-channel"
    output-channel="output-channel" xsl-resource="classpath:/my2-0.xsl" result-transformer="net.sf.saxon.TransformerFactoryImpl" />


    Exception in thread "main" org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'org.springframework.integration.xml.transformer.X sltPayloadTransformer#0': Could not resolve matching constructor (hint: specify index/type/name arguments for simple parameters to avoid type ambiguities)
    at org.springframework.beans.factory.support.Construc torResolver.autowireConstructor(ConstructorResolve r.java:250)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.autowireConstructor(Abs tractAutowireCapableBeanFactory.java:1035)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBeanInstance(Abst ractAutowireCapableBeanFactory.java:939)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.doCreateBean(AbstractAu towireCapableBeanFactory.java:485)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:456)
    at org.springframework.beans.factory.support.Abstract BeanFactory$1.getObject(AbstractBeanFactory.java:2 94)
    at org.springframework.beans.factory.support.DefaultS ingletonBeanRegistry.getSingleton(DefaultSingleton BeanRegistry.java:225)
    at org.springframework.beans.factory.support.Abstract BeanFactory.doGetBean(AbstractBeanFactory.java:291 )


    Any help will be appreciate.

    Thank you.
    Mariateresa

  2. #2
    Join Date
    Aug 2005
    Location
    Atlanta
    Posts
    124

    Default

    Hi Mariateresa,

    Could you look at our XQuery adapters at: https://github.com/SpringSource/spri...gration-xquery?

    Since XQuery is a super-set of XPath 2.0 maybe it can solve your issue. If not, please open Jira at:

    https://jira.springsource.org/browse/INT

    and we will try to provide XSLT 2.0 support as soon as possible.

    Thanks!

    Cheers,

    Gunnar
    Gunnar Hillert
    SpringSource/VMWare, Spring Integration team
    SpringSource Team - Spring Training, Consulting, and Support - "From the Source"
    http://twitter.com/ghillert
    http://blog.hillert.com/
    http://blog.springsource.com/author/ghillert/

  3. #3

    Default

    Hi Gunnar,
    thanks for your answer.

    I believe spring xquery adapter doesn't fit my needs because I should provide to the transformer an xq file but I have just my xsl file.
    Do you have any suggestion?

  4. #4

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •