Loading…
All sessions are in PDT (UTC -7)
Back To Schedule
Thursday, September 10 • 11:30am - 12:00pm
Contract as Code as Contract: Using Rust to Unify Specification and Implementation - Adam Leventhal & David Pacheco, Oxide Computer Company

Sign up or log in to save this to your schedule, view media, leave feedback and see who's attending!

Your API specification and implementation need to match. A mismatch is a recipe for heartbreak--broken clients, busted docs--and we see it all the time. Ideally we want a single source of truth for all aspects of an API, but too often we’re forced to specify attributes in multiple places which opens the door for “alternative mistruths”. For our rapidly evolving API, we developed a new library in Rust that incorporates OpenAPI, not just as decorations, but as load-bearing mechanisms that fully define the interface, both specification and implementation.

In this session, we’ll discuss methods of keeping specification and implementation in sync; why we developed Dropshot as an OpenAPI-first HTTP API library; and how we used some of the differentiated capabilities of the Rust language to combine code and contract. We will cover some of the properties of Rust that may be unfamiliar to the audience such as derive- and proc-macros and the powerful Rust type system.

Speakers
avatar for Adam Leventhal

Adam Leventhal

Engineer, Oxide Computer Company
Adam is the co-creator of DTrace, ZFS, Delphix, and Transposit. He was the 2019 API World Innovator of the Year. He's currently an engineer at Oxide, building hyperscale computing for sub-hyperscale companies.
avatar for David Pacheco

David Pacheco

Software Engineer, Oxide Computer Company
Software Engineer at Oxide Computer Company



Thursday September 10, 2020 11:30am - 12:00pm PDT
TBA
  Techniques
  • Presentations Available Yes