{"id":23606097,"url":"https://github.com/truefalse10/bookstore-microprofile","last_synced_at":"2025-11-05T12:30:34.788Z","repository":{"id":56486399,"uuid":"203367930","full_name":"truefalse10/bookstore-microprofile","owner":"truefalse10","description":"java-ee8 project with microprofile","archived":false,"fork":false,"pushed_at":"2020-11-04T16:16:56.000Z","size":56,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-27T13:14:40.755Z","etag":null,"topics":["docker","java","java-ee","jwt","microprofile","openshift"],"latest_commit_sha":null,"homepage":null,"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/truefalse10.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":"2019-08-20T12:04:38.000Z","updated_at":"2020-11-04T16:16:52.000Z","dependencies_parsed_at":"2022-08-15T19:40:27.753Z","dependency_job_id":null,"html_url":"https://github.com/truefalse10/bookstore-microprofile","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/truefalse10%2Fbookstore-microprofile","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/truefalse10%2Fbookstore-microprofile/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/truefalse10%2Fbookstore-microprofile/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/truefalse10%2Fbookstore-microprofile/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/truefalse10","download_url":"https://codeload.github.com/truefalse10/bookstore-microprofile/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239458923,"owners_count":19642100,"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":["docker","java","java-ee","jwt","microprofile","openshift"],"created_at":"2024-12-27T13:14:42.424Z","updated_at":"2025-11-05T12:30:34.655Z","avatar_url":"https://github.com/truefalse10.png","language":"Java","readme":"# bookstore-microprofile\n\u003e simple java-ee project that should evaluate oracle's [microprofile](https://microprofile.io/) specification together with the thinWar approach.\n\n### included microprofile libraries:\n* [microprofile-config](https://microprofile.io/project/eclipse/microprofile-config)\n* [microprofile-jwt](https://microprofile.io/project/eclipse/microprofile-jwt-auth)\n* [microprofile-metrics](https://microprofile.io/project/eclipse/microprofile-metrics)\n\n### persistence:\nfor testing purposes this project uses an h2 database that is filled with dummy data on application start\n\n### authentication with jwt:\nauthentication is done via json-web-token ([JWT](https://jwt.io)). To retrieve the token the login route \nexpects `name` and `password` and returns the token. This token must be sent as `Authorization: Bearer \u003ctoken\u003e`\nheader to access protected routes. The test credentials are `{ \"name\": \"Dieter\", \"password\": \"123Geheim\" }`\n\n### api-endpoints:\nthe app exposes the following endpoints\n```\nGET     /metrics // payara metrics + microprofile-metrics\nGET     /openapi // api documentation\nGET     /bookstore-microprofile/resources/ping\nGET     /bookstore-microprofile/resources/books\nPOST    /bookstore-microprofile/resources/books\nGET     /bookstore-microprofile/resources/books/{id}\n\nPOST    /bookstore-microprofile/resources/user // Login with body { name, password }\n```\n\n## build docker container\n```\nmvn clean package \u0026\u0026 docker build -t com.truefalse/bookstore-microprofile .\n```\n\n## run app in glassfish container\n```\ndocker rm -f bookstore-microprofile || true \u0026\u0026 docker run -d -p 8080:8080 -p 4848:4848 --name bookstore-microprofile com.truefalse/bookstore-microprofile \n```\n\n## deploy app locally with live-reload\nIn order to have a server with live-reload this project uses a tool called [wad](https://github.com/AdamBien/wad).\n\nIf you get errors executing make sure your `$M2_HOME` is set to the maven directory (I installed maven with homebrew and had to manually set it to `/Users/sedi/homebrew/Cellar/maven/3.6.0`)\n\n```\njava -jar wad.jar $PAYARA_DIR/glassfish/domains/domain1/autodeploy\n```\n\n## deploy to OpenShift\nthere is script that builds the application image and pushes it to an openshift cluster (minishift in this case). For custom configuration change variables in `deployOpenshift.sh` and run:\n```\n./deployOpenshift.sh\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftruefalse10%2Fbookstore-microprofile","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftruefalse10%2Fbookstore-microprofile","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftruefalse10%2Fbookstore-microprofile/lists"}