Commit Graph

100 Commits

Author SHA1 Message Date
Jacob Laursen
eb850e5175 [jdbc] Fix addon id for SQLite (#15877)
Fixes #15847

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2023-12-21 15:02:46 +01:00
openhab-bot
2c00b30e67 [unleash-maven-plugin] Preparation for next development cycle. 2023-11-03 17:01:07 +00:00
openhab-bot
9567c9bc57 [unleash-maven-plugin] Preparation for next development cycle. 2023-09-09 15:32:42 +00:00
Wouter Born
5a1164f4c2
Apply Spotless
Signed-off-by: Wouter Born <github@maindrain.net>
2023-09-02 22:58:10 +02:00
openhab-bot
512a94569f [unleash-maven-plugin] Preparation for next development cycle. 2023-08-15 22:19:30 +00:00
openhab-bot
ff341fbf56 [unleash-maven-plugin] Preparation for next development cycle. 2023-07-28 11:06:48 +00:00
Kai Kreuzer
72607d3bee Apply spotless
Signed-off-by: Kai Kreuzer <kai@openhab.org>
2023-07-24 01:20:31 +02:00
openhab-bot
809fceaff3 [unleash-maven-plugin] Preparation for next development cycle. 2023-07-23 19:19:01 +00:00
Robert D
99e78d84b5
fix timescale db type replacement (#15156)
Signed-off-by: querdenker2k <querdenker2k@gmx.de>
2023-07-02 21:20:50 +02:00
J-N-K
d85bb786ad
[jdbc] Fix addon-info (#14987)
Signed-off-by: Jan N. Klug <github@klug.nrw>
2023-05-13 20:55:31 +02:00
J-N-K
c3a9a4c7b6
Adjust to core changes (#14952)
Signed-off-by: Jan N. Klug <github@klug.nrw>
2023-05-08 09:35:36 +02:00
Jacob Laursen
f9cc267190
Upgrade MySQL Connector/J to 8.0.33 (#14893)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2023-04-28 10:00:32 +02:00
Jacob Laursen
d7b94b6bd3
Upgrade MySQL Connector/J to 8.0.33 (#14874)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2023-04-25 07:45:00 +02:00
Ilias Ktn
a42b92b183
Working PostgreSQL Schema check/fix and set TIMESTAMPTZ to match MySQL defaults (#14294)
Signed-off-by: Ilias Kotinas <henfiber@gmail.com>
2023-02-02 08:27:16 +01:00
Ilias Ktn
29b17e9c75
Perform upsert on key conflict like the default for MySQL (PostgreSQL >= 9.5) (#14281)
Signed-off-by: Ilias Kotinas <henfiber@gmail.com>
2023-01-27 10:33:11 +01:00
J-N-K
5f8214f08a
Adapt to core changes (addon.xml) (#13289)
Signed-off-by: Jan N. Klug <github@klug.nrw>
2023-01-15 20:31:42 +01:00
Jacob Laursen
4dd6d3a8a2
Update license headers to 2023 (#14154)
* Update copyright year in configuration
* Update license headers

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2023-01-06 09:49:54 +01:00
Jacob Laursen
0b59be62b6
Skip loading/migrating items with invalid name (#14054)
Fixes #14053

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-27 11:41:59 +01:00
Jacob Laursen
127f998a69
Upgrade MySQL Connector/J to 8.0.31 (#13991)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-19 23:49:51 +01:00
J-N-K
4d6d6443ef
fix spotless after release (#14014)
Signed-off-by: Jan N. Klug <github@klug.nrw>
2022-12-19 15:22:17 +01:00
openhab-bot
7993786dc9 [unleash-maven-plugin] Preparation for next development cycle. 2022-12-19 00:55:11 +00:00
Kai Takac
36137992a5
[jdbc] Update org.xerial/sqlite-jdbc to 3.40.0.0 (#14003)
* [jdbc] Update org.xerial/sqlite-jdbc to 3.40.0.0

Co-authored-by: Jacob Laursen <jacob-github@vindvejr.dk>
Signed-off-by: Kai Takac <kai.takac@gmail.com>
2022-12-18 19:04:43 +01:00
Jacob Laursen
a3fccc6390
Fix console command 'tables clean' (#13916)
NullPointerException was thrown because index table was not provided

Fixes #13911

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-11 22:47:37 +01:00
Jacob Laursen
dd8b7c8b65
[jdbc] Fix date filter to be inclusive (Derby) (#13850)
Fixes #9906

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-05 17:09:13 +01:00
Jacob Laursen
a0ac57cfd9
Fix date filter to be inclusive (PostgreSQL) (#13843)
Fixes #9906

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-05 00:27:54 +01:00
Jacob Laursen
312b4e2faf
Fix console command 'tables' for SQLite (#13837)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-04 14:54:12 +01:00
Jacob Laursen
e979be4911
Fix Derby/H2/HSQLDB/SQLite queries for storing timestamps (#13817)
Fixes #13816

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-02 08:14:23 +01:00
dependabot[bot]
9cc3cd0cf9
[jdbc] Update PostgreSQL JDBC driver to 42.4.3 (#13770)
* Bump postgresql in /bundles/org.openhab.persistence.jdbc

Bumps [postgresql](https://github.com/pgjdbc/pgjdbc) from 42.4.1 to 42.4.3.
- [Release notes](https://github.com/pgjdbc/pgjdbc/releases)
- [Changelog](https://github.com/pgjdbc/pgjdbc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pgjdbc/pgjdbc/compare/REL42.4.1...REL42.4.3)

---
updated-dependencies:
- dependency-name: org.postgresql:postgresql
  dependency-type: direct:production
...

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-12-01 22:32:55 +01:00
Jacob Laursen
3912487305
[jdbc] Add safety valve for suspicious migrations (#13797)
* Abort migration from real names when most tables have table name prefix
* Add missing checks for database connection from console commands
* Add additional documentation for check/fix schema

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-28 23:38:55 +01:00
Jacob Laursen
22ea587d20
[jdbc] Add console command for checking/repairing schema integrity (#13765)
* Add console command for checking schema integrity
* Remove unneeded logging
* Add console command for fixing schema integrity
* Provide documentation
* Try to add support for Derby and PostgreSQL
* Sort alphabetically by item name

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-27 19:02:43 +01:00
Jacob Laursen
f9aa20e488
[jdbc] Fix date filter to be inclusive (#13734)
Fixes #9906

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-22 07:13:45 +01:00
Jacob Laursen
d3348327a9
Fix PostgreSQL query for storing timestamps (#13745)
Fixes #13121

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-19 20:57:51 +01:00
Jacob Laursen
d075f141d7
Make itemsManageTable configurable (#13737)
Fixes #9637

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-18 17:34:10 +01:00
Jacob Laursen
b6f9f6339e
[jdbc] Add warning about using tableCaseSensitiveItemNames without dedicated schema (#13732)
* Add warning about using tableCaseSensitiveItemNames without dedicated schema
* Move warning to extended description
* Rephrase explanation
* Fix commands

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-17 20:05:10 +01:00
Jacob Laursen
dbf2358280
Do not modify index or create tables when uninitialized (#13728)
Fixes #13727

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-17 20:00:31 +01:00
Jacob Laursen
2f786b87b4
Add console command for reloading index/schema (#13733)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-17 19:52:54 +01:00
Jacob Laursen
3ef974df17
Fix NoSuchElementException when there are no tables (#13731)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-17 00:58:14 +01:00
Jacob Laursen
0873dd3ddf
[jdbc] Improve error handling safety (#13726)
* Wrap YankSQLException into checked exception for all Yank calls

* Move files into internal

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-16 09:28:46 +01:00
Jacob Laursen
7eb2c9fb81
[jdbc] Improve error handling (#13719)
* Enable wrapped exceptions being thrown by Yank

Fixes #13718

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>

* Fix SAT warning about hashCode implementation

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-15 08:44:12 +01:00
Jacob Laursen
159054a99c
[jdbc] Add console maintenance commands (#13662)
* Add console command for listing tables
* Query row counts only when needed and while generating output
* Add cleanup command
* Add documentation

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-12 12:30:53 +01:00
openhab-bot
62899e0fa5
New translations jdbc.properties (German) (#13697) 2022-11-11 22:36:39 +01:00
Jacob Laursen
64791b386c
[jdbc] Upgrade MariaDB connector to 3.0.8 (#13659)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-09 23:01:15 +01:00
openhab-bot
a8f671960d
New translations jdbc.properties (German) (#13686) 2022-11-09 10:52:30 +01:00
openhab-bot
cdff5a06e7
New translations jdbc.properties (German) (#13678) 2022-11-08 11:07:37 +01:00
Jacob Laursen
2c30756fdd
[jdbc] Fix MySQL deprecation notice on startup (#13660)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-05 20:27:38 +01:00
Jacob Laursen
70abb5d1f6
[jdbc] Add support for case sensitive table names reflecting item names 1:1 (#13544)
* Do not append number when using real item names
* Extract getTableName to separate class
* Add initial test coverage
* Extract migration logic to separate class
* Support migration from real names back to numbered
* Simplify zero-padding
* Fix NullPointerException
* Fix MySQL compatibility when CLIENT_MULTI_STATEMENTS option is not set
* Add option for case sensitive table names
* Add real name with suffix mode for backwards compatibility
* Remove real name in lower case without suffix mode
* Map directly from item name to table name
* Fix ambiguous table name scenario
* Add additional testcase
* Add migration path for changed table prefix
* Drop items table when using direct mapping
* Add configuration note
* Fix table alignment
* Extend description as more migration paths are now supported
* Do not stop halfway through a migration
* For clarity, do not use abbreviation for operating system

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-11-05 10:41:31 +01:00
dependabot[bot]
97956d30e9
[jdbc] Upgrade derby from 10.12.1.1 to 10.14.2.0 (#13038)
* Use derby instead of derbyclient, fix bnd optional package imports
* Update versions add dynamic package import for custom JDBC drivers
* Prevent redundant null check warnings

Signed-off-by: Wouter Born <github@maindrain.net>
2022-10-11 21:54:19 +02:00
Jacob Laursen
12389f083d
Consolidate and optimize datetime conversions (#13483)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-10-04 08:59:59 +02:00
Jacob Laursen
c706ac8478
[jdbc] Fix warnings and apply null annotations (#13429)
* Fix warnings and apply null annotations

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-10-02 11:14:41 +02:00
Jacob Laursen
3e5dde0474
Fix ClassCastException for LocalDateTime (#13425)
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
2022-09-21 19:10:02 +02:00