SlideShare ist ein Scribd-Unternehmen logo
1 von 21
Downloaden Sie, um offline zu lesen
Developer Experience Cloud Native
-
Become Efficient and Achieve Parity
Michael Hofmann
https://hofmann-itconsulting.de
Developer Experience Cloud Native
create code
Docker build
& push
deploy to
(local) K8S
test & debug
remote
Git push
build & test
(local)
The Twelve-Factor App
“methodology for building software-as-a-service apps that”:
● “Use declarative formats for setup automation, to minimize time and cost for new
developers joining the project”;
● “Have a clean contract with the underlying operating system, offering maximum
portability between execution environments”;
● “Are suitable for deployment on modern cloud platforms, obviating the need for
servers and systems administration”;
● “Minimize divergence between development and production, enabling
continuous deployment for maximum agility”;
● “And can scale up without significant changes to tooling, architecture, or
development practices”.
https://12factor.net
The Twelve-Factor App
I. Codebase
One codebase tracked in revision control, many
deploys
II. Dependencies
Explicitly declare and isolate dependencies
III. Config
Store config in the environment
IV. Backing services
Treat backing services as attached resources
V. Build, release, run
Strictly separate build and run stages
VI. Processes
Execute the app as one or more stateless processes
VII. Port binding
Export services via port binding
VIII. Concurrency
Scale out via the process model
IX. Disposability
Maximize robustness with fast startup and graceful
shutdown
X. Dev/prod parity
Keep development, staging, and production as similar as
possible
XI. Logs
Treat logs as event streams
XII. Admin processes
Run admin/management tasks as one-off processes
Deviation in Parity: local vs cloud
● operation system
● JDK version
● environment
– ENV vars
– volume mounts
– DNS (myservice.mynamespace.svc.cluster.local)
● backing service (single server / cluster)
(e.g. Redis: SingleServerConfig, ClusterServersConfig)
● Java SecureRandom: in cloud too slow (missing entropy with isolated
CPUs)
The Quest:
How to get
new source code
quick
into container or pod
to keep
parity?
Possible Solutions
● synchronous deployment in Kubernetes
● source reload in Kubernetes pod
● swap deployment of Kubernetes pod
● for completeness: source reload in local container
– no focus in this session
– to many manual tasks necessary (see summary)
Sync Deployment: Skaffold
● handles the workflow for
– building (application and image)
– pushing to registry
– deployment to Kubernetes
● keeps artifacts in sync
● workflow automated or manually
https://skaffold.dev
Sync Deployment
Demo Skaffold
Skaffold Summary
● always full build and deployment cycle
– deactivate JUnits for shorter roundtrip
● remote debug only with manual intervention (pod restart)
● automatic sync of deployment files and Docker images
● cleanup of all (skaffold-ed) resources in cluster
● main usage scenario: keep local and remote in sync
● remote debug is not a first class citizen
● OpenLiberty can reload code on every change
● setting in server.xml
<applicationManager autoExpand=”true”>
● on file basis (app.war) or on individual class files
● concept: sync local class files to remote pod for
reload in running app server
● remote debug with JDWP (java debug wire protocol)
Source Reload: OpenLiberty/Ksync
Ksync
● installs DaemonSet in K8s cluster
● works bi-directional
● local watch process keeps local folder and pod
folder in sync
● new pods will also be synced (scale --replicas=2)
https://github.com/ksync/ksync
OpenLiberty/Ksync Summary
● full parity: code evolution inside running pod
● roundtrip takes only 1-2s
● JDWP is well-engineered
● stable debug connection (no pod restart)
● concept can also be applied to other app servers (e.g.
tomcat)
● remove JDWP agent and debug port in production
Source Reload: Quarkus Live Coding
● start app (in pod) in remote dev mode:
– package app in mutable jar format
– env setting: QUARKUS_LAUNCH_DEVMODE=true
– same as mvn compile quarkus:dev for local dev mode
● intercepts HTTP requests: redeploys app if new code exists
– redeploy takes less than 1 second (even for larger applications)
● connect local agent to remote host:
mvn quarkus:remote-dev -Dquarkus.live-reload.url=
http://my-remote-host:8080
● sync can be delegated to e.g. Ksync (without url in previous command)
Source Reload
Demo Quarkus Live Coding
Quarkus Live Coding Summary
● full parity: code evolution inside running pod
● no need for additional tools
● very quick roundtrip (< 1s)
● stable debug connection (JDWP)
● do not use dev-mode in production
– app must be repackaged for production
– env setting and debug port must be deleted
Service-C (Pod)
Service-B (Pod)
swapped
Service-A (Pod)
Service-B (Pod)
Swap Deployment
local
Kubernetes
Env
Volume
Env
Volume
Swap Deployment
● debugging a service mesh
● substitutes K8S pod with a two-way network proxy
● proxies data from K8S environment (e.g., TCP connections,
environment variables, volumes) to local process
● local process has its networking transparently overridden:
DNS calls and TCP connections are routed to K8S
● Bridge to Kubernetes or Telepresence
https://marketplace.visualstudio.com/items?itemName=mindaro.mindaro
https://www.telepresence.io
Swap Deployment
Demo Bridge to Kubernetes
Swap Deployment Summary
● parity broken only on OS or JDK (env, mount, DNS parity)
● local development with local debugging
● no manipulation of image or settings necessary
● Non root account: can be set but a little complicated (Docker or env-settings)
● individual traffic
– Telepresence additional service (commercial)
– Bridge to Kubernetes out-of-the-box
● main usage scenarios: develop and debug service mesh local with nearly
full parity
Tool OS/JDK ENV DNS Mount Debug Efficient
Source Reload
(Local Container)
mvn
liberty:devc
manually
--env
kubefwd
manually
--mount
Remote
Sync Deployment Skaffold Remote
Source Reload
(Kubernetes Pod)
OpenLiberty/
Ksync
Quarkus Live
Coding
Remote
Swap Deployment
Bridge to
Kubernetes
telepresence
Local
Summary

Weitere ähnliche Inhalte

Was ist angesagt?

Jenkins Workflow Webinar - Dec 10, 2014
Jenkins Workflow Webinar - Dec 10, 2014Jenkins Workflow Webinar - Dec 10, 2014
Jenkins Workflow Webinar - Dec 10, 2014
CloudBees
 
Developer Productivity Engineering with Gradle
Developer Productivity Engineering with GradleDeveloper Productivity Engineering with Gradle
Developer Productivity Engineering with Gradle
All Things Open
 
Fine-Tuning of Agile Development
Fine-Tuning of Agile DevelopmentFine-Tuning of Agile Development
Fine-Tuning of Agile Development
Thoughtworks
 

Was ist angesagt? (20)

High Performance Cloud-Native Microservices IndyCloudConf 2020
High Performance Cloud-Native Microservices IndyCloudConf 2020High Performance Cloud-Native Microservices IndyCloudConf 2020
High Performance Cloud-Native Microservices IndyCloudConf 2020
 
Docker Best Practices Workshop
Docker Best Practices WorkshopDocker Best Practices Workshop
Docker Best Practices Workshop
 
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
An Integrated Pipeline for Private and Public Clouds with Jenkins, Artifactor...
 
DCEU 18: Continuous Delivery with Docker Containers and Java: The Good, the B...
DCEU 18: Continuous Delivery with Docker Containers and Java: The Good, the B...DCEU 18: Continuous Delivery with Docker Containers and Java: The Good, the B...
DCEU 18: Continuous Delivery with Docker Containers and Java: The Good, the B...
 
DevOps World | Jenkins World 2018 and The Future of Jenkins
DevOps World | Jenkins World 2018 and The Future of JenkinsDevOps World | Jenkins World 2018 and The Future of Jenkins
DevOps World | Jenkins World 2018 and The Future of Jenkins
 
Mihai Criveti - PyCon Ireland - Automate Everything
Mihai Criveti - PyCon Ireland - Automate EverythingMihai Criveti - PyCon Ireland - Automate Everything
Mihai Criveti - PyCon Ireland - Automate Everything
 
Jenkins Workflow Webinar - Dec 10, 2014
Jenkins Workflow Webinar - Dec 10, 2014Jenkins Workflow Webinar - Dec 10, 2014
Jenkins Workflow Webinar - Dec 10, 2014
 
Improving WordPress Development and Deployments with Docker
Improving WordPress Development and Deployments with DockerImproving WordPress Development and Deployments with Docker
Improving WordPress Development and Deployments with Docker
 
Developer Productivity Engineering with Gradle
Developer Productivity Engineering with GradleDeveloper Productivity Engineering with Gradle
Developer Productivity Engineering with Gradle
 
[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise Applications[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise Applications
 
Fine-Tuning of Agile Development
Fine-Tuning of Agile DevelopmentFine-Tuning of Agile Development
Fine-Tuning of Agile Development
 
CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)
CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)
CI and CD Across the Enterprise with Jenkins (devops.com Nov 2014)
 
Distributed Docker Pipeline Architecture with CloudBees Jenkins Enterprise
Distributed Docker Pipeline Architecture with CloudBees Jenkins EnterpriseDistributed Docker Pipeline Architecture with CloudBees Jenkins Enterprise
Distributed Docker Pipeline Architecture with CloudBees Jenkins Enterprise
 
Adopting Java for the Serverless world at AWS User Group Pretoria
Adopting Java for the Serverless world at AWS User Group PretoriaAdopting Java for the Serverless world at AWS User Group Pretoria
Adopting Java for the Serverless world at AWS User Group Pretoria
 
SkyBase - a Devops Platform for Hybrid Cloud
SkyBase - a Devops Platform for Hybrid CloudSkyBase - a Devops Platform for Hybrid Cloud
SkyBase - a Devops Platform for Hybrid Cloud
 
Continuous Testing
Continuous TestingContinuous Testing
Continuous Testing
 
Git and GitHub for Documentation
Git and GitHub for DocumentationGit and GitHub for Documentation
Git and GitHub for Documentation
 
Unleashing Docker with Pipelines in Bitbucket Cloud
Unleashing Docker with Pipelines in Bitbucket CloudUnleashing Docker with Pipelines in Bitbucket Cloud
Unleashing Docker with Pipelines in Bitbucket Cloud
 
Jenkins vs. AWS CodePipeline
Jenkins vs. AWS CodePipelineJenkins vs. AWS CodePipeline
Jenkins vs. AWS CodePipeline
 
Jenkins + Docker = Continuous Improvement
Jenkins + Docker = Continuous ImprovementJenkins + Docker = Continuous Improvement
Jenkins + Docker = Continuous Improvement
 

Ähnlich wie Developer Experience Cloud Native - Become Efficient and Achieve Parity

Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
Michael Hofmann
 

Ähnlich wie Developer Experience Cloud Native - Become Efficient and Achieve Parity (20)

Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015
 
Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
Developer Experience Cloud Native - From Code Gen to Git Commit without a CI/...
 
Containers and Orchestration approaches
Containers and Orchestration approachesContainers and Orchestration approaches
Containers and Orchestration approaches
 
Making Service Deployments to AWS a breeze with Nova
Making Service Deployments to AWS a breeze with NovaMaking Service Deployments to AWS a breeze with Nova
Making Service Deployments to AWS a breeze with Nova
 
stackconf 2020 | The path to a Serverless-native era with Kubernetes by Paolo...
stackconf 2020 | The path to a Serverless-native era with Kubernetes by Paolo...stackconf 2020 | The path to a Serverless-native era with Kubernetes by Paolo...
stackconf 2020 | The path to a Serverless-native era with Kubernetes by Paolo...
 
Kubernetes - training micro-dragons without getting burnt
Kubernetes -  training micro-dragons without getting burntKubernetes -  training micro-dragons without getting burnt
Kubernetes - training micro-dragons without getting burnt
 
Docker dev ops for cd meetup 12-14
Docker dev ops for cd meetup 12-14Docker dev ops for cd meetup 12-14
Docker dev ops for cd meetup 12-14
 
Killer Docker Workflows for Development
Killer Docker Workflows for DevelopmentKiller Docker Workflows for Development
Killer Docker Workflows for Development
 
Containers&Orchestration Approaches
Containers&Orchestration ApproachesContainers&Orchestration Approaches
Containers&Orchestration Approaches
 
The path to a serverless-native era with Kubernetes
The path to a serverless-native era with KubernetesThe path to a serverless-native era with Kubernetes
The path to a serverless-native era with Kubernetes
 
ContainerDayVietnam2016: Dockerize a small business
ContainerDayVietnam2016: Dockerize a small businessContainerDayVietnam2016: Dockerize a small business
ContainerDayVietnam2016: Dockerize a small business
 
What's New in Docker - February 2017
What's New in Docker - February 2017What's New in Docker - February 2017
What's New in Docker - February 2017
 
Red Hat and kubernetes: awesome stuff coming your way
Red Hat and kubernetes:  awesome stuff coming your wayRed Hat and kubernetes:  awesome stuff coming your way
Red Hat and kubernetes: awesome stuff coming your way
 
The App Developer's Kubernetes Toolbox
The App Developer's Kubernetes ToolboxThe App Developer's Kubernetes Toolbox
The App Developer's Kubernetes Toolbox
 
Containers as a Service with Docker
Containers as a Service with DockerContainers as a Service with Docker
Containers as a Service with Docker
 
Docker Container As A Service - March 2016
Docker Container As A Service - March 2016Docker Container As A Service - March 2016
Docker Container As A Service - March 2016
 
Kubernetes for the PHP developer
Kubernetes for the PHP developerKubernetes for the PHP developer
Kubernetes for the PHP developer
 
Test cloud application deployments locally and in CI without staging environm...
Test cloud application deployments locally and in CI without staging environm...Test cloud application deployments locally and in CI without staging environm...
Test cloud application deployments locally and in CI without staging environm...
 
Docker Enterprise Workshop - Technical
Docker Enterprise Workshop - TechnicalDocker Enterprise Workshop - Technical
Docker Enterprise Workshop - Technical
 
Open shift and docker - october,2014
Open shift and docker - october,2014Open shift and docker - october,2014
Open shift and docker - october,2014
 

Mehr von Michael Hofmann

Mehr von Michael Hofmann (12)

Service Specific AuthZ In The Cloud Infrastructure
Service Specific AuthZ In The Cloud InfrastructureService Specific AuthZ In The Cloud Infrastructure
Service Specific AuthZ In The Cloud Infrastructure
 
New Ways To Production - Stress-Free Evolution Of Your Cloud Applications
New Ways To Production - Stress-Free Evolution Of Your Cloud ApplicationsNew Ways To Production - Stress-Free Evolution Of Your Cloud Applications
New Ways To Production - Stress-Free Evolution Of Your Cloud Applications
 
The Easy Way to Secure Microservices
The Easy Way to Secure MicroservicesThe Easy Way to Secure Microservices
The Easy Way to Secure Microservices
 
Service Mesh vs. Frameworks: Where to put the resilience?
Service Mesh vs. Frameworks: Where to put the resilience?Service Mesh vs. Frameworks: Where to put the resilience?
Service Mesh vs. Frameworks: Where to put the resilience?
 
Service Mesh vs. Frameworks: Where to put the resilience?
Service Mesh vs. Frameworks: Where to put the resilience?Service Mesh vs. Frameworks: Where to put the resilience?
Service Mesh vs. Frameworks: Where to put the resilience?
 
Servicierung von Monolithen - Der Weg zu neuen Technologien bis hin zum Servi...
Servicierung von Monolithen - Der Weg zu neuen Technologien bis hin zum Servi...Servicierung von Monolithen - Der Weg zu neuen Technologien bis hin zum Servi...
Servicierung von Monolithen - Der Weg zu neuen Technologien bis hin zum Servi...
 
Service Mesh mit Istio und MicroProfile - eine harmonische Kombination?
Service Mesh mit Istio und MicroProfile - eine harmonische Kombination?Service Mesh mit Istio und MicroProfile - eine harmonische Kombination?
Service Mesh mit Istio und MicroProfile - eine harmonische Kombination?
 
Service Mesh - kilometer 30 in a microservice marathon
Service Mesh - kilometer 30 in a microservice marathonService Mesh - kilometer 30 in a microservice marathon
Service Mesh - kilometer 30 in a microservice marathon
 
Service Mesh - Kilometer 30 im Microservices-Marathon
Service Mesh - Kilometer 30 im Microservices-MarathonService Mesh - Kilometer 30 im Microservices-Marathon
Service Mesh - Kilometer 30 im Microservices-Marathon
 
API-Economy bei Financial Services – Kein Stein bleibt auf dem anderen
API-Economy bei Financial Services – Kein Stein bleibt auf dem anderenAPI-Economy bei Financial Services – Kein Stein bleibt auf dem anderen
API-Economy bei Financial Services – Kein Stein bleibt auf dem anderen
 
Microprofile.io - Cloud Native mit Java EE
Microprofile.io - Cloud Native mit Java EEMicroprofile.io - Cloud Native mit Java EE
Microprofile.io - Cloud Native mit Java EE
 
Microservices mit Java EE - am Beispiel von IBM Liberty
Microservices mit Java EE - am Beispiel von IBM LibertyMicroservices mit Java EE - am Beispiel von IBM Liberty
Microservices mit Java EE - am Beispiel von IBM Liberty
 

Kürzlich hochgeladen

%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
masabamasaba
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
masabamasaba
 
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Medical / Health Care (+971588192166) Mifepristone and Misoprostol tablets 200mg
 
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
chiefasafspells
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
masabamasaba
 

Kürzlich hochgeladen (20)

tonesoftg
tonesoftgtonesoftg
tonesoftg
 
WSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go PlatformlessWSO2CON2024 - It's time to go Platformless
WSO2CON2024 - It's time to go Platformless
 
WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
 
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
%+27788225528 love spells in new york Psychic Readings, Attraction spells,Bri...
 
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 
WSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
WSO2Con2024 - Enabling Transactional System's Exponential Growth With SimplicityWSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
WSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
 
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
Abortion Pill Prices Tembisa [(+27832195400*)] 🏥 Women's Abortion Clinic in T...
 
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
 
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
 
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
Love witchcraft +27768521739 Binding love spell in Sandy Springs, GA |psychic...
 
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
%+27788225528 love spells in Boston Psychic Readings, Attraction spells,Bring...
 

Developer Experience Cloud Native - Become Efficient and Achieve Parity

  • 1. Developer Experience Cloud Native - Become Efficient and Achieve Parity Michael Hofmann https://hofmann-itconsulting.de
  • 2. Developer Experience Cloud Native create code Docker build & push deploy to (local) K8S test & debug remote Git push build & test (local)
  • 3. The Twelve-Factor App “methodology for building software-as-a-service apps that”: ● “Use declarative formats for setup automation, to minimize time and cost for new developers joining the project”; ● “Have a clean contract with the underlying operating system, offering maximum portability between execution environments”; ● “Are suitable for deployment on modern cloud platforms, obviating the need for servers and systems administration”; ● “Minimize divergence between development and production, enabling continuous deployment for maximum agility”; ● “And can scale up without significant changes to tooling, architecture, or development practices”. https://12factor.net
  • 4. The Twelve-Factor App I. Codebase One codebase tracked in revision control, many deploys II. Dependencies Explicitly declare and isolate dependencies III. Config Store config in the environment IV. Backing services Treat backing services as attached resources V. Build, release, run Strictly separate build and run stages VI. Processes Execute the app as one or more stateless processes VII. Port binding Export services via port binding VIII. Concurrency Scale out via the process model IX. Disposability Maximize robustness with fast startup and graceful shutdown X. Dev/prod parity Keep development, staging, and production as similar as possible XI. Logs Treat logs as event streams XII. Admin processes Run admin/management tasks as one-off processes
  • 5. Deviation in Parity: local vs cloud ● operation system ● JDK version ● environment – ENV vars – volume mounts – DNS (myservice.mynamespace.svc.cluster.local) ● backing service (single server / cluster) (e.g. Redis: SingleServerConfig, ClusterServersConfig) ● Java SecureRandom: in cloud too slow (missing entropy with isolated CPUs)
  • 6. The Quest: How to get new source code quick into container or pod to keep parity?
  • 7. Possible Solutions ● synchronous deployment in Kubernetes ● source reload in Kubernetes pod ● swap deployment of Kubernetes pod ● for completeness: source reload in local container – no focus in this session – to many manual tasks necessary (see summary)
  • 8. Sync Deployment: Skaffold ● handles the workflow for – building (application and image) – pushing to registry – deployment to Kubernetes ● keeps artifacts in sync ● workflow automated or manually https://skaffold.dev
  • 10. Skaffold Summary ● always full build and deployment cycle – deactivate JUnits for shorter roundtrip ● remote debug only with manual intervention (pod restart) ● automatic sync of deployment files and Docker images ● cleanup of all (skaffold-ed) resources in cluster ● main usage scenario: keep local and remote in sync ● remote debug is not a first class citizen
  • 11. ● OpenLiberty can reload code on every change ● setting in server.xml <applicationManager autoExpand=”true”> ● on file basis (app.war) or on individual class files ● concept: sync local class files to remote pod for reload in running app server ● remote debug with JDWP (java debug wire protocol) Source Reload: OpenLiberty/Ksync
  • 12. Ksync ● installs DaemonSet in K8s cluster ● works bi-directional ● local watch process keeps local folder and pod folder in sync ● new pods will also be synced (scale --replicas=2) https://github.com/ksync/ksync
  • 13. OpenLiberty/Ksync Summary ● full parity: code evolution inside running pod ● roundtrip takes only 1-2s ● JDWP is well-engineered ● stable debug connection (no pod restart) ● concept can also be applied to other app servers (e.g. tomcat) ● remove JDWP agent and debug port in production
  • 14. Source Reload: Quarkus Live Coding ● start app (in pod) in remote dev mode: – package app in mutable jar format – env setting: QUARKUS_LAUNCH_DEVMODE=true – same as mvn compile quarkus:dev for local dev mode ● intercepts HTTP requests: redeploys app if new code exists – redeploy takes less than 1 second (even for larger applications) ● connect local agent to remote host: mvn quarkus:remote-dev -Dquarkus.live-reload.url= http://my-remote-host:8080 ● sync can be delegated to e.g. Ksync (without url in previous command)
  • 16. Quarkus Live Coding Summary ● full parity: code evolution inside running pod ● no need for additional tools ● very quick roundtrip (< 1s) ● stable debug connection (JDWP) ● do not use dev-mode in production – app must be repackaged for production – env setting and debug port must be deleted
  • 17. Service-C (Pod) Service-B (Pod) swapped Service-A (Pod) Service-B (Pod) Swap Deployment local Kubernetes Env Volume Env Volume
  • 18. Swap Deployment ● debugging a service mesh ● substitutes K8S pod with a two-way network proxy ● proxies data from K8S environment (e.g., TCP connections, environment variables, volumes) to local process ● local process has its networking transparently overridden: DNS calls and TCP connections are routed to K8S ● Bridge to Kubernetes or Telepresence https://marketplace.visualstudio.com/items?itemName=mindaro.mindaro https://www.telepresence.io
  • 20. Swap Deployment Summary ● parity broken only on OS or JDK (env, mount, DNS parity) ● local development with local debugging ● no manipulation of image or settings necessary ● Non root account: can be set but a little complicated (Docker or env-settings) ● individual traffic – Telepresence additional service (commercial) – Bridge to Kubernetes out-of-the-box ● main usage scenarios: develop and debug service mesh local with nearly full parity
  • 21. Tool OS/JDK ENV DNS Mount Debug Efficient Source Reload (Local Container) mvn liberty:devc manually --env kubefwd manually --mount Remote Sync Deployment Skaffold Remote Source Reload (Kubernetes Pod) OpenLiberty/ Ksync Quarkus Live Coding Remote Swap Deployment Bridge to Kubernetes telepresence Local Summary