Commit Graph

13 Commits

Author SHA1 Message Date
haylan 2f3268c0b7 refactor: reorganise Service/ into Provider/ and Renderer/ sub-namespaces
Move all provider-related classes, enums, interface and trait into
App\Service\Provider; move SvgRenderer into App\Service\Renderer.
ContributionAggregator stays at the Service root as the orchestrator.
Test namespaces and use statements updated to match.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-31 00:10:09 +02:00
haylan 61b7735afc refactor(renderer): add strict_types declaration and make class final
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 14:13:51 +02:00
haylan c70d96c3aa feat(health): make /health report per-provider probe status
Introduce ProviderHealthChecker which probes each configured provider
via AutowireIterator. Wire it into GraphController so /health returns
detailed per-provider status and responds 503 when any provider is
in a degraded state.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 14:13:24 +02:00
haylan d3b9463c57 feat(provider): implement ping and probe on GitHub, GitLab, and Gitea
Add getName() and ping() to each provider and wire ProbeTrait. Make
all classes final, add strict_types declarations, and replace generic
RuntimeException with typed HTTP exceptions so probe() can classify
auth failures and unreachable endpoints correctly.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 14:13:14 +02:00
haylan 71bfb38028 feat(provider): add health-probe contract and supporting value objects
Add getName(), ping(), and probe() to ProviderInterface. Introduce
ProbeTrait to classify HTTP/transport exceptions into typed error codes,
ProviderStatus as the result value object, and ProviderStatusType /
ProviderErrorCode as backing enums.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 14:13:07 +02:00
haylan c205fed14b refactor(controller): extract contribution aggregation into dedicated service
Move fetchAllContributions and merge logic from GraphController into a new
ContributionAggregator service. Replace deprecated TaggedIterator with
AutowireIterator throughout.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-30 12:58:17 +02:00
haylan cceda8abf2 feat: integrate Monolog for enhanced logging across providers and controller 2026-05-29 18:57:25 +02:00
haylan 8b8ec9ab2f feat: add redirect from index route to graph.svg with query parameters 2026-05-29 18:28:56 +02:00
haylan 56035096c6 feat: implement multi-provider architecture for contribution fetching and add Docker support 2026-05-29 11:51:05 +02:00
haylan fa035781fd fix(svg-renderer): correct date alignment and drop unused parameter
- modify('Sunday') → modify('last Sunday') so the grid start is
  reliably the prior Sunday when today is already Sunday
- Remove unused $totalW from renderLegend signature
- Remove unused GAP constant (value preserved inline as a comment on STEP)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 22:09:31 +02:00
haylan d1dce19832 refactor(github): migrate contribution query to GraphQL bundle
Use GraphQLApiClientRegistryInterface to build the query via the
bundle's query builder. Keep Symfony HttpClient for the actual POST
since GitHub requires application/json (the bundle's transport sends
form_params instead).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-28 22:09:25 +02:00
haylan 3a42bec2b7 Add environment variables for GitHub, GitLab, Gitea, and allowed hosts configuration 2026-05-28 19:53:33 +02:00
haylan 342490035b Initialize git-contribution-graph project with Docker setup, environment configuration, and core functionality for merging contributions from GitHub, GitLab, and Gitea into an SVG heatmap. 2026-05-28 19:35:44 +02:00