Open raygao opened 11 years ago
If you're getting the same results I am, it's because the mvn install step is failing. Not sure why that is yet.
Okay, so I cleared out my previous maven install and was able to build; I was then able to discern the correct group ID from the maven installation.
What worked for me was:
karaf@root> install mvn:starter/producer/1.0 Bundle ID: 70 karaf@root> install mvn:starter/consumer/1.0 Bundle ID: 71 karaf@root> list START LEVEL 100 , List Threshold: 50 ID State Blueprint Level Name [ 70] [Installed ] [ ] [ 80] producer (1.0.0) [ 71] [Installed ] [ ] [ 80] consumer (1.0.0)
From here, you can start the bundles and continue the exercise.
Thanks, that works. But, it's better to load the jar file with the webconsole. features:install webconsole
Really? Why do you think so? Personally I like the cli.
On Tuesday, February 19, 2013, Raymond Gao wrote:
Thanks, that works. But, it's better to load the jar file with the webconsole. features:install webconsole
— Reply to this email directly or view it on GitHubhttps://github.com/seijoed/osgi-starter/issues/1#issuecomment-13777666.
The problem is 'there is no indication, from which directory, I should run those commands from'. I tried to start consumer from both $root/consumer and $root/producer directory. And, both time, it failed. The web console on the other hand works every time.
Raymond, they should both be built from the root directory.
Sorry about that. What failure do you get?
On Feb 19, 2013, at 8:40 AM, Raymond Gao notifications@github.com wrote:
The problem is 'there is no indication, from which directory, I should run those commands from'. I tried to start consumer from both $root/consumer and $root/producer directory. And, both time, it failed. The web console on the other hand works every time.
— Reply to this email directly or view it on GitHub.
There is no difference in using the web-console or the CLI. The cli is commonly more used.
On Feb 19, 2013, at 8:21 AM, Raymond Gao notifications@github.com wrote:
Thanks, that works. But, it's better to load the jar file with the webconsole. features:install webconsole
— Reply to this email directly or view it on GitHub.
I did the following:
karaf@root> install mvn:starter/producer/1.0 Bundle ID: 186 karaf@root> install mvn:starter/consumer/1.0 Bundle IDs: Error executing command: Error installing bundles: Unable to install bundle mvn:starter/consumer/1.0
The directory was: /home/rgao/workspace/osgi-starter
It was the root of the cloned github tarball.
Did you build and install the bundles?
mvn clean install This will put the bundles into your Maven repository.
On Feb 19, 2013, at 9:17 AM, Raymond Gao notifications@github.com wrote:
I did the following:
karaf@root> install mvn:starter/producer/1.0 Bundle ID: 186 karaf@root> install mvn:starter/consumer/1.0 Bundle IDs: Error executing command: Error installing bundles: Unable to install bundle mvn:starter/consumer/1.0
The directory was: /home/rgao/workspace/osgi-starter
It was the root of the cloned github tarball.
— Reply to this email directly or view it on GitHub.
FWIW, I ran karaf from the $karaf-install-root/bin dir, and it found the maven-generated jars just fine. So I ran the 'mvn install', after moving some old m2 config stuff out, and then ran karaf from $karaf-install-root/bin.
BTW, after I got everthing working command line, I imported the maven projects into eclipse and ran them successfully there too. The problem I originally had was the URIs used to access the new bundles, and the new URIs fixed that.
On Tue, Feb 19, 2013 at 9:18 AM, Johan Edstrom notifications@github.comwrote:
Did you build and install the bundles?
mvn clean install This will put the bundles into your Maven repository.
On Feb 19, 2013, at 9:17 AM, Raymond Gao notifications@github.com wrote:
I did the following:
karaf@root> install mvn:starter/producer/1.0 Bundle ID: 186 karaf@root> install mvn:starter/consumer/1.0 Bundle IDs: Error executing command: Error installing bundles: Unable to install bundle mvn:starter/consumer/1.0
The directory was: /home/rgao/workspace/osgi-starter
It was the root of the cloned github tarball.
— Reply to this email directly or view it on GitHub.
— Reply to this email directly or view it on GitHubhttps://github.com/seijoed/osgi-starter/issues/1#issuecomment-13781133.
What maven version do you have? Technically maven should pick the latest build in your repo.
On Feb 19, 2013, at 9:27 AM, Chris Lamb notifications@github.com wrote:
FWIW, I ran karaf from the $karaf-install-root/bin dir, and it found the maven-generated jars just fine. So I ran the 'mvn install', after moving some old m2 config stuff out, and then ran karaf from $karaf-install-root/bin.
BTW, after I got everthing working command line, I imported the maven projects into eclipse and ran them successfully there too. The problem I originally had was the URIs used to access the new bundles, and the new URIs fixed that.
On Tue, Feb 19, 2013 at 9:18 AM, Johan Edstrom notifications@github.comwrote:
Did you build and install the bundles?
mvn clean install This will put the bundles into your Maven repository.
On Feb 19, 2013, at 9:17 AM, Raymond Gao notifications@github.com wrote:
I did the following:
karaf@root> install mvn:starter/producer/1.0 Bundle ID: 186 karaf@root> install mvn:starter/consumer/1.0 Bundle IDs: Error executing command: Error installing bundles: Unable to install bundle mvn:starter/consumer/1.0
The directory was: /home/rgao/workspace/osgi-starter
It was the root of the cloned github tarball.
— Reply to this email directly or view it on GitHub.
— Reply to this email directly or view it on GitHubhttps://github.com/seijoed/osgi-starter/issues/1#issuecomment-13781133.
— Reply to this email directly or view it on GitHub.
running Maven 3.0.4
I have same question, when I do osgi:install in shell ,it's failed, but i do it success in web console.
This is probably a bit outdated. The iTests are causing the initial mvn clean install
to fail. Some versioning error within one of the iTests. I was able to successfully build after removing the tests, so it's clear this should probably be updated.
I bought your book. But, I am lost. You said, run :
karaf@root> install -s mvn:com.packt.osgi.starter/1.0.0/producer Bundle IDs:
Error executing command: Error installing bundles: Unable to install bundle mvn:com.packt.osgi.starter/1.0.0/producer
What is the problem? The book is very poorly written, I can't follow it!!!! Should I ask for a refund?