replikativ / datahike-jdbc

Datahike JDBC data storage backend
Eclipse Public License 1.0
16 stars 4 forks source link

Create general Datahike JDBC backend #1

Closed TimoKramer closed 4 years ago

TimoKramer commented 4 years ago

This is a first working version of Datahike JDBC backend which builds on top of https://github.com/alekcz/konserve-jdbc. The current version of konserve-jdbc builds on clojure.java.jdbc which is superseded by next.jdbc. It seems that next.jdbc is more future proof and this should be ported in the future.

Configuration is done by using a config map as parameter to the corresponding functions or by using the appropriate environment variables or system properties. This works like other backends, but since JDBC is very versatile you can only pass the whole configuration as one string to one environment variable/system property named DATAHIKE_STORE_CONFIG

But you need to set DATAHIKE_STORE_BACKEND=jdbc as well that datahike knows which backend to speak to. There are integration tests that test the integration with Datahike in MySQL, PostgreSQL and H2.

TimoKramer commented 4 years ago

this PR has failing tests because it needs datahike to merge PR https://github.com/replikativ/datahike/pull/195 first

alekcz commented 4 years ago

@TimoKramer alekcz/konserve-jdbc is build for konserve 0.6.0 datahike 3.1.x depends on HHT 1.7.0 which depends konserve 0.5.1. I got stuck here because the updates to all my konserve backends where for 0.6.0. Have you managed to overcome this?

TimoKramer commented 4 years ago

this seems to work with hht 1.7.0 provided by datahike and konserve 0.6.0-20200512.093105-1 provided by konserve-jdbc:) Do you expect any issues mixing this? @whilo @alekcz

TimoKramer commented 4 years ago

@alekcz so I had a short chat with whilo about that and afai understood there should be no issue