Skip to content

crackCodeLogn/diurnal-dbi-service

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

diurnal-dbi-service

Tech stack:

  1. Java 11 - OpenJDK11
  2. Quarkus https://quarkus.io/
  3. Heroku https://dashboard.heroku.com/
  4. Postgres - for prod
  5. CockroachDB - for local dev. CRDB is built on postgres. https://www.cockroachlabs.com/
  6. Swagger - OpenAPI - non prod
  7. OpenFeign
  8. Gson
  9. Protobuf
  10. Lombok
  11. Apache Commons Lang3
  12. Assertj

Important notepoints:

  • Database is using timestamptz to store all time in UTC by default. Whenever the java process will read it from DB, it will get the time converted into the JVM time.

Deployments - Server only (!app):

Serial Version Time Artifact Significant changes
4 1.4 2021-11-07 1900 IST 0.0.5-SNAPSHOT Shifting to Quarkus, DB overhaul, App handling updates
3 1.3 2021-10-30 1000 IST 0.0.4-SNAPSHOT Backup and upload to github, restricting cloud backup rows to 1 year from last date and overhauling configs
2 1.2 2021-10-28 2330 IST 0.0.3-SNAPSHOT Using JPA completely and replacing the hand-written SQL logic
1 1.1 2021-10-24 0.0.2-SNAPSHOT Giving 1 month free premium status to new sign ups
0 1.0 2021-06-08 0.0.1-SNAPSHOT Genesis and deployed to Heroku-free tier

Backup option from postgres:-

psql <DATABASE_URL> \copy (select * from <table_name) to '<local_file.csv>' with CSV;

Backup restore into postgres:-

I had to write customized code to read csv and use the upload endpoint to bulk add.