Commit Graph

223 Commits

Author SHA1 Message Date
Wouter Born
d12c30dfcf
Upgrade Aries JAX-RS Whiteboard to 1.0.9 (#1656)
This version uses CXF 3.2.13 which has some SSE fixes.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-09-19 15:59:48 +02:00
Wouter Born
f5f1e32b9f
Add null annotations to ConfigDescriptionRegistry and ConfigUtil (#1641)
Also added "org.eclipse.jdt.annotation" to the test BOM so we can use "org.eclipse.jdt.annotation.Checks" in itests.
That class has many useful methods that help with writing more readable test code when using the Eclipse JDT null analysis annotations.

After running the resolver on the itests  a lot of bundles were removed from the itest.bndrun files.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-09-15 17:00:15 +02:00
Łukasz Dywicki
7652d04ff6 Remove dependencies which are not present in the project. (#1592)
These cause build to fail with clean repository.

Signed-off-by: Łukasz Dywicki <luke@code-house.org>
2020-09-03 20:33:32 +02:00
Wouter Born
42a02ecb53
Exclude transitive activation-api dependency from swagger (#1582)
This newer version would make bnd resolve the lower bound to 1.2 instead of 1.1 for add-ons.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-10 09:04:36 +02:00
Wouter Born
d3ea6063c0
Migrate to JUnit 5 (#1580)
* Migrates all tests to the JUnit 5 Jupiter API
* Updates bnd to 5.1.2
* Updates maven-surefire-plugin to 3.0.0-M5
* Updates Mockito to 3.4.6
* Updates Hamcrest to 2.2
* Removes org.openhab.core.boot POM dependencies

Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-09 14:36:46 +02:00
Wouter Born
29dfb967c4
Migrate to OpenAPI 3 annotations (#1576)
* Upgrade to Swagger 2.1.0
* Add missing root and events resources
* Fix wrong and add missing response implementations

Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-02 13:21:57 +02:00
Yannick Schaus
aac4ca2f79
Swagger: support injection of ReaderListener, add OAuth2 annotations (#1496)
Signed-off-by: Yannick Schaus <github@schaus.net>
2020-07-24 22:30:06 +02:00
Kai Kreuzer
0f134996f2
removed boot bundle (#1559)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-07-24 13:11:56 +02:00
Wouter Born
84bf78d651
Remove Quartz leftovers (#1521)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-06-14 12:48:22 +02:00
Kai Kreuzer
173c93081d
Replaced "classic" rule engine by a DSLRuleProvider for the NGRE (#1451)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-06-14 10:36:25 +02:00
Wouter Born
5b325aa3d2
Update nrjavaserial in TP to 5.2.1 (#1503)
With this version it will no longer completely exit the JVM in certain scenarios when ports are closed/reopened.

Related to:

* openhab/org.openhab.binding.zigbee#577
* openhab/org.openhab.binding.zwave#1332

Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-27 21:28:52 +02:00
Wouter Born
2b5be0ba53
Update BOMs: remove mapdb, add dagger (#1493)
Related to #1488
Fixes #1238

Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-22 21:12:09 +02:00
Kai Kreuzer
97d7ef65a8
removed unused mapdb storage bundle (#1488)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-05-22 09:52:22 +02:00
Wouter Born
859da2e1c7
Migrate to JAX-RS Whiteboard (#1443)
* Migrate to JAX-RS Whiteboard
* Upgrade Jackson and Swagger TP feature dependencies

The upstream JAX-RS Whiteboard feature is not used because the version ranges currently do not work with Karaf on Windows.
See: https://issues.apache.org/jira/browse/KARAF-6536

* Update Felix logback to 1.0.2

This version adds the jul-to-slf4j bridge (FELIX-6027).
JUL is used by CXF and using the bridge we can use logback to reduce the verbosity of the info logging whenever org.apache.cxf.endpoint.ServerImpl creates endpoints.

* Update Aries Whiteboard to 1.0.8
* Removes the hated default web application (ARIES-1931)
* Improves performance
* Uses CXF 3.2.12
* Don't reuse SSE event builders

SSE event builders are not thread-safe.
It also causes the wrong default values being used.

Also-by: Markus Rathgeb <maggu2810@gmail.com>
Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-14 22:32:35 +02:00
Wouter Born
ac1f4080e3
Update nrjavaserial in TP to 5.0.2 and define import version range (#1464)
The first version of nrjavaserial with OSGi manifest entries is 3.12.0.
The interface has not changed and is still the same with nrjavaserial 5.x.
So using 3.12.0 as compile time dependency and defining a [3.12,6) version range using bnd.bnd files allows for maximum flexibility.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-08 11:48:06 +02:00
Wouter Born
54082a6fc8
Add commons-fileupload back to runtime BOM (#1458)
Fixes resolving bundles in the Demo App.
It's a dependency of org.apache.felix.webconsole

Caused by: #1436

Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-04 11:31:48 +02:00
Wouter Born
ed4b5ff94b
Reconfigure and apply Spotless (#1442)
Adds a configuration for feature.xml files which will be necessary for https://github.com/openhab/static-code-analysis/pull/375

Also applies the results of running Spotless

Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-23 17:17:12 +02:00
Christoph Weitkamp
e17046ea3f
Removed dependency on 'org.apache.commons.httpclient' (#1436)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-04-20 22:31:46 +02:00
Wouter Born
66da3a7912
Update nrjavaserial to 3.20.0 (#1426)
Updates nrjavaserial to the official 3.20.0 release (compatible with Java 8/11).
With the upgraded version the library will no longer crash the Java 11 VM on Windows.
The native libraries now use the built in RXTX lockfiles instead of the previously used (OS dependent) liblockdev whereas the OH build didn't use any lockfiles at all.
It also has a fix for errors being printed when scanning for serial ports whenever a serial port is locked (NeuronRobotics/nrjavaserial#166).
With the new version RXTX threads also have proper names and there is a fix for an IllegalMonitorStateException that might occur when closing ports.

Fixes #1384

Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-15 11:10:55 +02:00
Yannick Schaus
fe4e276b68
Implementation of a JWT-based OAuth2 flow for the admin API (#1389)
* Initial implementation of a JWT-based OAuth2 flow for the admin API

Implements #1388.

Signed-off-by: Yannick Schaus <github@schaus.net>
2020-03-23 22:36:11 +01:00
Christoph Weitkamp
11fa4fad4a
Removed dependency on 'org.apache.commons.exec' (#1359)
* Removed dependency on 'org.apache.commons.exec'
* Use StringBuilder

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-02-12 13:20:06 +01:00
Kai Kreuzer
86899daf1a replaced Joda Time by Java Time (#1342)
* replaced Joda Time by Java Time

Signed-off-by: Kai Kreuzer <kai@openhab.org>

* removed joda from target platform feature

Signed-off-by: Kai Kreuzer <kai@openhab.org>

* updated tests

Signed-off-by: Kai Kreuzer <kai@openhab.org>

* fixed persistence extension tests

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-01-25 22:44:03 +01:00
Yannick Schaus
cc702266fe Refactor dashboard tiles into core (#1329)
* Refactor dashboard tiles into core

Move the tile concept from the dashboard UI to the
org.openhab.core.ui bundle, and add a REST resource
(/rest/ui/tiles) to retrieve the list of tiles i.e.
registered UIs.

Signed-off-by: Yannick Schaus <github@schaus.net>
2020-01-17 15:28:05 +01:00
Wouter Born
18d0a52d02 Switch to Java 11 and drop Java 8 support (#1305)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-01-12 22:32:28 +01:00
Christoph Weitkamp
800956598b Applied spotless formatter (#1302)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-12-30 22:55:19 +01:00
Kai Kreuzer
650f895620 removed 1.x compatibility layer (#1284)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-12-21 11:32:29 +01:00
Christoph Weitkamp
32e20111f0 Removed dependency on 'org.apache.commons.collections' (#1236)
* Removed dependency on 'org.apache.commons.collections'
* Removed dependency from feature

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-12-19 17:01:16 +01:00
jenkins
bc6a380297 [unleash-maven-plugin] Preparation for next development cycle. 2019-12-15 14:55:36 +00:00
Kai Kreuzer
57c719e187 added Californium to runtime bom (#1263)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-12-08 22:21:06 +01:00
Kai Kreuzer
d7972f2ea8
added Californium to compile bom (#1262)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-12-08 20:51:58 +01:00
Markus Rathgeb
7ba7ee2a86 update runtime dependencies to sync Jetty and Pax Web versions (#1218)
Use the same Pax Web and Jetty version for the runtime dependencies
(used by the demo application) as is used in the Karaf distribution.

This PR needs to be merged synchron to the updated bndrun in the openHAB
demo repository.

Related to: https://github.com/openhab/openhab-core/pull/1197#issuecomment-553029014

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-11-17 11:47:24 +01:00
Wouter Born
d627a6b7e6 Downgrade Jollyday again to fix Java 11 build issues (#1195)
Jollyday requires JAXB 2.3 on Java 11 whereas only 2.2 is available during compilation for Java 8 compatibility.

See also:
* https://github.com/openhab/openhab2-addons/issues/6334
* https://github.com/openhab/openhab-core/pull/1170
* https://github.com/openhab/openhab-core/pull/1169

Signed-off-by: Wouter Born <github@maindrain.net>
2019-11-08 15:18:58 +01:00
Wouter Born
e943ec8970 Upgrade to Xtext 2.19, LSP4J 0.8.0 and fix LSP server (#1171)
Every connection to the LSP server failed because it always threw a org.eclipse.smarthome.model.ide.SitemapIdeSetup NoClassDefFoundError.
Which is caused by the SitemapIdeSetup residing in a package that is split between both the org.openhab.core.model.item.ide and the org.openhab.core.model.sitemap.ide bundles.
The SitemapIdeSetup class is also using classes from the org.eclipse.smarthome.model package which is also a package split between the org.openhab.core.model.items and org.openhab.core.model.sitemap bundles.
After renaming the packages used for the sitemap classes the NoClassDefFoundError is resolved and LSP works properly again.
Many imports were updated for the sitemap model package changes.

Fixes #1030

Signed-off-by: Wouter Born <github@maindrain.net>
2019-11-07 16:26:59 +01:00
J-N-K
07d10dba3d move MQTT client from Paho to HiveMQ (#1125)
Signed-off-by: Jan N. Klug <jan.n.klug@rub.de>
2019-11-05 07:51:59 +01:00
Christoph Weitkamp
92a0017e49 Bump jollyday version to 0.5.9 (#1170)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-10-29 20:39:11 +01:00
Wouter Born
017302e3cf Update Mockito to 3.1.0 (#1127)
Mockito 3 does not introduce any breaking API changes, but now requires Java 8 over Java 6 for Mockito 2.

Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-14 07:14:09 +02:00
Christoph Weitkamp
91617d8af8 Fixed POM XML Shema Definition path (#1119)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-10-12 08:52:16 +02:00
lolodomo
cf4b752ae1 [rest] New audio API (#1020)
* New Audio REST API

Signed-off-by: Laurent Garnier <lg.hc@free.fr>
2019-09-15 08:50:15 +02:00
pali
fa416be057 [bin2json] Binary to JSON converter initial contribution (#611)
Signed-off-by: Pauli Anttila <pauli.anttila@gmail.com>
2019-09-01 12:57:58 +02:00
Christoph Weitkamp
abed938de0 Removed duplicate dependencies (#1013)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-08-30 21:26:46 +02:00
Kai Kreuzer
b6aae6907f Revert "openHAB JAX-RS publisher (#905)"
This reverts commit ad81f040de.
2019-07-17 11:55:29 +02:00
Christoph Weitkamp
165df518de Bump tec.uom libraries (#923)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-07-14 21:37:07 +02:00
Markus Rathgeb
522af08531 provide Java EE modules (#920)
Also-by: Jan N. Klug <jan.n.klug@rub.de>
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-07-12 17:59:15 +02:00
Markus Rathgeb
ad81f040de openHAB JAX-RS publisher (#905)
* add project for publisher
* add unmodified com.eclipsesource.jaxrs.publisher sources
* modify and use modified publisher
* drop tracker usage (only for custom whitelist by fragments)
* add the new code to new classes and namespace

Also-by: Kai Kreuzer <kai@openhab.org>
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-07-01 21:08:03 +02:00
Hakan Tandogan
3e3cbeac60 [ephemeris] upgrade jollyday library to the latest released version (#870)
Signed-off-by: Hakan Tandogan <hakan@tandogan.com>
2019-06-13 10:27:01 +02:00
Kai Kreuzer
d0dfbe3f44 Ephemeris service (#506)
Also-by: Gaël L'hopital <gael@lhopital.org>
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-06-11 10:20:04 +02:00
Wouter Born
060530a8e4 Use nrjavaserial 3.15.0.OH2 in runtime BOM (#833)
When debugging openHAB in Eclipse I ran into serial port locking issues again on Ubuntu 18.04.2.
We resolved these in the distro by using 3.15.0.OH2 which doesn't use liblockdev.

Errors similar to the one below may show after stopping/restarting openHAB when using serial ports on certain distros:

RXTX fhs_lock() Error: opening lock file: /var/lock/LCK..ttyUSB0: File exists. It is mine

testRead() Lock file failed

See also:
    https://github.com/openhab/openhab-core/pull/761

Signed-off-by: Wouter Born <github@maindrain.net>
2019-05-27 14:18:00 +02:00
Markus Rathgeb
d55d59d3b5 MQTT: disable https hostname verification (#820)
After the bump of Paho from 1.2.0 to 1.2.1 the library enables the https
hostname verification.
This breaks compatibility with current consumers.
Connections cannot be established anymore.

We disable the https hostname verification to keep the old behaviour.
We should add an API so the hostname verification can be enabled if
desired.

This also makes the version 1.2.1 the lower version limit as we need to
use the API to disable the verification internally.

Related to: https://github.com/openhab/openhab-core/issues/815

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-15 17:57:49 +02:00
David Gräff
efdcf79300 Update paho to 1.2.1 service release (#784)
Fixes unreleased resources, disconnecting problems and many more

Signed-off-by: David Gräff <david.graeff@web.de>
2019-05-08 10:10:47 +02:00
Markus Rathgeb
c359347ada allow to use "Pure Annotation-Driven Bundle Development" (#803)
Bump the OSGi annotation to allow a pure annotation-driven bundle
development.

Related to: https://virtual.osgiusers.org/2018/10/pure-annotation-driven-dev

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-06 23:10:32 +02:00
Markus Rathgeb
b7b5dfc9fa POM Code Convention (#790)
There is a recommended ordering for all Maven POM files.
See: https://maven.apache.org/developers/conventions/code.html

The POM files has been "fixed" by using the "sortpom-maven-plugin".
The blank lines has been kept to keep the element separation for
readability.
The plugin also fixes indentation etc.
Have a look at: https://github.com/Ekryd/sortpom/wiki

The profile has been set to "recommended_2008_06" that states:
The POM Code Convention that was chosen by Maven developers in 2008

Command that has been executed:

    mvn \
      com.github.ekryd.sortpom:sortpom-maven-plugin:sort \
      -Dsort.keepBlankLines=true \
      -Dsort.predefinedSortOrder=recommended_2008_06

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-05 17:47:41 +02:00
Markus Rathgeb
d60a7c8fe0 use compendium specification R7 (#766)
This allows us to use the version 1.4 of the components and we can use
the Constructor Injection.

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-04-29 19:14:24 +02:00
Markus Rathgeb
d2c7db63db use upstream nrjavaserial 3.15.0 on runtime (#761)
* add nrjavaserial without liblockdev
* use only one feature for a nrjavaserial implementation

Fixes: https://github.com/openhab/openhab-core/issues/750

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-04-29 19:11:32 +02:00
David Gräff
31c3ba3713 Add serial transport to runtime BOM (#714)
Add nrjavaserial to runtime bom

Signed-off-by: David Graeff <david.graeff@web.de>
2019-04-13 12:09:15 +02:00
Markus Rathgeb
9630a7eb1a runtime: add support for Paho MQTT (#702)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-04-09 21:25:50 +02:00
Wouter Born
6900fcbe3e Add commons-net to bom (#694)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-04-03 07:28:04 +02:00
Wouter Born
cbb96945f0 Ignore and remove Eclipse project specific settings (#677)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-03-26 13:04:09 +01:00
Wouter Born
2c7ca348ef Upgrade Xtext to 2.17 for full Java 11 support (#650)
* Upgrade Xtext to 2.17 for full Java 11 support

Signed-off-by: Wouter Born <github@maindrain.net>
2019-03-15 09:13:24 +01:00
Markus Rathgeb
2ecc21d7a2 drop slf4j-simple from test index (#652)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-03-14 10:37:31 +01:00
Markus Rathgeb
f00b005ab9 bump Gson to 2.8.2 (#648)
As long as we depend on the internal Gson packages, we need to use the
Gson bundle provided by Eclipse Orbit instead of the official one.

Related to: https://github.com/openhab/openhab-core/pull/641

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-03-13 23:23:37 +01:00
Wouter Born
56a5c151c0 Upgrade Mockito to 2.25.0 for Java 11 compatibility (#647)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-03-13 11:23:56 +01:00
Markus Rathgeb
2a06d15955 add runtime dependency declarations to project (#606)
For the runtime dependencies a template from the EnRoute project has
been used. To allow further customization and usages of different Maven
scopes, we migrate the template to this repo.

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-25 22:39:28 +01:00
Markus Rathgeb
ee29031708 bump jUPnP (#602)
The version 2.5.2 contains the provided JUPnPService capability
information.

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-25 09:21:16 +01:00
Kai Kreuzer
fb0470c6d1 removed dashboard bundle as it has moved to https://github.com/openhab/openhab-webui (#586)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-02-20 05:37:41 +00:00
Markus Rathgeb
363a437347 workround m2e indexer hickup, build local openhab index (#584)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-18 16:29:55 +01:00
Markus Rathgeb
0c4298f6a6 migrate tests for io.rest.core
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-06 15:56:00 +01:00
Markus Rathgeb
034e38d3e1 add test: org.openhab.core.config.core (#516)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-04 17:37:10 +01:00
Markus Rathgeb
c37d2a41e9 use openHAB Core index, simplify itests and demo app (#503)
* use openHAB Core index, simplify itests and demo app

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-02-01 11:02:39 +01:00
Kai Kreuzer
53096ba08f removed Groovy support from tests (#490)
Also-by: Markus Rathgeb <maggu2810@gmail.com>
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2019-01-31 05:15:43 +00:00
Markus Rathgeb
76dd62623f make a first step to split between pure JUnit and integration tests (#488)
* make a first step to split between pure JUnit and integration tests

Related to: https://github.com/openhab/openhab-core/issues/482

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-01-30 08:57:06 +01:00
Markus Rathgeb
fbca7e806f remove project specific JDT settings (#481)
Done per request by @wborn.
Related to: https://github.com/openhab/openhab-core/pull/476#discussion_r251566034

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-01-29 10:24:39 +01:00
Markus Rathgeb
c0d638e8a3 fix eclipse project name for openhab-core BOM (#478)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-01-28 23:14:56 +01:00
Markus Rathgeb
a37cceab67 mavenize openHAB and integrate mavenized ESH repository (#467)
* mavenize openHAB and integrate mavenized ESH repository

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-01-28 13:07:31 +01:00