如何从本地Maven存储库部署karaf功能? [英] How to deploy a karaf feature from a local maven repository?

查看:210
本文介绍了如何从本地Maven存储库部署karaf功能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经为karaf(4.0.1)创建了第一个项目.到目前为止,我有以下内容:

I've created by first project for karaf (4.0.1). So far I've got the following:

  • 使用maven-bundle-plugin构建的应用程序捆绑包.将会有更多...
  • 使用karaf-maven-plugin创建的karaf功能.
  • 使用相同插件创建的karaf组件
  • an application bundle built with the maven-bundle-plugin. There are going to be more...
  • a karaf feature created with the karaf-maven-plugin.
  • a karaf-assembly created with the same plugin

因此,我准备交付给客户-但是我在开发过程中陷入了困境. 这个问题回答了我几乎所有的问题其余的问题保存一个:

So I'm ready to deliver to the customer - but I'm stuck over the development process. This question answered almost all my remaining questions save one:

通过运行maven install构建项目之后,我认为我应该能够使用命令feature:install之类的功能在本地karaf实例上运行我的功能.

After having built my project by running maven install I think I should be able to to get my feature running on a local karaf instance using something like the command feature:install.

我可以使用bundle:install从本地Maven安装我的应用程序捆绑包,但是我可以自己管理依赖项了.

I can install my application bundle from local maven by using bundle:install but then I'm down to managing dependencies myself.

bundle:install对我的本地Maven存储库有效而feature:install无效时,真的不知道.

Really can't figure out while bundle:install works against my local maven repository and feature:install doesn't.

推荐答案

找到了解决方案这里.我知道我需要feature:repo-add-但是该命令的名称和

Found the soloution here. I knew I'd need feature:repo-add - but the name of this command and the official documentation sent me thinking in entirely the wrong direction.

此命令不会添加(Maven)存储库,但是会在Maven存储库链中添加功能的位置(因此,我认为旧名称addUrl可能更容易理解).

This command does not add a (maven) repository, but adds the location of a feature in the maven repository chain (so I'm thinking the old name addUrl was probably easier to understand).

无论如何-使用feature:repo-add mvn:<groupId>/<artifactId>/<version>/xml/features可行.

这篇关于如何从本地Maven存储库部署karaf功能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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