Skip to content

Step14: add dockerfile, docker-compose and integration test#16

Merged
Parth576 merged 4 commits intomainfrom
step14
Mar 1, 2026
Merged

Step14: add dockerfile, docker-compose and integration test#16
Parth576 merged 4 commits intomainfrom
step14

Conversation

@Parth576
Copy link
Owner

@Parth576 Parth576 commented Mar 1, 2026

No description provided.

Multi-stage Dockerfile compiles Go backend into a static binary
(CGO_ENABLED=0) with distroless runtime. Docker Compose configures
backend and Qdrant services with health checks, named volumes for
data persistence, and environment variable loading from .env file.

Assisted by the code-assist SOP
Replace nil stubs in main.go with fully constructed pipeline dependencies:
embedding client (OpenAI), vector store (Qdrant), LLM client (Anthropic),
RAG pipeline, in-memory cache, and analyzer. Add HealthCheck method to
QdrantStore for Qdrant connectivity verification on the health endpoint.

- Parse CacheDefaultTTL with fail-fast validation
- Initialize components in dependency order with structured logging
- Wire analyzer as PipelineRunner and store.HealthCheck to router
- Add 3 tests for QdrantStore.HealthCheck (success, error, context)

Assisted by the code-assist SOP
…eline

Add deterministic integration tests that exercise the complete HTTP pipeline
with mocked external services, plus build-tag gated tests for real API keys.

Deterministic tests (14): full pipeline happy path, score validation, risk
level consistency, caching behavior, non-policy content, invalid requests,
health endpoint, CORS/request-ID headers, content type validation.

Real integration tests (3): gated with //go:build integration tag, skip
gracefully when API keys unavailable.

Assisted by the code-assist SOP
@Parth576 Parth576 merged commit 16aef05 into main Mar 1, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant