0

我正在升级到 Fuse 7.3 并在使用 CXF 的任何路线中遇到新错误。

  Blueprint bundle ruleEngineService/5.0.2 is waiting for namespace
  handlers [http://camel.apache.org/schema/blueprint]

根据所有文档,我的 blueprint.xml 包含正确的架构位置。例如。关联

<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.0.0"
xmlns:tx="http://aries.apache.org/xmlns/transactions/v1.2.0"
xmlns:camel="http://camel.apache.org/schema/blueprint"
xmlns:cxf="http://camel.apache.org/schema/blueprint/cxf"

xsi:schemaLocation="
http://www.osgi.org/xmlns/blueprint/v1.0.0 http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd"> 

自从它在 Fuse 7.0.0 中工作以来,我没有太大变化。

已安装功能:

  cxf                                      | 3.2.7.fuse-731004-redhat-00003  | x        | Started     | cxf-3.2.7.fuse-731004-redhat-00003            |

  camel-cxf                                | 2.21.0.fuse-731003-redhat-00003 | x        | Started     | camel-2.21.0.fuse-731003-redhat-00003         |

将此蓝图与正在解决的蓝图区别开来的是:

<cxf:cxfEndpoint id="myEndpoint" ...>

<bean id="myRoute" class="com.application.CxfCamelRoute" />

<camelContext xmlns="http://camel.apache.org/schema/blueprint" id="serviceRoutes">
    <routeBuilder ref="myRoute" />
</camelContext>

其中 CxfCamelRoute 包含对cxf://bean:myEndpoint?serviceClass="..."

关于蓝图功能:

admin@root()> features:list | grep blueprint
kie-aries-blueprint                      | 7.11.0.Final                    |          | Uninstalled | karaf-features-core-droolsjbpm-7.11.0.Final   | KIE Aries Blueprint
camel-blueprint                          | 2.23.2.fuse-740006              |          | Uninstalled | camel-2.23.2.fuse-740006                      |
camel-blueprint                          | 2.21.0.fuse-731003-redhat-00003 | x        | Started     | camel-2.21.0.fuse-731003-redhat-00003         |
aries-blueprint-spring                   | 4.3.20.RELEASE_1                |          | Uninstalled | spring-legacy-4.2.0.fuse-731003-redhat-00003  |
aries-blueprint                          | 4.2.0.fuse-731003-redhat-00003  | x        | Started     | standard-4.2.0.fuse-731003-redhat-00003       | Aries Blueprint

会不会是aries-blueprint和camel-blueprint之间的冲突?

我的想法不多了。

4

2 回答 2

0

好的,我似乎已经解决了。

features:addurl mvn:org.kie/kie-karaf-features/7.11.0.Final/xml/features在做任何其他事情之前,我添加了 KIE ( ) 的 repo 。订单更改解决了我的问题。似乎 KIE 7.11.0.Final 添加了以下存储库:

mvn:org.apache.camel.karaf/apache-camel/RELEASE/xml/features
mvn:org.apache.cxf.karaf/apache-cxf/3.2.7.fuse-sb2-740011/xml/features

namehandler 问题可能是由于 Fuse 7.3 库和最新的 camel/cxf RELEASE 版本之间的一些冲突。

对我来说,这感觉像是一个错误,让 KIE 7.11.0.Final 使用 RELEASE 功能。这显然会带来不好的后果。但我不知道另一种方法可以让feature:install kie我的 Karaf 访问。

于 2019-07-04T15:20:42.593 回答
0

切勿RELEASE在 Maven 坐标中使用。在期待 Camel 2 时,您甚至可以使用 Camel 3。(永远不要使用LATEST任何一种)。

如果您使用 Fuse 安装 KIE 功能,则不应安装mvn:org.kie/kie-karaf-features/7.11.0.Final/xml/features

首先,您必须从 Fuse 安装为 KIE 提供功能依赖项的桥接功能:

karaf@root()> feature:repo-add mvn:org.jboss.fuse.features/rhba-features/7.6.0.fuse-760014/xml/features
Adding feature url mvn:org.jboss.fuse.features/rhba-features/7.6.0.fuse-760014/xml/features

然后你必须安装 Kie 功能的 Fuse 变体。不是这个,而是这个

中的描述kie-karaf-features-7.11.0.Final-features-fuse.xml比当前的 Fuse 有点旧,因为功能 artifactId 已更改:

   In order to install the below features into Fuse 7, target runtime needs to provide these features:
    - drools7-dependencies
    - jbpm7-dependencies
    - optaplanner-dependencies
    - kie7-remote-dependencies
    - db-dependencies
    - hibernate-dependencies
    - hibernate-validator-dependencies
   These features are contained in some repository not referenced explicitly with <repository> (loose coupling).
   Fuse 7 specific repository is 'mvn:org.jboss.fuse.features/brms-features/VERSION/xml/features'

所以这里是命令:

karaf@root()> feature:repo-add mvn:org.kie/kie-karaf-features/7.11.0.Final/xml/features-fuse
Adding feature url mvn:org.kie/kie-karaf-features/7.11.0.Final/xml/features-fuse
karaf@root()> feature:list|grep kie
kie                                      │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-core-droolsjbpm-7.11.0.Final             │ KIE API
kie-ci                                   │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-core-droolsjbpm-7.11.0.Final             │ KIE CI
kie-spring                               │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-core-droolsjbpm-7.11.0.Final             │ KIE Spring
kie-aries-blueprint                      │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-core-droolsjbpm-7.11.0.Final             │ KIE Aries Blueprint
kie-camel                                │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-core-droolsjbpm-7.11.0.Final             │
kie-dmn                                  │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-fuse-droolsjbpm-7.11.0.Final             │ Kie DMN
kie-server-client                        │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-fuse-droolsjbpm-7.11.0.Final             │ KIE Server Client
servlet-api-kie                          │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-fuse-droolsjbpm-7.11.0.Final             │
kie-pmml                                 │ 7.11.0.Final                    │          │ Uninstalled │ karaf-features-fuse-droolsjbpm-7.11.0.Final             │
kie7-remote-dependencies                 │ 0.0.0                           │          │ Uninstalled │ fuse-features-dependencies-droolsjbpm-7.6.0.fuse-760014 │
于 2020-03-06T09:13:28.063 回答