Service registry for the Elara microservices platform, built with Netflix Eureka Server.
This service is the runtime source of truth for service instance discovery. It allows clients and edge components to resolve backend locations dynamically instead of relying on static host/port wiring.
discovery-service is a Spring Boot application enabled with @EnableEurekaServer.
At runtime it:
- receives registrations from microservice instances,
- maintains the active service registry,
- exposes discovery metadata used by clients and infrastructure components.
Current local server settings (src/main/resources/application.yml):
spring.application.name: discovery-serviceserver.port: 8761eureka.client.register-with-eureka: falseeureka.client.fetch-registry: false
Primary consumers of service discovery:
discovery-servicestarts on port8761.- Service instances boot and register against
http://localhost:8761/eureka/. - API Gateway and peer services resolve logical service IDs to healthy instances through Eureka.
- Routing and service-to-service communication use registry data instead of fixed endpoints.
In this platform, service registration URLs are typically distributed through config-service from centralized-configuration, while this repository remains focused on Eureka Server behavior.
- Eureka dashboard:
http://localhost:8761/ - Registry API base:
http://localhost:8761/eureka/
Common inspection endpoint:
curl http://localhost:8761/eureka/appsRequirements:
- Java 21
- Maven Wrapper (
./mvnw)
Commands:
./mvnw clean install
./mvnw test
./mvnw spring-boot:runSingle test execution:
./mvnw test -Dtest=DiscoveryServiceApplicationTests
./mvnw test -Dtest=DiscoveryServiceApplicationTests#contextLoads- Start
discovery-servicebefore services that depend on registration/discovery. - Keep service IDs stable (
spring.application.name) to avoid route or lookup regressions. - Avoid hardcoded downstream URLs in clients when discovery is the expected runtime contract.
- Monitor registry churn (rapid register/deregister cycles), as it usually indicates unhealthy instances or network instability.
- Keep this repository limited to discovery concerns; manage environment-specific client config in
centralized-configuration.