https://github.com/noherczeg/simpleosgi
Basic OSGi example project
https://github.com/noherczeg/simpleosgi
example java java-8 karaf osgi
Last synced: 10 months ago
JSON representation
Basic OSGi example project
- Host: GitHub
- URL: https://github.com/noherczeg/simpleosgi
- Owner: noherczeg
- Created: 2017-06-28T21:01:50.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-07-03T17:00:44.000Z (over 8 years ago)
- Last Synced: 2025-02-01T16:48:46.314Z (about 1 year ago)
- Topics: example, java, java-8, karaf, osgi
- Language: Java
- Size: 9.77 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Simple OSGi
## Build
```
mvn clean install
```
## Start Karaf
```
karaf clean debug
```
Optionally you can install the webconsole feature which gives a nice admin
panel where you can check and manage bundles and features.
```
feature:install webconsole
```
The web console is available by default at `http://localhost:8181/system/console`.
The default username and password is `karaf`.
## Deployment
The Declarative Services annotations require an implementation to work. Therefore
we need to install one. The standard is `scr`.
```
feature:install scr
```
Then we need to register the repository/repositories to our features:
```
feature:repo-add mvn:hu.noherczeg/hu.noherczeg.simpleosgi.api/1.0.0-SNAPSHOT/xml/features
feature:repo-add mvn:hu.noherczeg/hu.noherczeg.simpleosgi.service/1.0.0-SNAPSHOT/xml/features
```
Lastly we can install said features:
```
feature:install noherczeg-simpleosgi-api
feature:install noherczeg-simpleosgi-service
```
## Further reading
- [Karaf Container](http://karaf.apache.org/manual/latest/)