我们有一个 Karaf OSGi 服务器,它有一个捆绑包,用于使用 CAMEL/CXF 传入的 Web 请求。
自周末以来,当服务器启动时,捆绑包一直出现以下错误:
Unable to start blueprint container for bundle uniworks-camel-web-services/2.3.5 org.xml.sax.SAXParseException; systemId: http://cxf.apache.org/schemas/configuration/cxf-beans.xsd; lineNumber: 1; columnNumber: 1; Premature end of file.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203)[:1.8.0_221]
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177)[:1.8.0_221] at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400)[:1.8.0_221]
.. etc. (I can supply more of the stack trace if required)
这方面的代码没有改变,即使是相同服务器的旧版本现在也有这个问题。
它已经阻止了我们的一位客户死在他们的轨道上,因此我们将不胜感激任何帮助。
更新:我们将 blueprint-core 的版本更新为 1.6.2,这使得捆绑包可以正常启动。显然,这个版本并不坚持需要互联网来检查 XML。
我们在 Karaf 服务器上执行的步骤是:
- 下载
org.apache.aries.blueprint.core-1.6.2.jar
并放入文件夹system/org/apache/aries/blueprint/org.apache.aries.blueprint.core/1.6.2/
- 将“blueprint-core”的版本更改
system/org/apache/karaf/features/standard/4.0.5/standard-4.0.5-features.xml
为 1.6.2 overrides.properties
在 Karaf文件夹中创建了一个文件,其中etc
包含以下行:mvn:org.apache.aries.blueprint/org.apache.aries.blueprint.core/1.6.2
Karaf 服务器重新启动然后选择新版本。