{"id":27180049,"url":"https://github.com/tennyros/make-it-healthy","last_synced_at":"2026-04-21T16:36:17.397Z","repository":{"id":286275862,"uuid":"960809238","full_name":"tennyros/make-it-healthy","owner":"tennyros","description":"Nutrition Tracking REST API","archived":false,"fork":false,"pushed_at":"2025-04-14T18:51:00.000Z","size":96,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"dev","last_synced_at":"2025-06-21T10:46:12.678Z","etag":null,"topics":["jacoco","java-17","junit5","liquibase","mapstruct","maven","mockito","postgresql","rest-api","spirng-data-jpa-hibernate","spring-boot","swagger-ui"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tennyros.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-04-05T05:37:40.000Z","updated_at":"2025-04-23T06:30:56.000Z","dependencies_parsed_at":"2025-04-10T04:48:48.417Z","dependency_job_id":null,"html_url":"https://github.com/tennyros/make-it-healthy","commit_stats":null,"previous_names":["tennyros/make-it-healthy"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tennyros/make-it-healthy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tennyros%2Fmake-it-healthy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tennyros%2Fmake-it-healthy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tennyros%2Fmake-it-healthy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tennyros%2Fmake-it-healthy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tennyros","download_url":"https://codeload.github.com/tennyros/make-it-healthy/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tennyros%2Fmake-it-healthy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32100517,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-21T11:25:29.218Z","status":"ssl_error","status_checked_at":"2026-04-21T11:25:28.499Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["jacoco","java-17","junit5","liquibase","mapstruct","maven","mockito","postgresql","rest-api","spirng-data-jpa-hibernate","spring-boot","swagger-ui"],"created_at":"2025-04-09T14:25:23.755Z","updated_at":"2026-04-21T16:36:17.309Z","avatar_url":"https://github.com/tennyros.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Make it Healthy\n\n![CI Status](https://github.com/tennyros/make-it-healthy/workflows/CI%20Pipeline%20with%20Maven/badge.svg)\n![Coverage](https://github.com/tennyros/make-it-healthy/raw/coverage-badge/.github/badges/jacoco.svg)\n![Java 17](https://img.shields.io/badge/Java-17-blue)\n![Spring Boot 3.4.4](https://img.shields.io/badge/Spring_Boot-3.4.4-brightgreen)\n\n**Make It Healthy** is a REST API service for tracking daily calorie intake and user diet.\n\n## Tech Stack\n\n| Component                       | Version | Purpose                                          |\n|---------------------------------|---------|--------------------------------------------------|\n| Spring Boot                     | 3.4.4   | Backend framework                                |\n| Hibernate ORM (Spring Data JPA) | 6.6.11  | ORM framework for managing Java persistence with |\n| Maven (wrapper)                 | 3.9.9   | Project build tool                               |\n| PostgreSQL                      | 15+     | Database management system                       |\n| Liquibase                       | 4.31.1  | Database migrations                              |\n| MapStruct                       | 1.6.3   | Object mapping (DTO/Entity)                      |\n| JUnit 5                         | 5.11.4  | Test framework for unit tests                    |\n| Mockito                         | 5.14.2  | Test framework for mocking in unit tests         |\n| JaCoCo                          | 0.8.13  | Test coverage reports                            |\n| Springdoc OpenAPI               | 2.8.6   | API documentation (Swagger UI for Spring)        |\n\n## Project Structure\n\n```text\nSource code structure (dev branch):\nsrc/\n├── main/\n│   ├── java/\n│   │   └── com/github/tennyros/makeithealthy/\n│   │       ├── config/      # Configurations\n│   │       ├── dto/         # Data Transfer Objects\n│   │       │   ├── request/     # Request DTOs\n│   │       │   └── response/    # Response DTOs\n│   │       │       └── reporting/    # Report DTOs\n│   │       ├── entity/      # Data models\n│   │       ├── exception/   # Own exceptions\n│   │       ├── http/        # REST API\n│   │       │   ├── advice/     # Exception Handlers\n│   │       │   └── rest/       # REST Controllers\n│   │       ├── mapper/      # MapStruct mappers\n│   │       ├── repository/  # Data Access Objects\n│   │       └── service/     # Business logic\n│   └── resources/\n│       ├── db/changelog/    # Liquibase migrations\n│       ├── application.yml  # Main configuration\n│       ├── application-dev.yml   # Development configuration\n│       └── application-prod.yml  # Production configuration\n├── test/\n│   ├── java/\n│   │   └── com/github/tennyros/makeithealthy/\n│   │       └── unit/        # Unit tests\n│   │           ├── controller/   # Controller layer unit tests\n│   │           └── service/      # Service layer unit tests\n│   └── resources/\n│       └── application-test.yml  # Test configuration\n├── postman/  # json Postman API test collection\npom.xml\n\nBuild artifacts:\ntarget/\n├── generated-sources/\n│   ├── annotations/\n│   │   └── com.github.tennyros.makeithealthy.mapper/  # Auto-generated MapStruct classes\n├── reports-report/  # JaCoCo coverage reports\n```\n\n## Quick Start\n\n### Prerequisites\n\n1. **Java 17+**\n2. **PostgreSQL 15+** (local, remote or docker container instance)\n3. **Maven 3.9.9** (wrapper included)\n\n### Setup\n\n**1. Clone the repository:**\n\n```bash\ngit clone https://github.com/tennyros/make-it-healthy.git\ncd make-it-healthy\n```\n\n**2. Copy the .env file and change the credentials if necessary:**\n\n```bash\ncp .env.example .env\n```\n\n**3. Run PostgreSQL via Docker (optional, if you don’t run own DB):**\n\n```bash\n# Copy the example config (if not customized yet)  \ncp docker-compose.example.yml docker-compose.yml  \n\n# Start PostgreSQL in Docker  \ndocker-compose up -d\n\nIf using docker-compose, PostgreSQL will be available at \nlocalhost:5433 (default credentials: postgres/root).\n\nIf you already have PostgreSQL, ensure application.yml/.env matches your DB settings.\n```\n\n**4. Application build:**\n\n```bash\n./mvnw clean install -Dspring.profiles.active=dev\n```\n\n**5. Run the application:**\n\n```bash\n# Run via terminal:\n./mvnw spring-boot:run -Dspring-boot.run.profiles=dev\n\n# Run via Intellij Idea (Shift + F10):\nType dev in Active profiles Edit Configurations of main class to setup profile\n\nApplication port is 8008\n```\n\n**After this, the API will be available at:**\n\n```url\nhttp://localhost:8008/swagger-ui.html\n```\n\n## Testing\n\n**Test types:**\n\n```text\nunit/ - Unit tests\n```\n\n**Running tests:**\n\n```bash\n# All tests\n./mvnw test -Dspring.profiles.active=test\n\n# Run a specific test\n./mvnw test -Dspring.profiles.active=test -Dtest=YourTestName\n```\n\n## API Testing with Postman\n\nYou can test and explore the API using the included Postman collection.\n\n### Included File\n\n- **make-it-healthy-app.postman_collection.json** – API requests for user, meal, food intake, and reporting operations.\n\n### How to Use\n\n1. Install Postman – [Download here](https://www.postman.com/downloads/).\n2. Open Postman → `File \u003e Import` → Choose the `make-it-healthy-app.postman_collection.json` file.\n3. Click on the variable `{{url}}` in any request and set it to your running API base URL (e.g., `http://localhost:8008`).\n4. Click **Send** to test endpoints.\n\n\u003e ℹ️ The collection already includes the `{{url}}` variable pointing to `http://localhost:8008`. You can edit it if needed.\n\n## CI Pipeline\n\n```text\nThe project is set up with CI to automatically build \nand test on pull requests using GitHub Actions.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftennyros%2Fmake-it-healthy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftennyros%2Fmake-it-healthy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftennyros%2Fmake-it-healthy/lists"}