Quantcast

cvc-complex-type.2.4.a: Invalid content was found starting with element * * 'filter'.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

cvc-complex-type.2.4.a: Invalid content was found starting with element * * 'filter'.

abhilashaS
Hi i m writing my custom filter &getting following error.Let me know y

1)Config file
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns="http://www.mulesource.org/schema/mule/core/2.2"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns:spring="http://www.springframework.org/schema/beans"
      xmlns:file="http://www.mulesource.org/schema/mule/file/2.2"
      xmlns:vm="http://www.mulesource.org/schema/mule/vm/2.2"
      xmlns:stdio="http://www.mulesource.org/schema/mule/stdio/2.2"
      xsi:schemaLocation="
          http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
          http://www.mulesource.org/schema/mule/file/2.2 http://www.mulesource.org/schema/mule/file/2.2/mule-file.xsd
          http://www.mulesource.org/schema/mule/core/2.2 http://www.mulesource.org/schema/mule/core/2.2/mule.xsd
          http://www.mulesource.org/schema/mule/vm/2.2 http://www.mulesource.org/schema/mule/vm/2.2/mule-vm.xsd
          http://www.mulesource.org/schema/mule/core/2.2 http://www.mulesource.org/schema/mule/core/2.2/mule.xsd
          http://www.mulesource.org/schema/mule/stdio/2.2 http://www.mulesource.org/schema/mule/stdio/2.2/mule-stdio.xsd">

         <custom-filter name="MyFilter"
                        class="org.mule.example.hello.Filter"/> 
                 
                 <file:connector name="FileConnector" >
              <file:expression-filename-parser/>
        </file:connector>
       
               
        <stdio:connector name="stdioConnector" messageDelayTime="1234"
         promptMessage="Welcome to File to IO example" resourceBundle="dummy-messages" />
       
        <model name="filetoio">
        <service name="filetransport">
        <inbound>
       
        <file:inbound-endpoint path="C:/File1" connector-ref="FileConnector"/>
     
        </inbound>

       
        <outbound>
       
        <filtering-router>
        <filter ref="MyFilter">
        <stdio:outbound-endpoint system="OUT">
       
        </stdio:outbound-endpoint>
        <catch-all-strategy />
        </filter>
        </filtering-router>
       
       
        </outbound>
       
        </service>
    </model>
   
   
   
</mule>

2).Error is
INFO  2010-05-21 16:07:20,750 [main] org.mule.MuleServer: Mule Server initializing...
INFO  2010-05-21 16:07:21,187 [main] org.mule.config.spring.MuleApplicationContext: Refreshing org.mule.config.spring.MuleApplicationContext@1c80b01: display name [org.mule.config.spring.MuleApplicationContext@1c80b01]; startup date [Fri May 21 16:07:21 GMT+05:30 2010]; root of context hierarchy
ERROR 2010-05-21 16:07:22,250 [main] org.mule.config.spring.SpringXmlConfigurationBuilder: Configuration with "org.mule.config.spring.SpringXmlConfigurationBuilder" failed.
org.mule.api.lifecycle.InitialisationException: Initialisation Failure: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:76)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:110)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:73)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:112)
        at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:58)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:177)
        at org.mule.MuleServer.initialize(MuleServer.java:348)
        at org.mule.MuleServer.run(MuleServer.java:255)
        at org.mule.MuleServer.start(MuleServer.java:242)
        at org.mule.MuleServer.main(MuleServer.java:121)
Caused by: org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:404)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
        at org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:105)
        at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
        at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
        at org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:90)
        at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:68)
        ... 13 more
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
        at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Source)
        at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
        at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
        ... 22 more
ERROR 2010-05-21 16:07:22,250 [main] org.mule.config.builders.AutoConfigurationBuilder: Configuration with "org.mule.config.builders.AutoConfigurationBuilder" failed.
org.mule.api.config.ConfigurationException: Initialisation Failure: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected. (org.mule.api.lifecycle.InitialisationException)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:112)
        at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:58)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:177)
        at org.mule.MuleServer.initialize(MuleServer.java:348)
        at org.mule.MuleServer.run(MuleServer.java:255)
        at org.mule.MuleServer.start(MuleServer.java:242)
        at org.mule.MuleServer.main(MuleServer.java:121)
Caused by: org.mule.api.lifecycle.InitialisationException: Initialisation Failure: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:76)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:110)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:73)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        ... 10 more
Caused by: org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:404)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
        at org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:105)
        at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
        at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
        at org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:90)
        at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:68)
        ... 13 more
Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
        at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Source)
        at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
        at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
        ... 22 more
ERROR 2010-05-21 16:07:22,265 [main] org.mule.MuleServer:
********************************************************************************
Message               : Initialisation Failure: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
Type                  : org.mule.api.lifecycle.InitialisationException
Code                  : MULE_ERROR-72085
JavaDoc               : http://www.mulesource.org/docs/site/current2/apidocs/org/mule/api/lifecycle/InitialisationException.html
Object                : org.mule.config.spring.SpringRegistry@1786286
********************************************************************************
Exception stack is:
1. cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected. (org.xml.sax.SAXParseException)
  org.apache.xerces.util.ErrorHandlerWrapper:-1 (null)
2. Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected. (org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException)
  org.springframework.beans.factory.xml.XmlBeanDefinitionReader:404 (null)
3. Initialisation Failure: Line 39 in XML document from URL [file:/C:/Amuleworkspace/HttpHello/conf/Filter.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected. (org.mule.api.lifecycle.InitialisationException)
  org.mule.registry.AbstractRegistry:76 (http://www.mulesource.org/docs/site/current2/apidocs/org/mule/api/lifecycle/InitialisationException.html)
********************************************************************************
Root Exception stack trace:
org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'filter'. One of '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoint}' is expected.
        at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
        at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown Source)
        at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Source)
        at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
        at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
        at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
        at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
        at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
        at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
        at org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:105)
        at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
        at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
        at org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:90)
        at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:68)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:110)
        at org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:73)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.config.builders.AutoConfigurationBuilder.autoConfigure(AutoConfigurationBuilder.java:112)
        at org.mule.config.builders.AutoConfigurationBuilder.doConfigure(AutoConfigurationBuilder.java:58)
        at org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
        at org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
        at org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:177)
        at org.mule.MuleServer.initialize(MuleServer.java:348)
        at org.mule.MuleServer.run(MuleServer.java:255)
        at org.mule.MuleServer.start(MuleServer.java:242)
        at org.mule.MuleServer.main(MuleServer.java:121)

********************************************************************************

ERROR 2010-05-21 16:07:22,265 [main] org.mule.MuleServer:
********************************************************************************
* A Fatal error has occurred while the server was running:                     *
* cvc-complex-type.2.4.a: Invalid content was found starting with element      *
* 'filter'. One of                                                             *
* '{"http://www.mulesource.org/schema/mule/core/2.2":abstract-outbound-endpoin *
* t}' is expected. (org.xml.sax.SAXParseException)                             *
*                                                                              *
* The error is fatal, the system must shutdown                                 *
********************************************************************************

Loading...