Uploaded image for project: 'OpenEJB'
  1. OpenEJB
  2. OPENEJB-1258

Boolean conversion problem in ejb-jar.xml

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.3
    • Fix Version/s: 3.1.3
    • Component/s: deployment
    • Labels:
      None

      Description

      The ejb-jar_2_0.dtd allows "True or "False" as the values for the "reentrant" property. The ejb-jar_2.1.xsd (and later) allows "true" or "false" as the values for this property. Since the case of the values is different this can cause a problem when upconverting an old ejb-jar.xml to the latest schema representation. Specifically, I've ran into the following error:

      Caused by: javax.xml.bind.UnmarshalException: String "False" is not valid boolean value.

      • with linked exception:
        [java.lang.IllegalArgumentException: String "False" is not valid boolean value.]
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.handleEvent(UnmarshallingContext.java:642)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.handleError(UnmarshallingContext.java:671)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.handleError(UnmarshallingContext.java:667)
        at com.sun.xml.bind.v2.runtime.unmarshaller.Loader.handleParseConversionException(Loader.java:267)
        at com.sun.xml.bind.v2.runtime.unmarshaller.TextLoader.text(TextLoader.java:69)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallingContext.text(UnmarshallingContext.java:494)
        at com.sun.xml.bind.v2.runtime.unmarshaller.SAXConnector.processText(SAXConnector.java:179)
        at com.sun.xml.bind.v2.runtime.unmarshaller.SAXConnector.endElement(SAXConnector.java:152)
        at org.xml.sax.helpers.XMLFilterImpl.endElement(XMLFilterImpl.java:546)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:601)
        at com.sun.org.apache.xerces.internal.impl.dtd.XMLNSDTDValidator.endNamespaceScope(XMLNSDTDValidator.java:263)
        at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2028)
        at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:901)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1774\
        )
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerIm\
        pl.java:2930)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)
        at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)
        at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:807)
        at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
        at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:107)
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
        at org.xml.sax.helpers.XMLFilterImpl.parse(XMLFilterImpl.java:333)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:211)
        at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:184)
        at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:214)
        at org.apache.openejb.jee.JaxbJavaee.unmarshal(JaxbJavaee.java:104)
        at org.apache.openejb.config.ReadDescriptors.readEjbJar(ReadDescriptors.java:370)
        ... 46 more
        Caused by: java.lang.IllegalArgumentException: String "False" is not valid boolean value.
        at com.sun.xml.bind.DatatypeConverterImpl._parseBoolean(DatatypeConverterImpl.java:317)
        at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl$14.parse(RuntimeBuiltinLeafInfoImpl.java:649)
        at com.sun.xml.bind.v2.model.impl.RuntimeBuiltinLeafInfoImpl$14.parse(RuntimeBuiltinLeafInfoImpl.java:652)
        at com.sun.xml.bind.v2.runtime.unmarshaller.TextLoader.text(TextLoader.java:65)
        ... 70 more

        Attachments

          Activity

            People

            • Assignee:
              gawor@mcs.anl.gov Jarek Gawor
              Reporter:
              gawor@mcs.anl.gov Jarek Gawor
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: