This project provides the service implementation for clients to interact with Snippets.
The Snippet is accessible through the API provided as an HTTP service in this project. API Docs were not implemented yet, needs to be done.
This is a Java project and requires you have a Java JDK 1.11 or higher installed.
This project uses Gradle build system, you can
view all possible build actions for project via:
./gradlew tasks -all
Tests for this project can be run from top folder of project in command line:
./gradlew test
There is a build script to create runtime artifacts from the source files for this project.
The build script is capable to generate several output formats of runtimes,
To build executable Java jar file output, execute the build script from top folder of project in command line:
./gradlew assemble
The compiled jar file will be located in a generated sub-directory under project root directory in ./build/lib
Can use the Gradle build to run latest source code from cli:
./gradlew bootRun
Run the compiled jar directly by invoking the JRE 'java' VM from command line:
java -jar ./build/libs/snippets-0.0.1-SNAPSHOT.jar
Currently in-memory relational db.
- I ran a bit long on time, spent 3.5hrs on the challenge.
- I didn't get the service config'd to start on HTTPS, when the web service starts up, it is running on http://localhost:8081
- H2 DB config could be changed to persist to disk for one of extensions.
- I added extension for updating snippet via PUT API
- would like to have more unit tests.
- would like to have added some debug level logging around(entry/exit) on each endpoint.