{"id":51012169,"url":"https://github.com/nico-iaco/grocery-be","last_synced_at":"2026-06-21T04:30:36.862Z","repository":{"id":61056205,"uuid":"529277339","full_name":"nico-iaco/grocery-be","owner":"nico-iaco","description":"Personal project about food storage to avoid wasting food","archived":false,"fork":false,"pushed_at":"2024-10-21T19:13:42.000Z","size":568,"stargazers_count":3,"open_issues_count":3,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-22T12:04:09.858Z","etag":null,"topics":["circuit-breaker","docker-multiarch","hacktoberfest","java-21","kubernetes","kustomize","personal-project","spring-boot","spring-boot-3","spring-native"],"latest_commit_sha":null,"homepage":"","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/nico-iaco.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":"2022-08-26T13:53:18.000Z","updated_at":"2024-10-21T19:13:46.000Z","dependencies_parsed_at":"2023-11-12T19:25:10.128Z","dependency_job_id":"0e764de7-79ec-4a83-9221-182f79048618","html_url":"https://github.com/nico-iaco/grocery-be","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/nico-iaco/grocery-be","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nico-iaco%2Fgrocery-be","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nico-iaco%2Fgrocery-be/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nico-iaco%2Fgrocery-be/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nico-iaco%2Fgrocery-be/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nico-iaco","download_url":"https://codeload.github.com/nico-iaco/grocery-be/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nico-iaco%2Fgrocery-be/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34594326,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-21T02:00:05.568Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["circuit-breaker","docker-multiarch","hacktoberfest","java-21","kubernetes","kustomize","personal-project","spring-boot","spring-boot-3","spring-native"],"created_at":"2026-06-21T04:30:34.184Z","updated_at":"2026-06-21T04:30:36.853Z","avatar_url":"https://github.com/nico-iaco.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Grocery-be\n\n[![Build and Push Image to Google Cloud Platform](https://github.com/nico-iaco/grocery-be/actions/workflows/gcp.yml/badge.svg)](https://github.com/nico-iaco/grocery-be/actions/workflows/gcp.yml)\n\n## Description\n\nThis app is like an inventory for your groceries. You can track your groceries and their expiration dates. You can also\nadd new items to your inventory.\nWhen used with [food-track-be](https://github.com/nico-iaco/food-track-be) you can track your food usage and see how\nmuch you have left.\nThis app use [food-details-integrator-be](https://github.com/nico-iaco/food-details-integrator-be) to retrive additional\ninformation about the food like nutritional details.\n\n## Features\n\n- [x] Manage items in your inventory\n- [x] Track expiration dates\n- [x] The application is built in native mode with spring native to improve startup time\n\n## Requirements\n\n- [PostgreSQL](https://www.postgresql.org/)\n- [food-details-integrator-be](https://github.com/nico-iaco/food-details-integrator-be) (optional)\n\n## Installation\n\n### Cluster installation\n\nTo install the application in a cluster you need to have a running PostgreSQL database. Then you have to create grocery\nnamespace, modify the kustomization.yaml file to match your configuration and run the following command:\n\n```bash\nkubectl apply -k k8s/overlays/qa\n```\n\n### Local installation\n\nTo run the application locally with docker. To do so run the following command:\n\n```bash\ndocker run -p 8080:8080 ghcr.io/nico-iaco/grocery-be:latest -e {All the environment variables}\n```\n\n## Environment variables\n\n| Name                  | Description                              | Default value         |\n|-----------------------|------------------------------------------|-----------------------|\n| DB_URL                | The host of the database                 |                       |\n| DB_PORT               | The port of the database                 |                       |\n| DB_USER               | The user of the database                 |                       |\n| DB_PASSWORD           | The password of the database             |                       |\n| DB_NAME               | The name of the database                 |                       |\n| FOOD_DETAILS_BASE_URL | Base url for food-details-integration-be | http://localhost:8081 |\n\n## Database\n\nThe database is created automatically by the application. The database is created with the following tables:\n\n- item\n- transaction\n- item_transaction_list\n- food_detail\n\nThis is the schema of the database:\n![Database schema](./docs/groceryBeERSchema.png)\n\nHowever, here is the DDL for the database:\n\n```sql\ncreate table pantry\n(\n    id          uuid not null\n        primary key,\n    description varchar(255),\n    name        varchar(255)\n);\n\ncreate table item\n(\n    id        uuid not null\n        primary key,\n    barcode   varchar(255),\n    name      varchar(255),\n    user_id   varchar(255),\n    vendor    varchar(255),\n    pantry_id uuid\n        constraint fkiv459qrocp55s73hh0dmtwsmp\n            references pantry\n);\n\ncreate table transaction\n(\n    id                 uuid                       not null\n        primary key,\n    expiration_date    date,\n    price              double precision           not null,\n    quantity           double precision           not null,\n    unit               varchar(255),\n    vendor             varchar(255),\n    item_id            uuid\n        constraint fk3ibvxnlgyfslk9tm8vfcfqb0f\n            references item,\n    available_quantity double precision default 0 not null,\n    purchase_date      date,\n    quantity_std       double precision           not null,\n    seller             varchar(255)\n);\n\ncreate table item_transaction_list\n(\n    item_id             uuid not null\n        constraint fka3efk1qwebbyior4d54kreuf7\n            references item,\n    transaction_list_id uuid not null\n        constraint uk_2biy54jvr5xe1ej0eq9kj313d\n            unique\n        constraint fk3c5txed590yrvt06opdmmc3g2\n            references transaction\n);\n\n\ncreate table food_detail\n(\n    id                  uuid not null\n        primary key,\n    item_id             uuid\n        constraint fk3ibvxnlgyfslk9tm8vfcfqb0f\n            references item,\n    generic_name        varchar(255),\n    image_nutrition_url varchar(255),\n    image_url           varchar(255)\n);\n\ncreate table user_pantry\n(\n    pantry_id uuid         not null references pantry,\n    user_id   varchar(255) not null,\n    primary key (pantry_id, user_id)\n);\n\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnico-iaco%2Fgrocery-be","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnico-iaco%2Fgrocery-be","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnico-iaco%2Fgrocery-be/lists"}