org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected.

Spring JIRA | Iwein Fuld | 9 years ago
  1. 0

    It appears that selectors and concurrency are mutually exclusive in certain cases. For example using: <endpoint input-channel="drinks" handler-ref="hotHandlerChain1"> <selector ref="hotStuffSelector" /> <concurrency core="1" max="1" /> </endpoint> Assuming that hotHandlerChain1 is a valid handler and hotStuffSelector is a valid selector this gives the following exception (stacktrace reduced): >> Exception in thread "main" org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected. at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:390) ... Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected. at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236) << But when the rejection limit is reached the hint is to increase concurrency in the handler. This is contradictory, so it leads to believe it is unintentional behavior. Suggested fix is to support both concurrency and selector together.

    Spring JIRA | 9 years ago | Iwein Fuld
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected.
  2. 0

    It appears that selectors and concurrency are mutually exclusive in certain cases. For example using: <endpoint input-channel="drinks" handler-ref="hotHandlerChain1"> <selector ref="hotStuffSelector" /> <concurrency core="1" max="1" /> </endpoint> Assuming that hotHandlerChain1 is a valid handler and hotStuffSelector is a valid selector this gives the following exception (stacktrace reduced): >> Exception in thread "main" org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected. at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:390) ... Caused by: org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected. at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236) << But when the rejection limit is reached the hint is to increase concurrency in the handler. This is contradictory, so it leads to believe it is unintentional behavior. Suggested fix is to support both concurrency and selector together.

    Spring JIRA | 9 years ago | Iwein Fuld
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected.
  3. 0

    how can i access css and images in spring mvc

    Stack Overflow | 2 years ago | bablu
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 18 in XML document from ServletContext resource [/WEB-INF/spring-servlet.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 18; columnNumber: 32; cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'mvc:default-servlet-handler'.
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    org.xml.sax.SAXParseException ... no declaration can be found for element 'context:component-scan'

    Stack Overflow | 3 years ago | SzZ
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 19 in XML document from class path resource [META-INF/spring/app-context1.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'context:component-scan'.
  6. 0

    Camel/Spring giving the error: "The Prefix broker for element 'broker:broker' is not bound" when declaring ActiveMQ broker

    Stack Overflow | 2 years ago | user1483714
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 13 in XML document from class path resource [META-INF/spring/filecopycontext.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 13; columnNumber: 73; The prefix "broker" for element "broker:broker" is not bound.

    2 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException

      Line 33 in XML document from class path resource [cafeDemo.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'concurrency'. One of '{"http://www.springframework.org/schema/integration":selector, "http://www.springframework.org/schema/integration":handler}' is expected.

      at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions()
    2. Spring Beans
      XmlBeanDefinitionReader.doLoadBeanDefinitions
      1. org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:390)
      1 frame