|
|
|
|
|
by mitchellh
5349 days ago
|
|
I'm not very familiar with building services on the JVM at the moment (though I'd love to be), so a quick, honest question: What are the pros/cons of Ordasity[1] vs. something like Finagle[2]? Are they comparable and if so why would one be chosen over the other, what are the strengths of one vs the other, etc. [1]: https://github.com/boundary/ordasity [2]: https://github.com/twitter/finagle |
|
Thanks for asking -- in short, the use cases are a bit different. Finagle is a framework for building asynchronous RPC systems (e.g., services or APIs with transports over HTTP or Thrift), and Ordasity is a library for cluster membership, load balancing, and distribution.
Twitter's put together a nice toolkit atop Netty for building reliable services and describing communication between them. These services are generally stateless and might be balanced by something like HAProxy (when using an HTTP transport), or via a round-robin approach in the case of Thrift clients. A closer comparator for Finagle would be something like Scalang, our library for building hybrid Erlang / Scala distributed systems (though it's also excellent for pure-Scala systems as well): https://github.com/boundary/scalang
Ordasity is designed for describing stateful clusters in which individual nodes are responsible for claiming longer-lived work units -- think of it in terms of "a processing shard" of the system's total load. The library's primary goals are to help you:
- Describe the cluster in simple terms such that when each node comes online, it joins the cluster and is aware of all other nodes (and vice versa)
- Distribute work across the cluster by directing each node to claim an even "count" of work units or "even distribution" of the total load imposed by those work units.
- Automatically rebalance work units across nodes in the cluster as the amount / intensity of work or cluster topology changes.
- And gracefully manage maintenance or downtime scenarios by draining work units to another node.
In the end, Ordasity and Finagle are both tools for building distributed systems on the JVM. However, the types of systems they're designed to describe are a bit different. Hope that helps; let me know if you'd like me to clarify something.