How dwdbk/appdemo works
Project type and purpose
• This is a microservices-based, full-stack backend system, comprised of an API Gateway plus two domain services (Opera Service and Shows Service).
• Purpose: provide a federated GraphQL API for managing operas and their show schedules, with built-in auth, caching, monitoring, and containerized deployment.
File structure
• Top-level directories:
• gateway-service-nodejs: Node.js-based API Gateway (Express + Apollo Federation proxy + cross-cutting middleware)
• opera-service: Spring Boot GraphQL microservice (manages operas, acts, scenes, characters)
• shows-service: Spring Boot GraphQL microservice (manages show schedules, singers, ticket availability)
• Each microservice has:
• src/main/java/... for code
• src/main/resources/db/changelog for Liquibase migrations
• src/main/resources/graphql for schema files
• application.yml for configuration
• gateway-service-nodejs has Dockerfiles, docker-compose, monitoring (Prometheus, Grafana, Logstash), middleware, proxy setup, health checks.
README for additional insights
• Confirms three main runtime components listening on ports 8080 (gateway), 8081 (opera), 8082 (shows).
• Uses Apollo Federation to stitch schemas at gateway.
• Uses custom scalars and directives, Liquibase migrations, Docker/Docker Compose, optional Kubernetes manifests.
• External dependencies: PostgreSQL (one DB per service), Keycloak (OAuth2/JWT), Prometheus, Grafana, Logstash.
Detail level
• Essential sub-components in the gateway: auth middleware, caching layer, proxy.
• Liquibase migrations as part of service startup.
• Monitoring pipelines: metrics endpoint → Prometheus → Grafana dashboards, logs → Logstash → Elasticsearch (if used).