I sat Sam Merritt down to discuss how the Ring in OpenStack Swift works. The Ring is responsible for mapping data to physical locations in the cluster. Understanding how it works will make you a better operator for your Swift cluster.
One of the key pieces of Swift’s ability to scale is how it chooses where to place data in the cluster. Swift does this with a data structure called the “ring”. In this talk Sam discusses Swift’s ring data structure, its features, and how it works in a Swift cluster.
In this talk we cover:
- The concept of consistent hashing rings
- The Swift ring: consistent hashing, enhanced
- Choosing a part_power (partition power)
- Understanding the ring internals so we know physically where data is located
- Ring building
- How the ring handles capacity additions
- Unique-as-possible data placement
Sam is a Senior Software Engineer at SwiftStack and he is a member of the Core OpenStack Swift Team. He really knows his stuff about the internals of the Ring. He implemented the ‘as-unique-as-possible’ feature which enables much more flexibility in cluster layout. He is currently working on global replication in Swift.