{"id":49801159,"url":"https://github.com/ehab-elshimi/native-doctrine-orm","last_synced_at":"2026-05-12T14:03:47.689Z","repository":{"id":323684107,"uuid":"1094286017","full_name":"ehab-elshimi/native-doctrine-orm","owner":"ehab-elshimi","description":"Minimal backend built with native PHP 8 and Doctrine ORM, focusing on clean structure and real fundamentals.","archived":false,"fork":false,"pushed_at":"2025-11-21T15:53:06.000Z","size":36,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-02-19T22:41:00.005Z","etag":null,"topics":["backend","datamapper","dependency-injection","doctrine","doctrine-dbal","doctrine-orm","enterprise-solutions","europe","european-job-search","european-union","mvc-architecture","mysql-database","native-php","open-jobs","php","repository-service-api-pattern","service-container","software-development"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/ehab-elshimi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-11-11T14:05:46.000Z","updated_at":"2025-11-21T15:53:10.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ehab-elshimi/native-doctrine-orm","commit_stats":null,"previous_names":["ehab-elshimi/native-doctrine-orm"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ehab-elshimi/native-doctrine-orm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ehab-elshimi%2Fnative-doctrine-orm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ehab-elshimi%2Fnative-doctrine-orm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ehab-elshimi%2Fnative-doctrine-orm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ehab-elshimi%2Fnative-doctrine-orm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ehab-elshimi","download_url":"https://codeload.github.com/ehab-elshimi/native-doctrine-orm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ehab-elshimi%2Fnative-doctrine-orm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32942160,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-12T09:19:52.626Z","status":"ssl_error","status_checked_at":"2026-05-12T09:17:33.438Z","response_time":102,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6: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":["backend","datamapper","dependency-injection","doctrine","doctrine-dbal","doctrine-orm","enterprise-solutions","europe","european-job-search","european-union","mvc-architecture","mysql-database","native-php","open-jobs","php","repository-service-api-pattern","service-container","software-development"],"created_at":"2026-05-12T14:03:45.867Z","updated_at":"2026-05-12T14:03:47.684Z","avatar_url":"https://github.com/ehab-elshimi.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Doctrine Category–Product Mini Framework\n\nA **small PHP project** built with **native PHP 8+**, **Doctrine ORM**, and a **custom dependency injection container**, without relying on Laravel or Symfony.  \n\nIt demonstrates **basic backend architecture**, including **entity relationships, simple API handling, and data filtering**.  \n\nThis project is intended to **showcase real backend skills** in PHP and Doctrine for **European backend opportunities**, focusing on clean, maintainable, and framework-independent code.\n\n---\n\n## ✅ Project Highlights\n\n* **Native PHP \u0026 Doctrine Mastery**\n\n  * Full control of entity mapping using **Doctrine Attributes**\n  * One-to-Many and Many-to-One relationships without relying on a framework\n  * Repository pattern and advanced QueryBuilder usage\n  * Filtering using Doctrine **Criteria**, **Collection filters**, and **custom queries**\n\n* **Custom Dependency Injection Container**\n\n  * Handmade container showing understanding of DI principles\n  * Lazy-loaded services and controllers\n  * Clean separation between business logic and routing\n\n* **Services \u0026 Controllers Layered Architecture**\n\n  * `CategoryService` and `ProductService` contain business logic\n  * Controllers handle only requests and output, keeping code modular\n\n* **Caching with Symfony Cache Adapter**\n\n  * Caching categories and products for performance\n  * Debug routes to inspect cached data\n\n* **Multiple Filtering Techniques for Products**\n\n  1. **QueryBuilder** – database-level filtering\n  2. **Collection filter** – in-memory PHP filtering\n  3. **Doctrine Criteria** – reusable and expressive filters\n\n* **Clean, Minimal, Readable Code**\n\n  * No boilerplate from Laravel/Symfony\n  * Focus on **real-world backend architecture and native PHP skills**\n\n---\n\n## 📁 Project Structure\n\n```\nsrc/\n └── App/\n      ├── Controllers/\n      │     ├── CategoryController.php\n      │     └── ProductController.php\n      ├── Services/\n      │     ├── CategoryService.php\n      │     └── ProductService.php\n      ├── Entity/\n      │     ├── Category.php\n      │     └── Product.php\n      ├── Repository/\n      │     ├── CategoryRepository.php\n      │     └── ProductRepository.php\n      └── Core/\n            └── Container.php   ← handcrafted DI container\nconfig/\n └── bootstrap.php             ← container setup + services registration\n index.php                 ← front controller with routing\n```\n\n---\n\n## 🛠 Requirements\n\n* **PHP ≥ 8.1** (native features \u0026 attributes)\n* Composer\n* MySQL / MariaDB\n* Doctrine ORM (installed via Composer)\n\n---\n\n## 📦 Installation\n\n1. Clone repository:\n\n```bash\ngit clone https://github.com/your-username/native-doctrine-orm.git\ncd native-doctrine-orm\n```\n\n2. Install dependencies:\n\n```bash\ncomposer install\n```\n\n3. Configure your database in `config/bootstrap.php`.\n\n4. Generate database tables:\n\n```bash\nvendor/bin/doctrine orm:schema-tool:update --force\n```\n\n5. Start local server:\n\n```bash\nphp -S localhost:8000\n```\n\nOpen in browser: `http://localhost:8000`\n\n---\n\n## 🧭 Available Routes\n\n### Categories\n\n| Route                                   | Description                             |\n| --------------------------------------- | --------------------------------------- |\n| `?uri=categories`                       | List all categories                     |\n| `?uri=category-detail\u0026name=Electronics` | Show a single category                  |\n| `?uri=category-prices1`                 | Filter products (QueryBuilder)          |\n| `?uri=category-prices2`                 | Filter products (PHP Collection filter) |\n| `?uri=category-prices3`                 | Filter products (Doctrine Criteria)     |\n| `?uri=cache-debug`                      | Inspect cached category cache           |\n\n### Products\n\n| Route                                     | Description                         |\n| ----------------------------------------- | ----------------------------------- |\n| `?uri=products`                           | List all products                   |\n| `?uri=product-detail\u0026product_id=1`        | Show single product                 |\n| `?uri=products-by-category\u0026category_id=3` | Products in a category              |\n| `?uri=products-by-price\u0026min=5000`         | Products above minimum price        |\n| `?uri=products-with-category`             | Join products with their categories |\n\n---\n\n## 🎯 Why This Project Matters for European Recruiters\n\n* **Native PHP \u0026 Doctrine skills** – you demonstrate mastery of backend without frameworks\n* **Clean architecture** – services, controllers, repositories, and DI container\n* **Scalable \u0026 maintainable** – shows understanding of real enterprise projects\n* **Problem-solving mindset** – multiple filtering solutions, caching, and entity relationships\n\n---\n\n## 🧠 Learning Purpose\n\n* Deep understanding of **Doctrine ORM internals** (Unit of Work, Proxies, Repositories)  \n* Building **MVC applications from scratch** using native PHP  \n* Designing **scalable, maintainable backend systems** with clean architecture  \n* Implementing **AI-powered workflow automation** and intelligent backend processes  \n* Developing robust **APIs and integration with 3rd-party services**  \n* Preparing for **open Backend PHP roles in the European Union**, showcasing native PHP, automation, and API skills\n\n---\n\n## 🤝 Contributions\n\n* Extend entities and relationships\n* Add custom router or event system\n* Implement autowiring for the container\n* Add tests and CI/CD pipelines\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fehab-elshimi%2Fnative-doctrine-orm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fehab-elshimi%2Fnative-doctrine-orm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fehab-elshimi%2Fnative-doctrine-orm/lists"}