Skip to content
This repository has been archived by the owner on May 22, 2023. It is now read-only.

A sample Spring Boot application that reads and displays MOVR data stored in CockroachDB

Notifications You must be signed in to change notification settings

timveil-cockroach/movr-spring-boot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MOVR Sample Application - Spring Boot

This is an example, full stack, application using the following technologies:

  • Spring Boot
  • JPA for persistence
  • Thymeleaf for UI templating
  • Bootstrap for UI rendering

⚠️ This project is in active development and likely not stable. Proceed at your own risk. ⚠️

How to Build

./mvnw clean package

How to Run

CockroachDB on Docker

  1. Start a single node CockroachDB instance
docker run -d --name=crdb --hostname=crdb -p 26257:26257 -p 8080:8080 cockroachdb/cockroach:latest start-single-node --insecure
  1. Create the movr database using CockroachDB's workload service
docker exec -it crdb ./cockroach workload init movr 'postgresql://root@crdb:26257?sslmode=disable'
  1. Run the movr workload generator to create data and simulate load
docker exec -it crdb ./cockroach workload run movr --duration=5m 'postgresql://root@crdb:26257?sslmode=disable'
  1. Start an instance of the movr-spring-boot application locally using Maven
./mvnw spring-boot:run -Dspring-boot.run.profiles=local
  1. Open the MOVR UI: http://localhost:8082/

  2. Open the CockroachDB UI: http://localhost:8080/

  3. Shut down the crdb Docker image when ready

docker stop crdb && docker rm crdb

CockroachDB on Kubernetes

todo

About

A sample Spring Boot application that reads and displays MOVR data stored in CockroachDB

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published