Exposed: Exposed slow
I’m trying to connect to the H2 database on an embedded device.
The connection using
Database.connect("jdbc:h2:~/testdb;DB_CLOSE_DELAY=-1", driver = "org.h2.Driver", user = "root", password = "")
takes about 7s to create/open a database, but the connection using another library, for example kotliquery
val create = measureTimeMillis {
sess = sessionOf("jdbc:h2:~/testdb;DB_CLOSE_DELAY=-1", "root", "")
sess.execute(queryOf("CREATE TABLE IF NOT EXISTS RandomText(ID INT PRIMARY KEY auto_increment, text VARCHAR(15));"))
}
takes about 2s.
Any reason for that overhead and is there any way to speed it up?
We’re running the program and the database on an embedded device called Colibri IMx6, and the speedup would greatly help us.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 16 (7 by maintainers)
Sure thing! I’m on it! @Tapac new commit has been pushed! This is an example output from my PC
and this is the output from Colibri imx6