applications developing cloud-native · 2019. 10. 11. · developing cloud-native applications...
TRANSCRIPT
with Microservices Architectures
Developing Cloud-Native Applications
Brian ‘redbeard’ HarringtonPrincipal Product Manager@brianredbeard
1
CONFIDENTIAL Designator
2
Brian “Redbeard”Harrington
Product Manager, Service MeshRed Hat@brianredbeardfreenode/#coreos/[email protected]
4
Serverless
Building blocks that extends the platform to enable auto-scaling and
event-driven applications
Pipelines
Native CI/CD for the platform.
Service Mesh
Managed connectivity to provide the glue between components, applications, and services.
5
Serverless
Building blocks that extends the platform to enable auto-scaling and
event-driven applications
Pipelines
Native CI/CD for the platform.
Service Mesh
Managed connectivity to provide the glue between components, applications, and services.
Service Mesh
6
Microservices* Evolution
SERVICE MESH
7
Service
Config
Svc Discovery
Routing
Circuit Breaker
Tracing
Platform
...2014
Microservices* Evolution
SERVICE MESH
8
Service
Config
Svc Discovery
Routing
Circuit Breaker
Tracing
Service
Platform Container Platform (+ Service Mesh)
...2014 2018
Microservices* Evolution
SERVICE MESH
9
Service
Config
Svc Discovery
Routing
Circuit Breaker
Tracing
Service
Platform Container Platform (+ Service Mesh)
...2014 20202018
Service
Container Platform (+ Service Mesh)
Service Service
Microservices Miniservices Evolution
SERVICE MESH
10
Service
Config
Svc Discovery
Routing
Circuit Breaker
Tracing
Service
Platform Container Platform (+ Service Mesh)
...2014 20202018
Service
Container Platform (+ Service Mesh)
Service Service
OpenShift Service Mesh
SERVICE MESH
11
Observe Observe
Secure
ControlConnect
Jaeger
Kiali Grafana
Prometheus
Istio
12
POD
SERVICEA
Istio Proxy
POD
SERVICEB:v2
Istio Proxy
POD
SERVICEB:v1
Istio Proxy
/api/v2
/api/v1
OpenShift Service Mesh
"A dedicated network for service-to-service communications"
13
Customer Benefits● Reduced need for developers to have operational knowledge● Service observability and discovery with distributed tracing● Enable transparent policy-driven security● From routing rules to chaos engineering● Powerful visualization & monitoring
Learn more● red.ht/osm-install● learn.openshift.com
GA 4.1
Serverless
14
15
16
ServerlessIt’s a trait.It’s a continuum, a spectrum.*Allow you to focus on business value.Write less code. You give away control to gain velocity.
Nadaam Archery by David Baxendale (CC)
May 2019, Barcelona
18
"Function as a Service (FaaS)
is serverless in the same way
a square is a rectangle”
Serverless > Functions
May 2019, Barcelona
19
Serverless > Microservices
"Microservices can promote
separation of concerns and
offer an interesting way to
build distributed systems,
serverless or not."
May 2019, Barcelona
20
Serverless > Containers
"Containers offer an efficient
and open format to package,
distribute and isolate
workloads."
Microservices, Functions and Apps
21
MicroservicesFunctions Apps
Containers
Infrastructure & Scheduling
Application frameworks
Infrastructure
Containers
Infrastructure & Scheduling
Microservices, Functions and Apps
22
MicroservicesFunctions Apps
Containers
Infrastructure & Scheduling
Application frameworks
Infrastructure
Containers
Infrastructure & Scheduling
Knative Components
...an extension to Kubernetes exposing building blocks to build modern, source-centric, and container-based applications that can run anywhere"
23
Serving
An event-driven model that serves the container with your application and can "scale to
zero".
Eventing
Common infrastructure for consuming and producing events that will stimulate applications.
Build
A pluggable model for building
artifacts, like jar files, zips or
containers from source code.
24
Serving
An event-driven model that serves the container with your application and can "scale to
zero".
Eventing
Common infrastructure for consuming and producing events that will stimulate applications.
Pipelines
Provides Kubernetes native modern resources for declaring
CI/CD pipelines.
OpenShift serverless
Serverless building blocks for any container workload
25
Customer Benefits● Familiar to Kubernetes users. Native.● Scale to 0 and autoscale to N based on demand● Applications and functions. Any container workload.● Powerful eventing model with multiple event sources.● No vendor lock in
Learn more● openshift.com/learn/topics/knative● http://bit.ly/knative-tutorial
Tech Preview 4.2
Azure Functions & KEDA
Functions as a Service
26
Customer Benefits● Enable FaaS in OpenShift● Familiar developer experience using VS Code and Azure CLI● Azure Queues, Azure Service Bus...● Reuse Knative event sources, HTTP auto-scaling
Learn more● https://github.com/kedacore/keda
In partnership with:
Developer Preview
27
Serverless
Building blocks that extends the platform to enable auto-scaling and
event-driven applications
Pipelines
Native CI/CD for the platform.
Service Mesh
Managed connectivity to provide the glue between components, applications, and services.
28
29
30
31
database
shell server
k8s west
k8s east
jenkins
32
33
34
import jsonfrom pynamodb.attributes import UnicodeAttribute, BooleanAttribute, UTCDateTimeAttributefrom pynamodb.models import Model
class EventModel(Model): class Meta: table_name = os.environ['DYNAMODB_TABLE'] region = 'us-west-1' host = 'https://dynamodb.eu-central-1.amazonaws.com'
event_id = UnicodeAttribute(hash_key=True, null=False) ip = UnicodeAttribute(null=False) createdAt = UTCDateTimeAttribute(null=False, default=datetime.now())
def save(self, conditional_operator=None, **expected_values): self.updatedAt = datetime.now() super(EventModel, self).save()
def create(event, context): data = json.loads(event['body'])
event = EventModel(event_id=str(uuid.uuid1()), ip=data['ip'])
event.save()
# create a response return {'statusCode': 201, 'body': json.dumps(dict(event))}
35
import jsonfrom pynamodb.attributes import UnicodeAttribute, BooleanAttribute, UTCDateTimeAttributefrom pynamodb.models import Model
class EventModel(Model): class Meta: table_name = os.environ['DYNAMODB_TABLE'] region = 'us-west-1' host = 'https://dynamodb.eu-central-1.amazonaws.com'
event_id = UnicodeAttribute(hash_key=True, null=False) ip = UnicodeAttribute(null=False) createdAt = UTCDateTimeAttribute(null=False, default=datetime.now())
def save(self, conditional_operator=None, **expected_values): self.updatedAt = datetime.now() super(EventModel, self).save()
def create(event, context): data = json.loads(event['body'])
event = EventModel(event_id=str(uuid.uuid1()), ip=data['ip'])
event.save()
# create a response return {'statusCode': 201, 'body': json.dumps(dict(event))}
36
import jsonfrom pynamodb.attributes import UnicodeAttribute, BooleanAttribute, UTCDateTimeAttributefrom pynamodb.models import Model
class EventModel(Model): class Meta: table_name = os.environ['DYNAMODB_TABLE'] region = 'us-west-1' host = 'https://dynamodb.eu-central-1.amazonaws.com'
event_id = UnicodeAttribute(hash_key=True, null=False) ip = UnicodeAttribute(null=False) createdAt = UTCDateTimeAttribute(null=False, default=datetime.now())
def save(self, conditional_operator=None, **expected_values): self.updatedAt = datetime.now() super(EventModel, self).save()
def create(event, context): data = json.loads(event['body'])
event = EventModel(event_id=str(uuid.uuid1()), ip=data['ip'])
event.save()
# create a response return {'statusCode': 201, 'body': json.dumps(dict(event))}
37
import jsonfrom pynamodb.attributes import UnicodeAttribute, BooleanAttribute, UTCDateTimeAttributefrom pynamodb.models import Model
class EventModel(Model): class Meta: table_name = os.environ['DYNAMODB_TABLE'] region = 'us-west-1' host = 'https://dynamodb.eu-central-1.amazonaws.com'
event_id = UnicodeAttribute(hash_key=True, null=False) ip = UnicodeAttribute(null=False) createdAt = UTCDateTimeAttribute(null=False, default=datetime.now())
def save(self, conditional_operator=None, **expected_values): self.updatedAt = datetime.now() super(EventModel, self).save()
def create(event, context): data = json.loads(event['body'])
event = EventModel(event_id=str(uuid.uuid1()), ip=data['ip'])
event.save()
# create a response return {'statusCode': 201, 'body': json.dumps(dict(event))}
38
39
40
41
42
43
44
45
46
47
48
Build and Deploy Cloud Native Apps
SERVICE MESH
49
Service
CONTAINER
Service
CONTAINER
Service
CONTAINER
ANYINFRASTRUCTURE
OpenShift Container Platform(Enterprise Kubernetes)
Amazon Web Services Microsoft Azure Google CloudOpenStackDatacenterLaptop
ANYAPPLICATION
Service
CONTAINER
Service
CONTAINER
Service Discovery
Config Mgmt
Build Automation
Deploy Automation
Monitoring
Log Mgmt
Security
CI/CD Pipelines
try it at http://learn.openshift.com
linkedin.com/company/red-hat
youtube.com/user/RedHatVideos
facebook.com/redhatinc
twitter.com/RedHat
50
● red.ht/osm-install● learn.openshift.com● openshift.com/learn/topics/knative● bit.ly/knative-tutorial ● github.com/kedacore/keda
Thank you
OPTIO
NAL SECTION
MARKER O
R TITLE
@brianredbeard