This repo has a "Hello World" Java application that uses the Hibernate ORM to talk to CockroachDB.
To run the code:
-
Start a local, insecure CockroachDB cluster.
-
Create a
bank
database andmaxroach
user as described in Build a Java app with CockroachDB and Hibernate. -
From the SQL client:
GRANT ALL ON DATABASE bank TO maxroach
-
In your terminal, from this directory:
gradle run