Commit Graph

153 Commits

Author SHA1 Message Date
Wouter Born
05b7ec86f1
Fix new SAT findings (#2291)
Signed-off-by: Wouter Born <github@maindrain.net>
2021-04-14 18:41:07 +02:00
Sönke Küper
db488d861e
[automation] Added rule rest endpoint and backend operation for rule execution simulation (#2125)
* Added marker interface for TriggerHandler to indicate if they are time based and thus can be used to simulate execution times.
* Added marker interface for ConditionHandler to indicate, if they are time based and thus can be checked during rule execution for a certain time.
* Moved CronAdjuster to common, so it can be used for the rule simulation
* Created RuleExecutionSimulator that allows simulation of rules
* Added method in RuleManger to create simulation
* Added rest endpoint for rule simulation.
* Changed marker interface to return TemporalAdjuster instead of cron expression. This better hides the internals of the TriggerHandler (i.e. the cron expression) and is more clear and flexible for other handlers to implement

Fixes #2044
Fixes #2266

Signed-off-by: Sönke Küper <soenkekueper@gmx.de>
2021-04-11 09:31:48 +02:00
Christoph Weitkamp
7907f48735
Added nullness annotations to TypeParser (#2181)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2021-02-07 09:47:27 +01:00
Sönke Küper
65218f81fc
Added rule condition for not a holiday (#2043)
Signed-off-by: Sönke Küper <soenkekueper@gmx.de>
2021-02-06 16:37:29 +01:00
Wouter Born
46666eb169
Fix deprecations (#2163)
Signed-off-by: Wouter Born <github@maindrain.net>
2021-01-30 12:22:31 +01:00
Wouter Born
774b9d607b
Update license headers to 2021 (#2041)
Signed-off-by: Wouter Born <github@maindrain.net>
2021-01-01 16:43:46 +01:00
Wouter Born
bf14e1077f
Apply Spotless, resolve itest runbundles for 3.1.0 (#1982)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-12-22 10:01:42 +01:00
jenkins
965531696b [unleash-maven-plugin] Preparation for next development cycle. 2020-12-20 22:24:39 +00:00
Christoph Weitkamp
f83fc07c6a
[automation] Added ItemStateUpdate action (#1970)
* Added ItemUpdate action

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-12-20 13:53:09 +01:00
Kai Kreuzer
8f13b99122
[automation] Correctly trigger rules with start level 50 trigger (#1962)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-18 22:07:19 +01:00
Kai Kreuzer
4a108e5c80
Reintroduce delayed rule initialization (#1960)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-18 20:04:28 +01:00
Kai Kreuzer
5d87c1def4
[automation] Fixed startup rules being triggered more than once
Fixes #1943 

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-16 23:21:47 +01:00
Christoph Weitkamp
d37fa48da4
Temporarily hide ThingAction in UIs (#1947)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-12-16 23:21:27 +01:00
Kai Kreuzer
2b9f890831
Stabelized automation integration test (#1944)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-16 14:13:04 +01:00
Kai Kreuzer
8290306348
Fixed SAT issues (#1925)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-13 13:17:35 +01:00
Kai Kreuzer
313fb496ce
Added config options for start level trigger (#1923)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-13 09:31:34 +01:00
Kai Kreuzer
1a2c81d9e2
Improved startup logging and avoid scripts being loaded in start level service thread (#1919)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-13 09:31:09 +01:00
Kai Kreuzer
076ac3fe15
Implemented start level service (#1914)
Fixes #1637
Fixes #1777
Fixes #1734
Fixes #1823
Fixes #1808

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-12 14:34:37 +01:00
Kai Kreuzer
f99135ae3d
Reverted the introduction of an automation threadpool (#1890)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-12-05 11:50:16 +01:00
Kai Kreuzer
a892c7bcac
Synchronize the executions of each rule (#1870)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-11-30 10:31:33 +01:00
Kai Kreuzer
575f744a43
Request automation thread pool as a scheduled pool (#1869)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-11-30 10:18:56 +01:00
Kai Kreuzer
1e2fd7b447
Make rule engine use a threadpool (#1857)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-11-29 10:56:01 +01:00
Kai Kreuzer
48209e4a45
[automation] Fixes NPE when no command is given in a member-of-group trigger (#1806)
Fixes #1793 

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-11-11 16:27:31 +01:00
Christoph Weitkamp
0b239692ce
Added NPE checks for result of 'getSymbolicName()' methods (#1795)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-11-10 22:36:21 +01:00
Wouter Born
2f2bfde500
Remove Map null annotation workarounds (#1780)
These workarounds to prevent false positives can be removed now the EEAs allow for proper null analysis.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-11-03 22:12:22 +01:00
Wouter Born
0281c10036
[infrastructure] add external null-annotations (#1775)
Add EEAs and fix null analysis errors.

Related to:

* #888
* openhab/openhab-addons#8848

Signed-off-by: Wouter Born <github@maindrain.net>
2020-11-03 21:33:48 +01:00
Christoph Weitkamp
dd92288e97
Added nullness annotations, ctor injection (#1747)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-10-24 10:08:38 +02:00
Christoph Weitkamp
7d70a97b77
Fixed IndexOutOfBoundsException in ScriptModuleTypeProvider (#1730)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-10-19 13:41:58 +02:00
Wouter Born
0d1a15ef34
Update ActionService and ThingActions classes in Xtext cache (#1714)
Xtext uses a cache for looking up classes when rules are run.
It also adds a null class value to this cache when a class is not found.

Once a value has entered the cache it will not be updated.
This causes the cache to return the wrong class (or the null value) when
calling static methods on ActionService and ThingActions classes that
were added/updated.

With the changes in this PR Xtext will be configured to use a custom cache
that updates the ActionService and ThingActions class references.

The PR also has a fix for the AnnotatedThingActionModuleTypeProvider not
properly sending ModuleType removed events when all ThingActions
registrations have been removed.

Fixes #1265
Fixes #1694

Signed-off-by: Wouter Born <github@maindrain.net>
2020-10-13 23:17:57 +02:00
Wouter Born
81e82e7d44
Use consistent capitalization with Conditions, Triggers, Actions (#1647)
Fixes #1639

Signed-off-by: Wouter Born <github@maindrain.net>
2020-09-15 19:52:35 +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
057604cc2d
Use new Collection API methods (#1598)
Using the new methods there will be less and more readable code.

Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-22 23:04:11 +02:00
Wouter Born
d5529f0c1b
Fix various deprecations (#1595)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-15 10:54:41 +02:00
Wouter Born
7300734585
Use "openhab" event topic prefix (#1587)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-08-11 21:16:49 +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
Kai Kreuzer
0f134996f2
removed boot bundle (#1559)
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-07-24 13:11:56 +02:00
Paul Vogel
ed21001891
Cleanup tests: Simplify assertEquals with boolean to assertTrue or assertFalse (#1567)
Signed-off-by: Paul Vogel <pavog@users.noreply.github.com>
2020-07-23 22:19:00 +02:00
Christoph Weitkamp
c747f7f9bb
Fixed removal / replacement of annotated ThingActions (#1536)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-07-21 19:44:55 +02:00
Paul Vogel
27dcce5207
Replace for-loops and iterators with foreach-loops (#1561)
Signed-off-by: Paul Vogel <pavog@users.noreply.github.com>
2020-07-21 17:40:29 +02:00
Christoph Weitkamp
68405036f1
Removed 'Calendar' leftovers (#1522)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-06-14 17:13:28 +02:00
Kai Kreuzer
1fdede0f61
[automation] Removed superfluous file
- Removed superfluous file

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-06-08 12:40:06 +02:00
Kai Kreuzer
840335bbd5
[automation] Moved constants to top and made them public for reference (#1513)
* Moved constants to top and made them public for reference

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-06-07 23:03:53 +02:00
Kai Kreuzer
d265e16e67
[automation] Added group and system triggers to automation component (#1509)
* Added group and system triggers to automation component

Signed-off-by: Kai Kreuzer <kai@openhab.org>
2020-06-04 07:24:42 +02:00
Christoph Weitkamp
3eb93bf13a
Removed deprecated constructors and methods from Config API (#1448)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-05-20 22:16:54 +02:00
Wouter Born
f3508e4775
Use constructor injection and update null annotations (#1487)
* Use constructor injection and update null annotations

Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-20 17:29:18 +02:00
Wouter Born
84d9438737
Add null annotations to REST resources (#1475)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-05-17 19:32:35 +02:00
aisebastian
aca4513601
This patch adds more robust value comparison in the rule engine (#1456)
Previously, the state values were compared only if the item state was instanceof DecimalType
which did not work for channels that had a dimension specifier, such as Type:Length. The itemState
instance was of type QuantityType<Quantity<BigDecimal>> and therefore was never compared in the rules

Signed-off-by: Sebastian Irimia <aisebastian@yahoo.com>
2020-05-04 21:58:39 +02:00
Christoph Weitkamp
30839ac487
[automation] Fixed creation of 'EphemerisConditionHandler' (#1453)
* Fixed creation of EphemerisConditionHandler

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-05-02 14:08:11 +02:00
Wouter Born
61e17ce39e
Upgrade SAT and Spotless, apply Spotless and enable check (#1446)
* Update SAT and Spotless dependencies
* Apply Spotless and enable check

Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-26 11:15:24 +02:00
Christoph Weitkamp
d371a34321
Removed dependency on 'org.apache.commons.lang' (#1433)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-04-22 14:32:31 +02:00
Wouter Born
92027ca922
Use .equals() on constants and literals to prevent NPEs (#1420)
* Use .equals() on constants and literals to prevent NPEs

Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-16 07:40:49 +02:00
Wouter Born
6c85b1bccd
Add and fix more null annotations (#1421)
Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-15 01:44:37 +02:00
Wouter Born
fb7a7ac421
Add null annotations to providers and ThingManager (#1412)
* Add null annotations to providers and ThingManager

Signed-off-by: Wouter Born <github@maindrain.net>
2020-04-11 08:29:12 +02:00
Christoph Weitkamp
28afe7d866 Remove not needed object array creation for logging (#1344)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-01-27 09:22:17 +01:00
Christoph Weitkamp
08da8de5cf Moved "ESH-INF/" folders to "OH-INF/" folders (#1328)
* Moved ESH-INF folders to OH-INF folders

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2020-01-17 15:29:18 +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
Wouter Born
3811cb9560 Update copyright headers to 2020 (#1309)
* Update copyright headers to 2020

Signed-off-by: Wouter Born <github@maindrain.net>
2020-01-01 18:06:34 +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
Christoph Weitkamp
59675788e0 Renamed packages
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-12-28 12:18:16 +01:00
jenkins
bc6a380297 [unleash-maven-plugin] Preparation for next development cycle. 2019-12-15 14:55:36 +00:00
Gaël L'hopital
4fef0100cb [ephemeris] Evolutions of the Ephemeris module (#1169)
* Evolutions of the Ephemeris module

Signed-off-by: Gaël L'hopital <gael@lhopital.org>
2019-11-04 21:50:43 +01:00
Wouter Born
f002a21da5 Fix SAT errors/warnings in resources and tests (#1178)
Fixes SAT errors/warnings in resources and tests reported by SAT 0.8.0-SNAPSHOT.

Related to openhab/static-code-analysis#363

Signed-off-by: Wouter Born <github@maindrain.net>
2019-11-03 11:04:19 +01:00
Christoph Weitkamp
1f9a6f685d Consider more than one value when applying the default value(s) for Things and Channels (#1067)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-11-01 22:23:52 +01:00
Christoph Weitkamp
12d91f7da9 [i18n] Refactoring and annotations (#1161)
* Added nullness annotations to 'RuleTemplateI18nUtil'
* Added nullness annotations to 'ConfigDescriptionGroupI18nUtil'
* Moved 'ConfigDescriptionI18nUtil' into internal package
* Moved 'ConfigDescriptionGroupI18nUtil' into internal package
* Moved 'ThingTypeI18nUtil' into internal package
* Use 'ConfigI18nLocalizationService' instead of 'ConfigDescriptionI18nUtil'
* Use default labels / descriptions if application of localization is not successful
* Resolved itest.bndrun files

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-10-27 11:17:52 +01:00
Hilbrand Bouwkamp
d39b6bd35b [automation] Fix typos in EphemerisConditions.json (#1164)
Closes #1163

Signed-off-by: Hilbrand Bouwkamp <hilbrand@h72.nl>
2019-10-24 20:37:24 +02:00
Feras Almannaa
144fc8b56f [automation] Fix the created cron to run only once at the trigger minute. (#1162)
Fixes #1156

Signed-off-by: Feras AlManna <firas.almanna3@gmail.com>
2019-10-23 18:11:42 +02:00
Wouter Born
2430256b6a Add null annotations to registries (#1134)
Adds null annotations to all registries, the interfaces they implement and a few other classes.

Also-by: Christoph Weitkamp <github@christophweitkamp.de>
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-23 07:36:56 +02:00
Wouter Born
be69d2254e Use !isEmpty() instead of "size() > 0" or "size() != 0" (#1155)
* Use !isEmpty() instead of "size() > 0" or "size() != 0"

!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.

Co-Authored-By: Christoph Weitkamp <github@christophweitkamp.de>
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-21 09:00:52 +02:00
Christoph Weitkamp
a3d91bebfc [automation] Added EphemerisConditions for NGRE (#915)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-10-20 01:37:56 +02:00
Wouter Born
4895977966 Use isEmpty() instead of "size() == 0" (#1151)
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>
2019-10-20 01:27:11 +02:00
Christoph Weitkamp
21744d22b1 Normalized instantiation of loggers (#1138)
Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-10-18 22:29:27 +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
Wouter Born
12e8edc039 Use diamond operator (#1114)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-11 02:29:47 -07:00
Wouter Born
4e10e0d116 Fix SAT JavadocMethodStyleCheck findings (#1109)
* Fix SAT JavadocMethodStyleCheck findings

Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-10 14:18:54 +02:00
Wouter Born
3d52c72a91 Fix SAT AuthorContributionDescriptionCheck findings (#1110)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-10 11:36:05 +02:00
Wouter Born
90005e4a56 Fix NoEmptyLineSeparatorCheck and NewlineAtEndOfFileCheck SAT findings (#1108)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-08 22:19:54 -07:00
Wouter Born
08a1f9a86d Fix SAT constant/variable name findings (#1106)
Fixes wrong names identified by the following rules:

* ConstantNameCheck
* LocalFinalVariableNameCheck
* LocalVariableNameCheck
* StaticVariableNameCheck

Most mismatches identified by the MemberNameCheck have also been fixed except for those where the variables are used in events/DTOs etc which would cause issues.

Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-08 22:19:00 -07:00
Wouter Born
12b3c1030f Fix SAT "Initial contribution" warnings (#1100)
Fixes the SAT warning: First javadoc author should have "Initial contribution" contribution description.

Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-07 21:25:40 -07:00
Wouter Born
9ae7bbe2e8 Move remaining unit tests (#1095)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-10-04 21:35:13 -07:00
Wouter Born
9d2f09936d Fix null annotations order and cleanup (#958)
* Move null annotations between modifiers and variable type
* Remove redundant public modifiers from interfaces where applicable
* Remove redundant `@NonNull` annotations

Signed-off-by: Wouter Born <github@maindrain.net>
2019-08-08 09:42:30 +02:00
Markus Rathgeb
ef05b4d878 start with an upper case on "initial contribution" (#931)
Related to: https://github.com/openhab/openhab-core/pull/916/#discussion_r305082016

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-07-21 12:24:58 +02:00
Christoph Weitkamp
4b7eddf16e [automation] Fixed topic (#922)
- Fixed topic for `ThingStatusTriggerHandler`. Is is called "things", not "thing".

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-07-12 21:01:42 +02:00
Christoph Weitkamp
17c756513a [automation] Added 'ThingStatusTrigger' for NGRE (#911)
* Added ThingStatusTrigger for NGRE

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-07-10 11:57:54 +02:00
Christoph Weitkamp
abab07dfb9 [automation] Added nullness annotations (#910)
* Added nullness annotations

Signed-off-by: Christoph Weitkamp <github@christophweitkamp.de>
2019-07-08 10:53:25 +02:00
Markus Rathgeb
ebda4b8fc7 handle nullness in unget handler of composite module correctly (#878)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-06-20 21:22:22 +02:00
Markus Rathgeb
f1dfb553c7 we don't know if the rule has been deleted async. (#877)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-06-20 21:21:41 +02:00
Markus Rathgeb
457df1e853 rule engine should not depend on specific registry implementation (#819)
The current rule registry implementation provides a configuration for
the "rule reinitialization delay". That configuration is not used by the
rule registry itself but used by the rule engine implementation.
This required the rule engine implementation to contain a special code
path that checks if the injected rule registry is an instance of that
special implementation to access that configuration parameter.
As the configuration is not used by the registry itself, it does not
make sense that it is a configuration of that component.
If the rule engine (at least this special implementation) would like to
use a configurable parameter, it should be part of that specific
component implementation.

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-15 23:03:05 +02:00
Markus Rathgeb
1996f69e6f [automation] Fix activation of rules (#796)
Related to: https://github.com/openhab/openhab-core/issues/722
Related to: https://github.com/openhab/openhab-core/issues/783

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-08 15:18:21 +02:00
Markus Rathgeb
52c2456461 [automation] Disabled storage must not be null anymore (#797)
Related to: https://github.com/openhab/openhab-core/pull/787

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-06 13:32:15 +02:00
Markus Rathgeb
eaaf01a5fd use mandatory storage services (#787)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-02 21:11:00 +02:00
Markus Rathgeb
bafc39f91b automation: some cleanup (#776)
* automation: first cleanup
* automation: do not set all enabled rules to idle state

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-05-01 23:04:07 +02:00
Markus Rathgeb
1ac2e8978b automation: remove specific handling for CompositeModuleHandlerFactory (#764)
The member variable "compositeFactory" that holds the
"CompositeModuleHandlerFactory" instance is set in the activation method
by calling the constructor of of "CompositeModuleHandlerFactory".
This reference is destroyed and unset in the deactivate method.

There exists DS managed multiple optional references to
"ModuleHandlerFactory".
The "add" logic does not touch the "compositeFactory" variable.
The "remove" logic checks if the given service reference is a
"CompositeModuleHandlerFactory" and unsets the "compositeFactory" member
variable.

If e.g. a module handler factory is injected that also implements the
CompositeModuleHandlerFactory the CompositeModuleHandlerFactory created
by the activate method is still be used. If that specific module handler
factory is removed again, the variable "compositeFactory" is unset and
there is NO CompositeModuleHandlerFactory present anymore.

There are two options:
* The instance created in the activate method should be used as long as
  no other one is injected.
* The instance created in the activate method should be used all the
  time.

The whole code base does not contain another specific implementation for
CompositeModuleHandlerFactory, so there is no (at least in openHAB Core)
change that a CompositeModuleHandlerFactory is injected.

So instead of adding a non deterministic usage of "some" composite
module handler factory (which will require a fix of the "set module
handler factory method" and some others), let's drop the buggy code in
the "remove module handler factory" and use the manually created
composite module handler factory all the time.

Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-04-28 16:19:06 +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
Markus Rathgeb
fdb23778dc improve nullness of events (#657)
Signed-off-by: Markus Rathgeb <maggu2810@gmail.com>
2019-03-15 09:10:52 +01:00
Wouter Born
48d873a32b Use openHAB license headers (#632)
Signed-off-by: Wouter Born <github@maindrain.net>
2019-03-06 16:10:00 +01:00
David Gräff
4c9a5aa291 [Automation] GenericCronTrigger (#622)
A cron trigger module is actually not that "Generic" and a useful trigger type for a lot of rules.

Therefore I suggest to remove the visibility "HIDDEN" with this PR.
I have also added a context "cronexpression" to the TEXT configuration value, so that UI's can offer a cron expression
selection widget.
(we currently have: 'time','item','script','channel','dayOfWeek','rule')

Signed-off-by: davidgraeff <david.graeff@web.de>
2019-03-05 06:46:48 +01:00
David Gräff
eacb019e39 [Automation] DayOfWeekCondition (#621)
Remove inconsistent visibility "PUBLIC". This value is not documented (there is only HIDDEN and VISIBLE) and this is the only module type that uses PUBLIC instead of just not setting this value at all.

Signed-off-by: davidgraeff <david.graeff@web.de>
2019-03-04 11:19:47 +01:00
Hilbrand Bouwkamp
09e2292a58 Replaces 'Eclipse SmartHome' with 'openHAB' in text (#581)
Adapted CONTRIBUTING.md file.

Signed-off-by: Hilbrand Bouwkamp <hilbrand@h72.nl>
2019-02-15 10:46:37 +01:00
Hilbrand Bouwkamp
d342afbc4e Updated NOTICE files to openHAB (#578)
Signed-off-by: Hilbrand Bouwkamp <hilbrand@h72.nl>
2019-02-15 10:46:18 +01:00
David Gräff
ee466da9bc [automation] Unify types - itemsActions (#579)
Unify types - Second try
See also types in automation/moduletypes/ItemTriggers.json

Signed-off-by: davidgraeff <david.graeff@web.de>
2019-02-15 09:31:11 +00:00