Update administration / bundles (#1393)

* Update bundles.md

Update examples to show output from 3.0. Remove reference to Paper UI.

Signed-off-by: Bob Adair <bob.github@att.net>

* Fix typo

Signed-off-by: Bob Adair <bob.github@att.net>
pull/1396/head
Bob A 2020-12-28 03:19:07 -05:00 committed by GitHub
parent c04e3d743c
commit db44f6b003
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 25 additions and 21 deletions

View File

@ -7,44 +7,50 @@ title: Bundle Management
# Bundle Management
The [Karaf console](console.html) offers various commands to manage bundles. Most of these commands are not needed in the normal (non-developer) use of openHAB. However some basic commands are needed when dealing with some expert user situations like testing a binding.
The [console](console.html) offers various commands to manage bundles, among other things.
Most of these commands are not needed in the normal (non-developer) use of openHAB.
However some basic console commands may be needed when dealing with certain advanced user situations, such as when testing a newly developed or patched binding.
## List Bundles
The _bundle:list_ command returns a list of all currently installed bundles including their version.
The _bundle:list_ command returns a list of all currently installed bundles and their states, names, and versions.
The core openHAB system is composed of many bundles.
There will also be a bundle for each add-on, such a binding, that you have installed.
A state of "Active" means the bundle is running.
```text
openhab> bundle:list
START LEVEL 100 , List Threshold: 50
ID | State | Lvl | Version | Name
-----------------------------------------------------------------------------------------------------
10 | Active | 80 | 2.3.0.201506221200 | JAX-RS Gson Provider
11 | Active | 80 | 5.3.1.201602281253 | OSGi JAX-RS Connector
12 | Active | 80 | 2.3.1 | Gson
13 | Active | 80 | 18.0.0 | Guava: Google Core Libraries for Java
14 | Active | 80 | 3.0.0.v201312141243 | Google Guice (No AOP)
22 │ Active │ 80 │ 2.10.3 │ Jackson-annotations
23 │ Active │ 80 │ 2.10.3 │ Jackson-core
24 │ Active │ 80 │ 2.10.3 │ jackson-databind
25 │ Active │ 80 │ 2.10.3 │ Jackson-dataformat-YAML
26 │ Active │ 80 │ 2.10.3 │ Jackson datatype: JSR310
27 │ Active │ 80 │ 2.8.2.v20180104-1110 │ Gson: Google Json Library for Java
...
209 | Active | 80 | 2.0.0.b3 | Network Binding
209 | Active | 80 | 3.0.0 | openHAB Add-ons :: Bundles :: Network Binding
```
## Start/Stop Bundles
Stoping a bundle is done with the command _stop_ and the ID of the bundle:
Stopping a bundle is done using the command _stop_ and the ID of the bundle:
```text
openhab> bundle:stop 209
openhab> bundle:list
...
209 | Resolved | 80 | 2.0.0.b3 | Network Binding
209 | Resolved | 80 | 3.0.0 | openHAB Add-ons :: Bundles :: Network Binding
```
The _start_ command works accordingly:
Starting a bundle is done using the _start_ command and the ID of the bundle:
```text
openhab> bundle:start 209
openhab> bundle:list
...
209 | Active | 80 | 2.0.0.b3 | Network Binding
209 | Active | 80 | 3.0.0 | openHAB Add-ons :: Bundles :: Network Binding
```
## Naming Convention For Bundles
@ -59,19 +65,17 @@ where
- **prefix** is the first element to categorize the bundle.
For addons this is `org.openhab`.
- **type** is the add-on type, e.g. "binding" or "ui"
- **type** is the add-on type, e.g. "binding", "persistence", or "ui"
- **id** is the identifier for this bundle
The naming convention has many effects you may not have noticed before, but used already.
For example in the Paper UI the *sorted tabs* for all bindings are generated automatically based on the bundle naming.
In many places (e.g. logging) you will also have the **package namespace** as an identifier.
You can find it as the *Symbolic name* of the bundle with the following command:
These bundle names are used in many places in openHAB, such as in various configuration files.
Logging also makes extensive use of this **package namespace**.
You can see these names listed as the *Symbolic names* of bundles by using the ```-s``` option of _bundle:list_:
```text
openhab> bundle:list -s
ID | State | Lvl | Version | Name | Symbolic name
-----------------------------------------------------------------------------------------------------------------------
ID | State | Lvl | Version | Symbolic name
----------------------------------------------------------------------------------------------
...
209 | Active | 80 | 2.1.0 | Network Binding | org.openhab.binding.network
209 | Active | 80 | 3.0.0 | org.openhab.binding.network
```