building microservices with .net core and steeltoeschd.ws/hosted_files/ossna2017/81/building...
TRANSCRIPT
![Page 1: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/1.jpg)
Building Microservices with
.NET Core and SteeltoeZach Brown and Matt Horan, Pivotal
![Page 2: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/2.jpg)
outline
• Introduction Welcome to the .NET Renaissance
• What is Steeltoe?(and why is Steeltoe? and what’s in Steeltoe?)
• Cloud Foundry• Demo• Roadmap & Resources
![Page 3: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/3.jpg)
Be engaged!Join the dialogueShare your thoughts, opinions and photos ...even if you disagree
Zach Brown@moredeploys
Steeltoe Project@SteeltoeOSS
![Page 4: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/4.jpg)
Introduction:
Welcome to the .NET Renaissance
![Page 5: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/5.jpg)
![Page 6: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/6.jpg)
![Page 7: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/7.jpg)
the .NET Renaissance
We are on the cusp of a
.NET renaissance.
- Ian CooperNDC Oslo
![Page 8: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/8.jpg)
the .NET Renaissancea convergence of forces
• It’s about time… (.NET’s 15th Birthday)
• Cross-platform .NET Core
• Rise of Cloud
• Growing OSS community
• But we need more projects that
support for 12-factor, cloud-native, and microservices
![Page 9: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/9.jpg)
what is Steeltoe?
![Page 10: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/10.jpg)
why is Steeltoe?
![Page 11: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/11.jpg)
cloud-native .NET
• 12 Factor App principles (https://12factor.net/) • Configuration stored in environment variables• Out of process session state• No r/w to registry, GAC, Local file system• Loosely coupled backing services (i.e. RDBMS)
“Today’s best practices are tomorrow’s anti-patterns.”
![Page 12: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/12.jpg)
Microservices
Microservice architectures have many benefits
- Quickly iterate and release frequently- Easy for new devs to join and be productive- Increased developer velocity- Shorter test cycles- Polyglot becomes reality- Independently scalable components
![Page 13: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/13.jpg)
but Microservices are hard
Microservices = Distributed Systems = Way more complexity
- How to troubleshoot microservices?- How to set global configuration across
the whole application?- How to look up the dynamic addresses
of services you consume?- What do you do when a service you
depend on stops responding?
![Page 14: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/14.jpg)
the Good news is...
and
There are some great OSS solutions already available
But until now they’ve been focused on Java and not very accessible to .NET devs…
![Page 15: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/15.jpg)
so that’s why we built Steeltoe
To help you build
Cloud native .NET applications
and leverage Spring Cloud tooling for
resilient microservices
![Page 16: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/16.jpg)
what’s in Steeltoe?
![Page 17: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/17.jpg)
cloud-native .NET
- MySQL
- Postgres
- Redis
- RabbitMQ
- OAuth2
Connectors for common data services
![Page 18: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/18.jpg)
cloud-native .NET
Security Providers
- OAuth2 SSO Provider
- JWT resource protection
- Redis-backed Key Ring
Repository
![Page 19: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/19.jpg)
cloud-native .NET
Management Endpoints - /info
arbitrary app info, e.g. git build tag
- /health application health information
- /trace circular buffer of last 100 http requests/responses
- /loggers shows and modifies configuration of loggers down to the class level
![Page 20: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/20.jpg)
cloud-native .NET
Cloud Foundry- VCAP_APPLICATION, VCAP_SERVICES, CF_*
Config Server- Access config stored in Spring Cloud Config Server
(backed by Git, Vault, local filesystem)
- Across all instances, all apps, all environments
Configuration Providers
![Page 21: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/21.jpg)
cloud-native .NET
Spring Cloud Config Server
![Page 22: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/22.jpg)
resilient Microservices
Service Discovery with Eureka
- .NET Client for Netflix Eureka
- Dynamically discover and call
registered services
- Supports direct addressing
![Page 23: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/23.jpg)
resilient Microservices
Circuit Breaker
- .NET implementation of Netflix Hystrix
- Bypass failing services with
elegant fall-back behavior
(so your users don’t see nasty error messages)
- Rich metrics and monitoring
![Page 24: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/24.jpg)
resilient Microservices
Netflix Hystrix
![Page 25: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/25.jpg)
open and Flexible
Steeltoe works...
with .NET Core and with the .NET framework
on Windows and on Linux
standalone and running on Cloud Foundry
![Page 26: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/26.jpg)
wait... what’s this Cloud Foundry thing again?
![Page 27: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/27.jpg)
about Cloud FoundryDYNAMIC ROUTE SERVICES / API MANAGEMENT
APP MICROSERVICES TECHNOLOGY
Spring Boot Steeltoe Spring Cloud Services
DATA MICROSERVICES TECHNOLOGY
Spring Cloud Data
Flow
Cloud Cache RabbitMQ MySQL
YOUR APPLICATIONS
PLATFORM
Elastic Runtime Concourse AppAutoscaler PCF Metrics CredHub
Orgs, Spaces, Roles and
Permissions
EMBEDDED OS
CLOUD ORCHESTRATION
CONTAINER ORCHESTRATIONWindows Linux
AmazonWeb Services
MicrosoftAzure
GoogleCloud
PlatformOpen Stack VMWare
SERVICEBROKER API
PIVOTALCLOUD FOUNDRY
APPLICATIONRUNTIME
PIVOTALCLOUD FOUNDRY
BOSH
MODERNCLOUD NATIVE
PLATFORM
MULTI CLOUD
![Page 28: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/28.jpg)
Demo
![Page 29: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/29.jpg)
.NET Music Store w/Steeltoe
MusicUI
OrderProcessing
MusicStore
ShoppingCart
mySQL
redis mySQL
Browse music
Add itemto cart
Place Order
mySQL
session cache
![Page 30: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/30.jpg)
Roadmap and Resources
![Page 31: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/31.jpg)
roadmap
What’s coming on the Steeltoe Roadmap?- Additional Management endpoints
- Thread dump, Heap dump
- Netflix Ribbon- Load balancing for Eureka client
- Distributed Tracing (Zipkin4Net)
What else would you like to see?
![Page 32: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/32.jpg)
how to get started
Learn more → http://steeltoe.io
Clone a sample → https://github.com/SteeltoeOSS/Samples
Get the bits → https://www.nuget.org/profiles/steeltoe
Talk to us → http://slack.steeltoe.io/
Tell your friends → @SteeltoeOSS
The best way to get started is to take a look at our docs, clone a sample from the GitHub repo, and contact the team in Slack with questions and feedback.
![Page 33: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/33.jpg)
other ResourcesUpcoming Training
2-day Hands-on training course at Spring One Platform conferencehttps://springoneplatform.io/training/steeltoe-net-developer
Blogs on Steeltoe
Polyglot microservices and Eurekahttps://seroter.wordpress.com/2017/03/27/yes-you-can-use-a-single-service-registry-for-net-and-java-microservices/
Microservices, .NET, Cloud Foundry and Microsoft’s Face APIhttps://www.altoros.com/blog/microservices-with-steeltoe-and-cloud-foundry-a-dotnet-app-using-microsoft-face-api/
.NET Core Microservices and Steeltoehttps://www.altoros.com/blog/enabling-dotnet-core-microservices-with-steeltoe-and-pivotal-cloud-foundry/
![Page 34: Building Microservices with .NET Core and Steeltoeschd.ws/hosted_files/ossna2017/81/Building Microservices...the .NET Renaissance a convergence of forces • It’s about time… (.NET’s](https://reader031.vdocument.in/reader031/viewer/2022021514/5b0bc1337f8b9a6a6b8b48f9/html5/thumbnails/34.jpg)