Had to comment Deregistering original JDBC driver to be able to add oracle database with lein ring server

Hi,

I’m trying to use lein ring server to add a local oracle xe 11g database.

I’m using the 0.36.x release, I built the drivers, built the client

Problem was: When I try to add a oracle database I was getting Could not initialize class oracle.net.nt.Clock like Getting Error while connecting to Oracle DB

What I’ve noticed different from executing the metabase jar directly was a message from these code

(doseq [driver (enumeration-seq (DriverManager/getDrivers))
:when (instance? klass driver)]
(log/debug (u/format-color 'cyan (trs “Deregistering original JDBC driver {0}…” driver)))
(DriverManager/deregisterDriver driver)
)

I’ve commented this doseq block, and the lein ring server allowed me to add oracle 11g xe database successfully

The schemas (without forward slash tables) were recognized .

Why is that ?

The remaining problem (another one) is I cannot browse the tables (even with sample database) with lein ring server. I get:

No implementation of method: :write-body-to-stream of protocol: #'ring.core.protocols/StreamableResponseBody found for class: metabase.async.streaming_response.StreamingResponse",

I’m using
openjdk version “1.8.0_265”
Ubuntu 18.04.5 LTS \n \l
ojdbc 19.3.0.0

Thanks in advance,

Geraldo Lopes de Souza

Hi @geraldodev
You cannot use lein ring server currently - use lein run or REPL:
https://github.com/metabase/metabase/issues/12181

1 Like

Thank you flamber!