从 opendaylight-startup-archetype 构建的 OpenDaylight Oxygen Deploy 应用程序 [英] OpenDaylight Oxygen Deploy app built from opendaylight-startup-archetype

查看:32
本文介绍了从 opendaylight-startup-archetype 构建的 OpenDaylight Oxygen Deploy 应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

开放日光氧气
Maven 3.3.9
Ubuntu 16.04
卡拉夫 4

OpenDaylight Oxygen
Maven 3.3.9
Ubuntu 16.04
karaf 4

~/.m2/settings.xml - cp -n ~/.m2/settings.xml{,.orig} ;wget -q -O - https://raw.githubusercontent.com/opendaylight/odlparent/master/settings.xml >~/.m2/settings.xml

~/.m2/settings.xml - cp -n ~/.m2/settings.xml{,.orig} ; wget -q -O - https://raw.githubusercontent.com/opendaylight/odlparent/master/settings.xml > ~/.m2/settings.xml

用于创建骨架的过程

mvn archetype:generate -DgroupId=org.opendaylight.controller -DartifactId=testing -Dcopyright="None" -DclassPrefix="\${artifactId.substring(0,1).toUpperCase()}\${artifactId.substring(1)}" -DarchetypeGroupId=org.opendaylight.archetypes -DarchetypeArtifactId=opendaylight-startup-archetype -DarchetypeVersion=1.1.0-SNAPSHOT -DinteractiveMode=false

mvn clean install -Dcheckstyle.skip

我正在尝试构建一个示例应用程序并将其部署在单独的 ODL 实例 (karaf 4) 上.我在任何地方都找不到对此的有效答案.

I'm trying to build a sample app and deploy it on a separate instance of ODL (karaf 4). I cannot find a working answer to this anywhere.

我已经尝试将 PROJECT/karaf/target/assembly/system/org/opendaylight/controller 的内容复制到另一个 ODL 实例上的等效文件夹中.然后使用 feature:add-repo 添加功能.它能够检测到插件,但功能:安装 odl-testing 安装失败.

I've tried copying the contents of PROJECT/karaf/target/assembly/system/org/opendaylight/controller to the equivalent folder on the other ODL instance. Then used feature:add-repo to add the feature. It was able to detect the plugin, but feature:install odl-testing failed to install.

任何帮助将不胜感激.

推荐答案

当您说feature:install odl-testing failed to install"时,您并没有显示您遇到的确切故障,但仅供参考,大多数人实际上并没有使用你试图开始工作的过程......在技术上可以单独构建你的新包和 Karaf 功能,然后手动添加它以部署在单独的 ODL 实例上......但我知道的每个项目都发现更容易让构建生成一个随时可用的 Karaf 发行版.

You are not showing what exact failure you hit when you say "feature:install odl-testing failed to install", but FYI most people don't actually use the process you are trying to get working.. it's technically possible to build your new bundles and Karaf feature separately and then manually add it to deploy on a separate instance of ODL... but every project I know of finds it easier to just let the build produce a ready-to-use Karaf distribution.

您可能已经在 karaf/target/assembly 中看到过 ODL 原型的发行版 (此处记录 BTW;请注意,在刚刚发布的最新 Fluorine 版本中,archetypeGroupId 的使用更改为 org.opendaylight.archetypes)产生?

You have probably seen the distro in karaf/target/assembly which the the ODL archetype (documented here BTW; note the use of archetypeGroupId changed to org.opendaylight.archetypes in the just released latest Fluorine version) produces?

因此,您可以做的只是添加您可能希望将您的功能添加为自定义功能的依赖项的基本"功能.有了这个,您就可以获得准备运行的自定义发行版,包括您的新代码和您想要包含的任何其他 ODL 功能.

So what you can do instead is to just add your "base" feature which you are presumably wanting to add your feature into as a dependency to your custom feature. With this, you get your ready-to-run custom distribution including your new code and whatever other ODL features you want to include.

这篇关于从 opendaylight-startup-archetype 构建的 OpenDaylight Oxygen Deploy 应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆