Skip to content

[timescaledb] Upgrade libraries and make Docker test optional - #20721

Merged
lsiepel merged 1 commit into
openhab:mainfrom
holgerfriedrich:pr-timescaledb
May 17, 2026
Merged

[timescaledb] Upgrade libraries and make Docker test optional#20721
lsiepel merged 1 commit into
openhab:mainfrom
holgerfriedrich:pr-timescaledb

Conversation

@holgerfriedrich

Copy link
Copy Markdown
Member
  • Upgrade postgresql from 42.7.9 to 42.7.11
  • Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
  • Make Docker test optional to avoid failure if Docker is not available
  • Small adaptions

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>

@lsiepel lsiepel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks LGTM

Awaiting upload to jfrog (@florian-h05)

@lsiepel lsiepel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also expect the feature.xml to be update similar to
https://github.com/openhab/openhab-addons/pull/20722/changes

@holgerfriedrich

holgerfriedrich commented May 16, 2026

Copy link
Copy Markdown
Member Author

I would also expect the feature.xml to be update similar to https://github.com/openhab/openhab-addons/pull/20722/changes

I don't think so. It seems the design decision for timescaledb was to embed the driver into the binding jar.

	<feature name="openhab-persistence-timescaledb" description="TimescaleDB Persistence" version="${project.version}">
		<feature>openhab-runtime-base</feature>
		<bundle start-level="80">mvn:org.openhab.addons.bundles/org.openhab.persistence.timescaledb/${project.version}</bundle>
	</feature>

Looking at the pom, all runtime dependencies seem to be pulled in using scope compile.

Overall it seems we drift away from sharing libs (OSGI bundles) to embedding them per binding.
I have seen the same for okio - where we have both OSGI and embedded versions.

@lsiepel

lsiepel commented May 16, 2026

Copy link
Copy Markdown
Contributor

Yes, we could change it to provided and use the feature as the other persistence already shares it.

@holgerfriedrich

Copy link
Copy Markdown
Member Author

Ok, I have to adapt my comment above:
jdbc persistence also pulls in the libs with default scope, i.e. compile. It just drops them during packaging to save space, leading to the situation that the jar files need to be put in place for the specific databases.
This is not what we want for a default service like timescaledb.

The OSGI packages mentioned above are a different topic. DB drivers are probably not OSGI packages.

@florian-h05

Copy link
Copy Markdown
Contributor

I‘ve uploaded Hikari to JFrog, so you can OSGi-ify this dependency if you want.

<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>${postgresql.version}</version>
<scope>compile</scope>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was not talking about hikari, not sure if that is used elsewhere. Was mainly talking about postgresql:

<bundle start-level="80">mvn:org.postgresql/postgresql/42.7.11</bundle>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<scope>provided</scope>

@lsiepel lsiepel May 17, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the suggestion seems to be at some wrong line... compiled => provided

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure if I like to do this change. Timescaledb is installed per default and I don't want to complicate things now.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure what you mean by per default. It is just a add-on like any other. I'll create a seperate PR to make use of the osgi feature sharing

@lsiepel lsiepel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM

@lsiepel
lsiepel merged commit 5d40ad5 into openhab:main May 17, 2026
2 checks passed
@lsiepel lsiepel added this to the 5.2 milestone May 17, 2026
@holgerfriedrich
holgerfriedrich deleted the pr-timescaledb branch May 17, 2026 20:52
@holgerfriedrich

Copy link
Copy Markdown
Member Author

@lsiepel I had somehow in mind that timescale is installed by the setup wizard. That's not the case.... Sorry for the confusion.

markus7017 pushed a commit to markus7017/openhab-addons that referenced this pull request May 19, 2026
…b#20721)

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
markus7017 pushed a commit to markus7017/openhab-addons that referenced this pull request Jun 13, 2026
…b#20721)

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
darkscout pushed a commit to darkscout/openhab-addons that referenced this pull request Jul 5, 2026
…b#20721)

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
olemr pushed a commit to olemr/openhab2-addons that referenced this pull request Aug 8, 2026
…b#20721)

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
Signed-off-by: olemr <olemr@olemr.com>
cipianpascu pushed a commit to cipianpascu/openhab-addons that referenced this pull request Aug 16, 2026
…b#20721)

* Upgrade postgresql from 42.7.9 to 42.7.11
* Upgrade hikari from 5.1.0 to 7.0.2 (lifting req. to Java 11)
* Make Docker test optional to avoid failure if Docker is not available
* Small adaptions

Signed-off-by: Holger Friedrich <mail@holger-friedrich.de>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants