Wouter Born
db72021460
Update Eclipse files ( #4514 )
...
Signed-off-by: Wouter Born <github@maindrain.net>
2024-12-24 07:02:47 +01:00
Holger Friedrich
8d837f9823
Prepare for OH 5.0.0 ( #4496 )
...
* Prepare for OH 5.0.0
* Switch to 5.0.0-SNAPSHOT
* Fix spotless after unleash
* resolve itest runbundles
* Fix linux-specific pom
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2024-12-15 18:49:23 +01:00
openhab-bot
0f2e56f39d
[unleash-maven-plugin] Preparation for next development cycle.
2024-12-15 11:41:19 +00:00
Wouter Born
a22349abf4
Upgrade lastnpe EEA to 2.4.0 ( #4416 )
...
For release notes, see:
https://github.com/lastnpe/eclipse-null-eea-augments/releases/tag/v2.4.0
Signed-off-by: Wouter Born <github@maindrain.net>
2024-10-20 16:03:03 +02:00
Holger Friedrich
fc454883c2
Reduce SAT warnings ( #4339 )
...
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2024-08-11 10:04:26 +02:00
Kai Kreuzer
21e605d212
Apply spotless after release, resolve bundles ( #4301 )
...
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2024-07-07 23:22:27 +02:00
openhab-bot
07e23eac3c
[unleash-maven-plugin] Preparation for next development cycle.
2024-07-07 16:05:56 +00:00
Holger Friedrich
873bb53cbc
Upgrade Karaf from 4.4.5 to 4.4.6 ( #4181 )
...
* Upgrade Karaf from 4.4.5 to 4.4.6
* Sync runtime dependencies with Karaf 4.4.6, most notably:
* Jetty 9.4.54.v20240208, addresses CVE-2024-22201
* Pax Logging 2.2.7
* Pax Web 8.0.27
* ASM 9.7
* BouncyCastle 1.77
* Upgrade xtext to 2.35.0.M1
* Resolve itest runbundles
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2024-05-20 17:42:04 +02:00
Simonas Kazlauskas
81f2bd9366
[modbus] reduce log level when modbus slave returns DEVICE_BUSY exception ( #3847 )
...
* [modbus] reduce log level when modbus slave returns DEVICE_BUSY exception
This exception is meant to indicate that the request should be retried
shortly, essentially, and at least some of the devices I own seem to be
busy bees. Thus my logs receive significant spam of this warning.
Since the exception is transient and retrying it is the expected course
of action, I think it makes sense to reduce the log level here slightly
and only output an error when the retries get exhausted.
Signed-off-by: Simonas Kazlauskas <git@kazlauskas.me>
* Update bundles/org.openhab.core.io.transport.modbus/src/main/java/org/openhab/core/io/transport/modbus/internal/ModbusManagerImpl.java
Signed-off-by: Simonas Kazlauskas <github@kazlauskas.me>
---------
Signed-off-by: Simonas Kazlauskas <git@kazlauskas.me>
Signed-off-by: Simonas Kazlauskas <github@kazlauskas.me>
2024-04-28 18:04:40 +02:00
Holger Friedrich
c316b07c47
Update plugins ( #4197 )
...
* set minimum Maven version to 3.6.3
* build-helper-maven-plugin, 3.4.0 to 3.5.0, see
https://github.com/mojohaus/build-helper-maven-plugin/releases/tag/3.5.0
* jvnet maven-jaxb2-plugin, 0.15.2 to 0.15.3
* license-maven-plugin, 4.2 to 4.3
* maven-archetype-plugin, 3.0.1 to 3.2.1
* maven-assembly-plugin, 3.4.2 to 3.7.1, see https://github.com/apache/maven-assembly-plugin/releases
* maven-clean-plugin, 3.3.1 to 3.3.2, see https://github.com/apache/maven-clean-plugin/releases
* maven-dependency-plugin, 3.6.0/3.3.0/3.1.1 to 3.6.1, see
https://github.com/apache/maven-dependency-plugin/releases/tag/maven-dependency-plugin-3.6.1
* maven-jar-plugin, 3.3.0 to 3.4.1, see https://github.com/apache/maven-jar-plugin/releases
* maven-javadoc-plugin, 3.6.2 to 3.6.3, see https://github.com/apache/maven-javadoc-plugin/releases
* maven-plugin-plugin, 3.11.0 to 3.12.0, see
https://github.com/apache/maven-plugin-tools/releases/tag/maven-plugin-tools-3.12.0
* maven-shade-pluginm 3.5.2 to 3.5.3
* maven-source-plugin, 3.3.0 to 3.3.1
* maven-surefire-plugin, 3.1.2 to 3.2.5, see https://github.com/apache/maven-surefire/releases
* sortpom-maven-plugin, 3.3.0 to 3.4.1, see https://github.com/Ekryd/sortpom/releases
* spotless-maven-plugin, 2.38.0 to 2.43.0, see
https://github.com/diffplug/spotless/blob/main/plugin-maven/CHANGES.md
* openhab 18n-maven-plugin, 4.0.2 to 4.1.2
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2024-04-27 09:34:39 +02:00
Wouter Born
85056d9d7b
Some more code cleanup ( #4021 )
...
This cleanup includes:
* Use enhanced for loops
* Use text blocks
* Use Objects.equals
* Fix some typos
* Remove redundant variable initialization
* Remove redundant null checks with instanceof
* Remove redundant thrown Exceptions
* Remove redundant empty String concatenation
Signed-off-by: Wouter Born <github@maindrain.net>
2024-02-04 11:17:55 +01:00
Wouter Born
c757819a15
Fix JavaDoc issues ( #4004 )
...
Fixes various issues including wrong parameter names, references, links and dangling JavaDocs.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-04 00:03:48 +01:00
Wouter Born
2babea4c9a
Update license headers to 2024 ( #4011 )
...
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-03 21:20:34 +01:00
Wouter Born
6fc7700ea6
Use protected modifier with constructor of abstract classes ( #4010 )
...
Abstract classes should not have public constructors.
Constructors of abstract classes can only be called in constructors of their subclasses.
So there is no point in making them public.
The protected modifier should be enough.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-03 16:17:14 +01:00
Wouter Born
d162b82206
Fix String.format
argument mismatches ( #4008 )
...
These argument mismatches cause wrong messages being logged and thrown in exceptions.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-03 13:13:53 +01:00
Wouter Born
58a106d36d
Use diamond operator ( #4001 )
...
Often the type can be inferred so the diamond operator can be used to simplify the code.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-03 08:22:43 +01:00
Wouter Born
896b05e177
Replace or remove assert statements ( #3994 )
...
Java assertions are disabled by default so in this PR they are replaced/removed where applicable.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-02 22:21:42 +01:00
Wouter Born
041e3b5127
Remove redundant modifiers ( #4000 )
...
Removes redundant modifiers from the code.
These modifiers redeclare the default modifiers that apply to interfaces, enums etc.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-02 19:29:29 +01:00
Wouter Born
4e76d76088
Remove redundant array creation for calling varargs methods ( #3997 )
...
These array creations are unnecessary because arrays are created automatically for methods using varargs.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-02 19:01:34 +01:00
Wouter Born
89b67adbd7
Use isEmpty instead of 0 comparisons ( #3999 )
...
`isEmpty()` expresses the intent more clearly and is therefore preferred.
Counting the number of elements can also be an expensive operation e.g. when using linked lists.
Signed-off-by: Wouter Born <github@maindrain.net>
2024-01-02 18:47:36 +01:00
Wouter Born
f376606e92
Simplify boolean expressions ( #3971 )
...
Signed-off-by: Wouter Born <github@maindrain.net>
2023-12-28 13:19:01 +01:00
Wouter Born
ba5647b871
More code cleanups ( #3975 )
...
While cleaning up the code I found a some more code to cleanup:
* Remove unnecessary boxing
* Use `contains(..)` instead of `indexOf(..) != -1`
* Use `assertInstanceOf` in tests
* Make expensive trace logging conditional
* Remove redundant constructor
* Replace `collect(Collectors.toUnmodifiableList())` with `toList()`
* Replace `filter(..).count() == 0L` with `noneMatch(..)`
* Replace `filter(..).count() > 0` with `anyMatch(..)`
Signed-off-by: Wouter Born <github@maindrain.net>
2023-12-28 13:15:50 +01:00
Wouter Born
e958d5b46a
Replace lambdas with method references ( #3972 )
...
Method references are more readable because they refer to class names and usually result in less code.
Signed-off-by: Wouter Born <github@maindrain.net>
2023-12-28 09:55:31 +01:00
Holger Friedrich
839ba1ab4c
Apply spotless after release, resolve bundles ( #3953 )
...
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2023-12-22 23:14:28 +01:00
openhab-bot
3b279587b1
[unleash-maven-plugin] Preparation for next development cycle.
2023-12-22 11:48:43 +00:00
Holger Friedrich
9ad2fef549
Fix javadoc warnings ( #3870 )
...
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2023-11-15 09:21:07 +01:00
Wouter Born
e8e1c9fe73
Simplify code that creates List, Map and Set objects ( #3836 )
...
Simplifies the code by using List.of, List.copyOf etc. where possible which results in less code and imports.
Signed-off-by: Wouter Born <github@maindrain.net>
2023-10-09 18:00:00 +02:00
Wouter Born
09b3160a55
Simplify code using Stream.toList ( #3831 )
...
Stream.toList was introduced in Java 16 and creates an unmodifiable List so it can be used to simplify code whenever the List is not expected to be modified.
Signed-off-by: Wouter Born <github@maindrain.net>
2023-10-09 09:20:08 +02:00
Wouter Born
c39d15ade6
Cleanup code ( #3787 )
...
This code cleanup fixes various warnings in Eclipse.
Signed-off-by: Wouter Born <github@maindrain.net>
2023-08-30 22:50:17 +02:00
Kai Kreuzer
5692232e2b
Apply spotless
...
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2023-07-24 01:11:37 +02:00
openhab-bot
fd93f0a766
[unleash-maven-plugin] Preparation for next development cycle.
2023-07-23 17:14:35 +00:00
Holger Friedrich
a77a303dc3
Code cleanup: Use Java 17 features ( #3585 )
...
* Code cleanup: Use Java 17 features
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2023-05-01 08:27:15 +02:00
Wouter Born
3c6d855d4b
Remove redundant public and abstract modifiers from interfaces ( #3560 )
...
* Remove redundant public modifiers from interfaces
* Remove redundant abstract modifiers from interfaces
Signed-off-by: Wouter Born <github@maindrain.net>
2023-04-20 20:22:58 +02:00
Holger Friedrich
769aa562a1
Code cleanup: Use Java 17 features ( #3522 )
...
Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
2023-04-16 21:43:59 +02:00
Sami Salonen
fdea66ae75
[modbus] Fix possible NPE when connection construction fails ( #3490 )
...
Signed-off-by: Sami Salonen <ssalonen@gmail.com>
2023-04-15 16:29:36 +02:00
J-N-K
8d64ecfd8d
Update license header to 2023 ( #3294 )
...
* Update license header to 2023
Signed-off-by: Jan N. Klug <github@klug.nrw>
2023-01-03 09:45:42 +01:00
Wouter Born
687688db7e
Update Eclipse .classpath files ( #3250 )
...
Also adds some missing files for recently added projects.
Signed-off-by: Wouter Born <github@maindrain.net>
2022-12-22 14:14:35 +01:00
Дилян Палаузов
d48ac20377
typo: successful ( #3236 )
2022-12-19 15:45:17 +01:00
J-N-K
3fc4d23734
Fix spotless and resolve itests ( #3239 )
...
Signed-off-by: Jan N. Klug <github@klug.nrw>
2022-12-19 11:09:31 +01:00
openhab-bot
35254b3a0a
[unleash-maven-plugin] Preparation for next development cycle.
2022-12-18 23:08:22 +00:00
Kai Kreuzer
61fd47c853
Apply spotless and resolver ( #3018 )
...
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2022-06-27 13:41:28 +02:00
openhab-bot
8944bdbbe4
[unleash-maven-plugin] Preparation for next development cycle.
2022-06-26 16:37:00 +00:00
J-N-K
fe5b1ed6ac
Reduce levels of modbus connection logger ( #2972 )
...
Signed-off-by: Jan N. Klug <github@klug.nrw>
2022-05-20 20:40:50 +02:00
Łukasz Dywicki
c09db50d46
[modbus] Add configurable after connection delay ( #2927 )
...
Fixes #2926
Signed-off-by: Łukasz Dywicki <luke@code-house.org>
2022-04-23 13:49:43 +02:00
J-N-K
2a3e2e5567
Reduce Mockito warnings ( #2893 )
...
Signed-off-by: Jan N. Klug <github@klug.nrw>
2022-04-03 22:36:55 +02:00
Wouter Born
3d7be0ffa7
Avoid throwing raw exception types ( #2747 )
...
* Avoid throwing raw exception types
This fixes all 36 AvoidThrowingRawExceptionTypes SAT findings.
Signed-off-by: Wouter Born <github@maindrain.net>
2022-02-14 16:14:25 +01:00
Wouter Born
ad936cd83f
Add more null annotations ( #2742 )
...
* Add more null annotations
* Fix mock name
Adds null annotations to most of the tests as well as a few other classes.
Also fixes a few other SAT findings.
Fixes ~300 SAT findings in total.
Signed-off-by: Wouter Born <github@maindrain.net>
2022-02-14 11:33:50 +01:00
Christoph Weitkamp
cabb3f7315
Update license headers to 2022 ( #2671 )
...
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2022-01-07 13:16:42 +01:00
Kai Kreuzer
e3b07782b4
pom reference update from http to https ( #2644 )
...
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2021-12-23 22:55:20 +01:00
Kai Kreuzer
1ebf7395d9
Apply spotless
...
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2021-12-20 06:59:22 +01:00