350 likes | 558 Views
Scalable Systems Using Micro- RESTful Services. silicon valley code camp October 6 th , 2013. by Ted M. Young. http://about.me/tedmyoung Twitter: @ jitterted. What to expect this session. The Problem An Architectural Solution Our Proof of Concept. The Problems. Monolithic.
E N D
Scalable Systems Using Micro-RESTful Services silicon valley code camp October 6th, 2013 by Ted M. Young http://about.me/tedmyoung Twitter: @jitterted
What to expect this session • The Problem • An Architectural Solution • Our Proof of Concept
Layered Architecture Biz Logic Biz Logic Biz Logic
TheArchitecture CubeandMicro-Services Services per feature integrated using rest
ArchitecturalPrinciples From "The Art of Scalability" (Figure 12.3)
From "The Art of Scalability" (Figure 23.1) Scalability Cube
The Unix Philosophy Write programs that do one thingand do it well. Write programs to work together. Write programs that handle text streams, because that is a universal interface. • - Lions' Commentary on Unix
Hypermedia (REST) • Resource-oriented • Flexible in face of change • User-facing clients leverage links • Async and Stateless services
Proof of Concept Our summer experiment
Tech Stack • Dropwizard services • AngularJS UI Client • Jenkins + Maven (Nexus) deployment • Custom Dashboard
Dropwizard • Jettyfor HTTP • Jersey for REST (and HttpClient) • Jackson for JSON • Metrics (includes Healthcheck) for monitoring • Logback/slf4j for logging • Other useful libraries • Guava, JDBI, Liquibase, Freemarker, JodaDate/Time
REST: Media Types • More structure than POAJ • Plain Old application/json • Leverage libraries
Media Types for APIs • In/Out: application/collection+json • In: application/x-www-form-urlencoded
Continuous Deployment • Current: • Jenkins • Nexus repository (Maven package) • Shell script • Tried: • Upstart script & Puppet • Ansible • Bamboo 5
Still In Progress • API Facades • Better Deployment/Management
Notes (stuff I didn’t get to talk about) • Using a RESTful (or Hypermedia) architecture, we've created "micro" services that talk to each other in order to provide scalability, along with ease of development, deployment, and management. • Deployment and Management • Purpose: scaling, updating • Tools: Ansible, Mesos with Marathon, • Event information/Logging • Monitoring • Custom dashboards • REST or Hypermedia • Example of a client that can change functionality over time