https://github.com/andydunstall/fuddle
Fuddle is a service registry that can be used for client side service discovery and cluster observability.
https://github.com/andydunstall/fuddle
distributed-systems service-discovery service-registry
Last synced: 6 months ago
JSON representation
Fuddle is a service registry that can be used for client side service discovery and cluster observability.
- Host: GitHub
- URL: https://github.com/andydunstall/fuddle
- Owner: andydunstall
- License: mit
- Created: 2023-02-26T10:35:56.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-04T13:11:40.000Z (over 1 year ago)
- Last Synced: 2025-02-08T22:12:07.950Z (8 months ago)
- Topics: distributed-systems, service-discovery, service-registry
- Language: Go
- Homepage:
- Size: 7.1 MB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Fuddle
Fuddle was a side-project to try and create a simple service discovery mechanism, similar to
[Eureka](https://github.com/Netflix/eureka). I worked on this a while ago to play
around with ideas for replacing another gossip based service, though after moving jobs
I've stopped working on it...# What Is Fuddle?
Fuddle is a service registry, used for client side service discovery and cluster
observability.Application nodes register themselves into the registry, then use the registry
to discover other nodes in the cluster, and information needed to interact with
those nodes.Each member in the registry contains a set of attributes, including service,
locality and revision, plus metadata containing application-defined key-value
pairs. Clients can use the attributes and metadata to lookup members and
subscribe to changes.# Design Goals
## Simplicity
Fuddle is built to be very simple to integrate into existing infrastructure.Unlike many other service discovery systems, which require proxying requests and
running sidecars for every instance as part of a service mesh, Fuddle is a
standalone service that clients query via an SDK.## Flexibility
Fuddle supports client side service discovery instead of server side.Server side discovery requires proxying requests via some load balancer, which
routes requests among a set of nodes registered for that service. This limits
how much control developers have over how they route requests and what
transports they can use.Instead when using Fuddle, developers can query the registry using a Fuddle SDK
to lookup the target node(s).This gives you more flexibility in how you route requests, such as:
* Consistent hashing: Using Fuddle to lookup a set of nodes that build a hash
ring, and subscribe to changes in the set of nodes to trigger a rebalance
* Custom load balancing: Instead of a simple round robin strategy, you can add
custom policies like weighted load balancing based on the target nodes metadata
* Transports: Since Fuddle is used just to look up the target nodes instead of
proxying requests, there's no constraints on what transports or protocols can be
usedEach node can also register custom metadata, so there's no limit to what
information can be shared with other nodes.## Availability and Fault Tolerance
The registry is replicated over multiple Fuddle nodes, so if a node goes down,
clients automatically reconnect to another node without any disruption.The registry is eventually consistent and favours availability over consistency.
It will also detect when members registered by users' applications go down and
removes them from the registry.# Usage
Fuddle can be installed using `go install github.com/fuddle-io/fuddle`. This
includes a CLI to start a server node and interact with the cluster.A Fuddle SDK can be used to register members and subscribe to the registry. So
far only a Go SDK ([fuddle-go](https://github.com/fuddle-io/fuddle-go)) is supported.## Demo
The quickest way to get started with Fuddle is to run a demo cluster locally
using `fuddle demo`.Such as `fuddle demo clock` will run a clock service cluster as described
[here](demos/clock/README.md).## Start A Node
Start a Fuddle node with `fuddle start`. The node can be configured to join a
cluster using `--join`.See `fuddle start –help` for details.
## Inspect A Cluster
`fuddle info` can be used to inspect all nodes in a cluster (including both
Fuddle nodes and members registered by the application).`fuddle info cluster` lists all members of the cluster and their attributes.
`fuddle info member ` describes the member with the given ID, including
attributes and metadata.# Documentation
## Usage
* Monitoring
* [Metrics](./docs/usage/monitoring/metrics.md)
* [FCM](./docs/usage/fcm.md)## Architecture
* [Overview](./docs/architecture/overview.md)
* [Registry](./docs/architecture/registry/registry.md)
* [Members](./docs/architecture/registry/members.md)
* [Client](./docs/architecture/registry/client.md)
* [Failure Detector](./docs/architecture/registry/failure_detector.md)
* [Replication](./docs/architecture/registry/replication.md)
* [Fault Tolerance](./docs/architecture/registry/fault_tolerance.md)
* [Metrics](./docs/architecture/registry/metrics.md)# :warning: Limitations
Fuddle is still early in development so is missing features needed to run in
production.