System design: service registry
Requirements
- Data consistency
- How long it takes to discover offline service?
- How many service instances can it support?
- How many machines you need to run this registry?
Eureka
- P2P, all provides to outside services, when it is registred on node, it will be gossiped to other nodes
- ReadOnly default sync time is 30 sec. Service refreshes on 30 sec interval
- Default: Every 60 sec to detect offline service. Heartbeat expires at 90 sec