Spring Cloud Netflix & Config
Spring Cloud Netflix & Config Interview with follow-up questions
1. What is Spring Cloud Netflix?
Spring Cloud Netflix was the subproject that integrated Netflix OSS components into Spring Cloud: Eureka (service discovery), Ribbon (client-side load balancing), Hystrix (circuit breaker), and Zuul (API gateway). For years it was the default microservices stack.
The essential 2026 answer is that most of it is retired:
| Netflix component | Status | Modern replacement |
|---|---|---|
| Ribbon | removed | Spring Cloud LoadBalancer |
| Hystrix | removed (EOL) | Resilience4j (via Spring Cloud Circuit Breaker) |
| Zuul | removed | Spring Cloud Gateway |
| Eureka | still supported | — (or Consul / Kubernetes discovery) |
So in current Spring Cloud, only Eureka remains in common use; the rest were moved to maintenance and dropped (around the "Ilford"/2020.x release train). If an interviewer asks about Spring Cloud Netflix, the strong answer is: "It integrated Netflix OSS, but Ribbon, Hystrix, and Zuul have been removed and replaced by Spring Cloud LoadBalancer, Resilience4j, and Spring Cloud Gateway — only Eureka is still used." Knowing this distinction is exactly what separates current from stale knowledge.
Follow-up 1
What are the main components of Spring Cloud Netflix?
The main components of Spring Cloud Netflix are:
Eureka: A service registry and discovery server that allows microservices to register themselves and discover other services.
Ribbon: A client-side load balancing library that provides client-side load balancing algorithms for making HTTP requests to multiple instances of a service.
Hystrix: A fault tolerance library that provides circuit breakers, fallbacks, and bulkheads to handle and control failures in distributed systems.
Zuul: A gateway service that provides dynamic routing, monitoring, resiliency, and security features to enable fine-grained control over microservice requests.
Follow-up 2
How does Spring Cloud Netflix interact with other microservices?
Spring Cloud Netflix provides integration with other microservices through the use of Netflix components. It uses Eureka for service registration and discovery, allowing microservices to find and communicate with each other. Ribbon is used for client-side load balancing, enabling microservices to make HTTP requests to multiple instances of a service. Hystrix provides fault tolerance capabilities, such as circuit breakers, fallbacks, and bulkheads, to handle failures in distributed systems. Zuul acts as a gateway service, allowing fine-grained control over microservice requests, including dynamic routing, monitoring, resiliency, and security features.
Follow-up 3
What is the role of Eureka in Spring Cloud Netflix?
Eureka is a service registry and discovery server in Spring Cloud Netflix. Its role is to allow microservices to register themselves and discover other services. Microservices can register with Eureka by providing their network location (host and port) and a unique identifier. Eureka maintains a registry of all registered services and provides a REST API for other microservices to discover and communicate with them. This enables dynamic scaling and load balancing of microservices in a distributed system.
Follow-up 4
Can you explain the concept of a circuit breaker in the context of Spring Cloud Netflix?
In the context of Spring Cloud Netflix, a circuit breaker is a fault tolerance mechanism provided by Hystrix. It is used to handle and control failures in distributed systems. A circuit breaker monitors the availability and response time of a remote service. If the service fails or takes too long to respond, the circuit breaker trips and subsequent requests to the service are short-circuited. Instead of making actual requests, the circuit breaker returns a fallback response or throws an exception. This helps to prevent cascading failures and provides resilience to the system. Once the remote service becomes available again, the circuit breaker closes and requests are allowed to pass through.
2. What is Spring Cloud Config?
Spring Cloud Config provides centralized, externalized configuration for distributed systems. It has two parts:
- Config Server — a service that serves configuration, typically backed by a Git repository (also filesystem, Vault, JDBC, or cloud stores). Config is versioned, auditable, and environment-/profile-aware.
- Config Client — each microservice fetches its config from the server at startup, so all instances share one source of truth.
# client bootstrap
spring.config.import: optional:configserver:http://config-server:8888
Features interviewers like: per-profile/per-environment files (app-prod.yml), encrypted properties ({cipher}...) and Vault integration for secrets, and dynamic refresh — change config in Git, then trigger /actuator/refresh (often broadcast across all instances via Spring Cloud Bus) so services pick up changes without redeploying.
A current note worth adding: Config Server is still widely used, but teams running on Kubernetes frequently use ConfigMaps/Secrets (via Spring Cloud Kubernetes) instead, since the platform already provides centralized config. Either way, the goal is the same — keep configuration out of the code/artifact and manage it centrally and securely.
Follow-up 1
How does Spring Cloud Config manage application configurations?
Spring Cloud Config uses a centralized configuration server, known as the Config Server, to manage application configurations. The Config Server acts as a single source of truth for all the configuration properties of your applications. It retrieves the configurations from a Git repository or other supported sources and serves them to the client applications when requested.
Follow-up 2
What is the role of a Config Server in Spring Cloud Config?
The Config Server in Spring Cloud Config is responsible for serving the configuration properties to the client applications. It acts as a central repository for storing and managing the configurations. The client applications can request their configurations from the Config Server based on their application name and profile. The Config Server also supports features like encryption and decryption of sensitive configuration properties.
Follow-up 3
How does Spring Cloud Config handle version control?
Spring Cloud Config supports version control of configurations by integrating with a version control system like Git. Each configuration change is committed to the Git repository, allowing you to track the history of configuration changes over time. You can also tag specific versions of the configurations for easy reference. The Config Server retrieves the configurations from the Git repository based on the specified version or branch.
Follow-up 4
Can you explain the process of refreshing configuration changes in Spring Cloud Config?
In Spring Cloud Config, the process of refreshing configuration changes involves the following steps:
- The client application sends a refresh request to the Config Server.
- The Config Server checks for any changes in the configuration properties since the last refresh.
- If there are any changes, the Config Server sends the updated configurations to the client application.
- The client application reloads the updated configurations and applies them.
This process allows the client applications to dynamically update their configurations without requiring a restart.
3. How do Spring Cloud Netflix and Spring Cloud Config work together?
In a classic Spring Cloud setup they play complementary roles: Spring Cloud Config centralizes configuration, while service discovery (Eureka) lets services find each other — and they reinforce one another:
- Config from a central server — each service (including discovery clients and the gateway) pulls its settings from the Config Server at startup, so the whole fleet shares one versioned source of truth.
- Discovery-located Config Server — instead of hard-coding the Config Server's URL, services can discover it via Eureka ("discovery-first" config lookup), so the config endpoint isn't pinned to a fixed address.
- Dynamic refresh — config changes in Git are broadcast (via Spring Cloud Bus) to all registered instances, which
@RefreshScope-reload affected beans.
The 2026 correction to fold in: "Spring Cloud Netflix" today effectively means Eureka only — Ribbon, Hystrix, and Zuul were removed in favor of Spring Cloud LoadBalancer, Resilience4j, and Spring Cloud Gateway. So the accurate framing is "Eureka (discovery) + Spring Cloud Config work together: services register with Eureka, fetch centralized config from the Config Server, and the two combine for discovery-first config and dynamic refresh." On Kubernetes, both roles are often handled by the platform (DNS-based discovery + ConfigMaps) instead.
Follow-up 1
Can you give an example of how these two components might interact in a microservices architecture?
In a microservices architecture, Spring Cloud Config can be used to store the configuration properties for each service. The services can then use Spring Cloud Netflix's integration with Spring Cloud Config to retrieve and apply the configuration properties at runtime. For example, a service might use the @Value annotation provided by Spring Cloud Config to inject a configuration property into a bean. The value of the property will be retrieved from Spring Cloud Config and applied to the bean.
Follow-up 2
What benefits does this integration provide?
The integration of Spring Cloud Netflix and Spring Cloud Config provides several benefits. Firstly, it allows for centralized configuration management, making it easier to manage and update the configuration properties for all services. Secondly, it enables dynamic configuration updates, as the services can retrieve and apply the latest configuration properties from Spring Cloud Config at runtime. This eliminates the need for service restarts when configuration changes. Lastly, it promotes consistency and reduces duplication, as the services can share common configuration properties through Spring Cloud Config.
Follow-up 3
What challenges might arise when integrating these two components?
There are a few challenges that might arise when integrating Spring Cloud Netflix and Spring Cloud Config. Firstly, ensuring the availability and reliability of the Spring Cloud Config server is crucial, as all services rely on it for retrieving their configuration properties. Secondly, managing the security and access control of the configuration properties stored in Spring Cloud Config is important to prevent unauthorized access. Lastly, handling the coordination and synchronization of configuration updates across multiple services can be complex, especially in a distributed environment.
4. What is the role of Zuul in Spring Cloud Netflix?
Zuul was Netflix's API gateway in Spring Cloud Netflix — the single entry point for all client requests, responsible for dynamic routing to backend microservices, plus cross-cutting edge concerns (authentication, rate limiting, monitoring, request/response filtering) implemented through its filter model.
The essential 2026 correction: Zuul is retired — it was Zuul 1, a blocking gateway, and Spring Cloud removed it. The modern replacement is Spring Cloud Gateway, which is:
- Reactive and non-blocking (built on Spring WebFlux/Project Reactor), so it scales better under load.
- Configured with routes (predicates + filters) declaratively in YAML or Java.
- Integrated with Resilience4j (circuit breaking), Spring Cloud LoadBalancer, rate limiting, and security at the edge.
spring.cloud.gateway.routes:
- id: orders
uri: lb://order-service # load-balanced
predicates: [ Path=/orders/** ]
filters: [ StripPrefix=1 ]
So the right answer is: "Zuul was the Netflix API gateway for routing and edge filtering, but it's been replaced by Spring Cloud Gateway — a reactive, non-blocking gateway that's the current standard." (A newer Spring Cloud Gateway MVC variant also exists for the servlet stack.) Mentioning that Zuul is legacy is exactly what interviewers look for here.
Follow-up 1
How does Zuul handle routing in a microservices architecture?
Zuul uses a combination of static and dynamic routing to handle routing in a microservices architecture. Static routing is configured using the application.properties or application.yml file, where you can define the routes and their corresponding microservices. Dynamic routing is achieved through the use of service discovery, where Zuul queries the service registry (e.g., Eureka) to obtain the available microservices and their locations. Zuul then uses this information to route the requests to the appropriate microservice.
Follow-up 2
What are some advantages of using Zuul as an API gateway?
Some advantages of using Zuul as an API gateway are:
- Routing: Zuul provides dynamic routing capabilities, allowing you to easily route requests to the appropriate microservice based on the request URL.
- Load Balancing: Zuul integrates with service discovery (e.g., Eureka) to perform load balancing across multiple instances of a microservice.
- Security: Zuul can act as a security filter, authenticating and authorizing requests before forwarding them to the microservices.
- Monitoring and Resiliency: Zuul provides monitoring and resiliency features, such as circuit breakers and rate limiting, to ensure the stability and availability of the system.
- Easy Integration: Zuul seamlessly integrates with other Spring Cloud components, making it easy to incorporate into your microservices architecture.
Follow-up 3
Can you explain how Zuul filters work?
Zuul filters are used to intercept and modify the requests and responses passing through the gateway. There are four types of filters in Zuul:
- Pre filters: Pre filters are executed before the request is routed to the microservice. They can be used for tasks such as authentication, request validation, and logging.
- Routing filters: Routing filters are responsible for routing the request to the appropriate microservice. They can modify the request URL, add headers, or perform load balancing.
- Post filters: Post filters are executed after the request has been routed and the response has been received from the microservice. They can be used for tasks such as response modification, logging, and error handling.
- Error filters: Error filters are executed when an error occurs during the routing or processing of the request. They can be used to handle and customize error responses.
Zuul filters can be easily implemented by extending the ZuulFilter class and overriding the necessary methods.
5. How does Spring Cloud Config handle security?
Because the Config Server holds sensitive data (DB passwords, API keys), it needs securing on several fronts:
- Transport security — serve over HTTPS/TLS so config isn't sent in clear text.
- Authentication/authorization on the server — protect the Config Server's endpoints with Spring Security (HTTP Basic, OAuth2/OIDC, or mutual TLS); clients present credentials to fetch config. Lock down Actuator endpoints too.
- Encryption at rest / of values — encrypt sensitive properties so they're not stored in plaintext in Git: Spring Cloud Config supports
{cipher}encrypted values (symmetric or RSA keys) decrypted by the server, and integration with HashiCorp Vault or cloud secret managers (AWS Secrets Manager, etc.) for real secret storage. - Backend access control — restrict who can read/write the Git repo backing the config.
# encrypted value in a config file
spring.datasource.password: '{cipher}AQB3...'
The points interviewers reward: combine TLS + authentication + encrypted/Vault-backed secrets, never commit plaintext secrets to Git, and audit changes via the Git history. A current note: many teams now keep secrets in Vault or Kubernetes Secrets rather than encrypted properties, using Config Server (or Spring Cloud Kubernetes) mainly for non-secret configuration — keeping secrets out of source control entirely.
Follow-up 1
What measures does Spring Cloud Config take to protect sensitive configuration data?
Spring Cloud Config takes several measures to protect sensitive configuration data. It supports encryption and decryption of configuration properties, allowing you to store sensitive information, such as passwords or API keys, in an encrypted format. It also provides integration with secure credential storage solutions, such as HashiCorp Vault or CredHub, to securely manage service credentials. Additionally, Spring Cloud Config allows you to define fine-grained access control policies to restrict access to sensitive configuration data.
Follow-up 2
How does Spring Cloud Config handle encryption and decryption?
Spring Cloud Config supports encryption and decryption of configuration properties using symmetric or asymmetric encryption algorithms. To enable encryption, you need to configure a key or a keystore that will be used to encrypt the sensitive properties. The encrypted properties are stored in the configuration files or external storage (e.g., Git repository) and are decrypted by the Config Server when requested by clients. This ensures that sensitive configuration data remains secure even if the configuration files are compromised.
Follow-up 3
Can you explain the role of Spring Cloud Config in managing service credentials?
Spring Cloud Config plays a crucial role in managing service credentials. It allows you to store service credentials, such as database usernames and passwords, in a secure and centralized location. By leveraging encryption and access control mechanisms provided by Spring Cloud Config, you can ensure that only authorized services can access the required credentials. This simplifies the management of service credentials and reduces the risk of exposing sensitive information.
Live mock interview
Mock interview: Spring Cloud Netflix & Config
- Read your scene and goals
- Talk it out; goals tick off live
- Get a score and stronger lines
Your voice and your AI key never touch our servers; the key stays in this browser and is sent only to Google. Only your round scores are saved to track progress.