Code Monkey home page Code Monkey logo

todo-list-spring-boot-webflux-kotlin's Introduction

Todo List (Spring Boot)


Tech Stack

Features

  • Mockk + Spring Mockk to mock beans.
  • Kotest assertions provides fluent Kotlin DSL API for assertions in tests.
  • Spring Doc to expose OpenAPI via Swagger at http://localhost:9090/actuator/webjars/swagger-ui/index.html
  • Docker Compose to serve a running Postgres when running the application.
  • Test persistence with a Postgres database running in TestContainers.

Prerequisites

Libraries

Troubleshooting

Ensure Java Home variable is set
echo $JAVA_HOME

Should see

/Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Home

If not, you either don't have it downloaded, or Java Home variable is not set.

Ensure Java version is downloaded
/usr/libexec/java_home -V

Should see installed JDKs:

17.0.1 (x86_64) "Oracle Corporation" - "Java SE 17.0.1" /Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Home
16.0.1 (x86_64) "Oracle Corporation" - "OpenJDK 16.0.1" /Users/user/Library/Java/JavaVirtualMachines/openjdk-16.0.1/Contents/Home
11.0.13 (x86_64) "Oracle Corporation" - "Java SE 11.0.13" /Library/Java/JavaVirtualMachines/jdk-11.0.13.jdk/Contents/Home
...

If not found, have not downloaded the JDK properly.

Ensure correct v17 is showing
/usr/libexec/java_home -v 17

Should see

/Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Home

If you see a non-Oracle JDK, like open JDK, you need to uninstall it first.

Set Java Home variable

Find out what shell version you're using:

echo $SHELL

If you're using ZSH: you ought to be updating ~/.zshrc else ~/.bash_profile for the following steps.

Update your profile:

[emacs/vim/atom] ~/.zshrc

Add the following line:

export JAVA_HOME=$(/usr/libexec/java_home -v 17)

Update shell profile

source ~/.zshrc

Build & Run Project

Clean Project
./gradlew clean
Build Project
./gradlew build
Run Project
./gradlew bootRun --args='--spring.profiles.active=dev'

// or
./gradlew build
java -jar build/todo-xxxx.jar 

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.