Hello Ralf, i tried to get the example working but I am struggeling with the Datasource. I got a first issue resolved, where the Logger was twice found in the sourcetree but i think this is a local issue for me.
The issue I currently cannot resolve comes up, as soon as the datasource tries to get a connection. It tells me the HikariDatasource is null „HikariDatasource (null)“, unfortunatly i do not get a Stacktrace. The error occurs in SampleApp.java:240 as soon as the Connection shall be fetched in the run() Method. As Rainer I have not much experience with Spring too, but tried get it working non the less. If you can have a look into it and hopefully have a solution for me. Thanks in advance and have a great weekend Greetings Daniel Von: Ralf Eichinger <[email protected]<mailto:[email protected]>> Gesendet: Dienstag, 10. August 2021 18:12 An: [email protected]<mailto:[email protected]> Betreff: Re: Evaluating empire-db with Spring Boot Hi Rainer, I am glad to contribute. The example is without Spring JDBC Templates, just pure Empire-DB, but configured over the convenience configuration features of Spring Boot (application.yml, profiles and reading them with ConfigurationProperties). The DataSource is automatically instantiated when Spring Boot detects the hsqldb driver on classpath and when dependency to spring-boot-starter-jdbc is in pom.xml and by using standard datasource properties (see https://docs.spring.io/spring-boot/docs/current/reference/html/application-properties.html#application-properties.data.spring.datasource.url ) The DataSource uses automatically Hikari-ConnectionPool. Many greetings Ralf On Tue, Aug 10, 2021 at 4:21 PM Rainer Döbele <[email protected]<mailto:[email protected]>> wrote: Hello Ralf, thank you very much for your Spring-Boot Example. We are happy that you are interested in Empire-db and every contribution to our project is very much appreciated. We will gladly take a look at the example, but it might take a few days before we can comment. Unfortunately I personally do not have experience with Spring Boot and other Spring related components. But if I need some help to understand it, I will let you know. Best Regards, Rainer Von: Ralf Eichinger <[email protected]<mailto:[email protected]>> Gesendet: Montag, 9. August 2021 23:12 An: [email protected]<mailto:[email protected]> Betreff: Re: Evaluating empire-db with Spring Boot ok, managed to implement a working spring boot example. opened a pull request for the new example: https://github.com/apache/empire-db/pull/11 please review if done properly On Mon, Aug 9, 2021 at 7:55 PM Ralf Eichinger <[email protected]<mailto:[email protected]>> wrote: I have to questions: 1. Is there an example code using empire-db with spring boot? e.g. using common application properties for connection/database setup currently I am using jdbi but do not like the "functional programming" row mapping... the code example here: https://github.com/apache/empire-db/tree/master/empire-db-examples/empire-db-example-spring seems to map empire-db to spring jdbc templates... but I want a barebones empire-db setup in a spring boot (without jdbc template - for now) to get used to it. any tutorial/documentation beside this one: http://empire-db.apache.org/documentation/tutorial.htm ? 2. I have JSONB columns in my postgres database. How to handle json functions with empire-db? https://www.postgresql.org/docs/12/functions-json.html
