{"id":21406163,"url":"https://github.com/jorgeacetozi/notepad","last_synced_at":"2025-07-14T00:32:09.931Z","repository":{"id":54511406,"uuid":"101947029","full_name":"jorgeacetozi/notepad","owner":"jorgeacetozi","description":"Sample Spring Boot app used in my book Continuous Delivery for Java Apps: Build a CD Pipeline Step by Step Using Kubernetes, Docker, Vagrant, Jenkins, Spring, Maven and Artifactory","archived":false,"fork":false,"pushed_at":"2021-02-14T14:06:22.000Z","size":1020,"stargazers_count":15,"open_issues_count":2,"forks_count":85,"subscribers_count":2,"default_branch":"master","last_synced_at":"2023-02-27T10:06:45.156Z","etag":null,"topics":["continuous-delivery","continuous-integration","docker","kubernetes","mysql","spring-boot"],"latest_commit_sha":null,"homepage":"https://leanpub.com/continuous-delivery-for-java-apps","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jorgeacetozi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-31T01:50:08.000Z","updated_at":"2021-03-29T01:27:46.000Z","dependencies_parsed_at":"2022-08-13T18:10:57.153Z","dependency_job_id":null,"html_url":"https://github.com/jorgeacetozi/notepad","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgeacetozi%2Fnotepad","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgeacetozi%2Fnotepad/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgeacetozi%2Fnotepad/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jorgeacetozi%2Fnotepad/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jorgeacetozi","download_url":"https://codeload.github.com/jorgeacetozi/notepad/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225930070,"owners_count":17547105,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["continuous-delivery","continuous-integration","docker","kubernetes","mysql","spring-boot"],"created_at":"2024-11-22T16:31:42.792Z","updated_at":"2024-11-22T16:31:43.303Z","avatar_url":"https://github.com/jorgeacetozi.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Notepad: Simple Spring Boot App\n\nThis simple application is used for demo purposes. It exposes the `actuator` endpoints as well as the `/notes` endpoint, which creates a note when it gets a `POST` request.\n\n## Usage\n\nThe Notepad stores the notes in a MySQL instance, so it expects the MySQL database to be up and running. The bellow command starts a MySQL container with a newly created database `notepad` in it. It also sets up the mysql root password as `root`.\n\n`$ docker run -d --name mysql -e MYSQL_DATABASE=notepad -e MYSQL_ROOT_PASSWORD=root -p 3306:3306 mysql:5.7`\n\nNow, clone this repository and go into the notepad directory:\n\n`$ git clone https://github.com/jorgeacetozi/notepad.git`\n`$ cd notepad`\n\nOnce you succesfully cloned the repository, start the application the jar artifact:\n\n`$ mvn clean install`\n\nWait for the unit and integration tests to run and the artifact to be generated. Eventually it will be stored in the `target/` directory.\n\nNow, start the application:\n\n`$ java -jar $(ls target/*.jar)`\n\nCheck that the application is up and running hitting the actuator `/health` endpoint:\n\n`$ curl http://localhost:8080/health`\n\nCreate a new note:\n\n`$ curl -H \"Content-Type: application/json\" -X POST -d '{\"title\":\"Kubernetes\",\"content\":\"Best container orchestration tool ever\"}' http://localhost:8080/notes`\n\n## Features\n\n- `Flyway` to manage database migrations.\n- `maven-surefire-plugin` to run only unit tests with `mvn test`.\n- `maven-failsafe-plugin` to run unit and integrations tests with `mvn verify`.\n- 1 simple unit test, 2 integrations tests (a api test to ensure that the JSON returned by the endpoint is correct) and a database test (saves a note and ensures that it was successfuly persisted in MySQL).\n- `maven-release-plugin` to release new application versions in GitHub.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorgeacetozi%2Fnotepad","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjorgeacetozi%2Fnotepad","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjorgeacetozi%2Fnotepad/lists"}