Post on 18-Jan-2017
transcript
© Electric Cloud | electric-cloud.com
Powering DevOps Automation and Continuous Delivery
Better software faster
Process as Code: An Introduction to the ElectricFlow Automation DSL
© Electric Cloud | electric-cloud.com
Outline
• Introduction• What is a DSL?• Why am I excited about EF DSL?• Some use case where EF DSL shines• Benefits of code-based software delivery• Introduction to EF DSL• EF DSL examples• EF DSL editor• Conclusion• Q&A
© Electric Cloud | electric-cloud.com
Who am I?
Greg MaxeySolutions Engineer at Electric Cloud, five yearsSoftware Delivery Automation@gpmaxey
A career in automation• Test and measurement• Signal processing and analysis• System level design• Integrated chip hardware design• Microprocessor and system on chip design• Network equipment testing
© Electric Cloud | electric-cloud.com
Show of hands
• How many of you are involved in software delivery?• Are your primary tools UIs? or• Are your primary tools code based / scripts?• Do you automate the automation?• How many of you are familiar with Electric Cloud?• How many of you are users or ElectricFlow?
© Electric Cloud | electric-cloud.com
My job – DevOps Integration and Orchestration
Infrastructure
Development Operations
Developers
Coding Local Builds Local Testing
Preflight
Build
SCM
CIBuild
ArtifactManageme
nt
QA/UAT•Provision Environment
•Deploy
•Testing
Staging
•Deploy•Smoke test
Production
Retr
iev
e
On Preflight Success
Changes
Chec
kout
Chec
kout
CheckoutPublis
h
Checkin Retr
iev
e
On successpromote ¬ify QA & UAT
On successnotify releaseteam
1
2
3
45
6
7 8 9
Debug Prod
Start Release Pipeline
© Electric Cloud | electric-cloud.com
Getting to software delivery automation
GovernanceOrchestration
Dev Ops
Infrastructure
Business process requirements and
constraints(SW Delivery
Specifications)
Applications / SW
© Electric Cloud | electric-cloud.com
DEVO
PSWhat Electric Cloud provides for Software Delivery
DEPLOY
ANY APP. ANY VERSION.
ANYWHERE.ANYTIME.
RELEASE
TRADITIONAL AND CD
PIPELINES AND RELEASES
BUILD/TEST
FLEXIBLE AND SCALABLE
AUTOMATION FOR DEV AND QA
OTHER
ORCHESTRATE ANY TOOLCHAIN OR PROCESS.
DSL, CLI, REST, SOAP, HTTP, API, SDK
Plugs right in to your existing tools
ElectricFlowDEVOPS AUTOMATION PLATFORM
SHARED CONTROL | SHARED VISIBILITY | SHARED RESOURCES
SCALABLEEXTENSIBLE SECURE
TRANSPARENTFLEXIBLE HYBRID CLOUD
© Electric Cloud | electric-cloud.com
What is a DSL?
A domain-specific language (DSL) is a computer language specialized to a particular application domain. This is in contrast to a general-purpose language (GPL), which is broadly applicable across domains, and lacks specialized features for a particular domain… DSLs can be further subdivided by the kind of language, and include domain-specific markup languages, domain-specific modeling languages (more generally, specification languages), and domain-specific programming languages.
- Wikipedia
© Electric Cloud | electric-cloud.com
Examples of DSLs
• HTML for webpage definition• MATLAB for mathematical
modeling• Verilog, SystemC, LISA for HW,
SoC and uProcessor design• Regex for text pattern matching• make for build automation• Chef recipes & Puppet manifests
for Infrastructure as Code
• But what for software delivery automation?
© Electric Cloud | electric-cloud.com
Anders Wallgren, CTO Electric Cloud
Why am I excited about DSL?
Electric Flow DSL
• Easy to learn• Compact• Declarative• Idempotent• Inheritance
Very fast model creation
© Electric Cloud | electric-cloud.com
Configuration Management build Manual Run Book1. PuTTY into VOB server2. Create dynamic view3. … (other VOB interactions)4. Create local copy on build machine5. Adjust permisions6. Modify registry7. Run build script8. … (other file manipulations)9. Start Linux VM10. Copy build to VM11. Create RPMs on VM12. Create check sum file13. Copy RPMs to build machine14. … (other file manipulations)15. Burn CD
© Electric Cloud | electric-cloud.com
Spin up a field-deployable datacenter
1. Do inventory of installation media2. Power up3. Verify networking is operational4. Install the base services and infrastructure software5. Install the main software components6. Perform functional test subworkflow activity7. Checkout XYZ functionality8. Test and checkout9. Verify component interoperability
© Electric Cloud | electric-cloud.com
When models get large
Servers Services
TypeA svs1, svs2, svs3
TypeB svs1, svs4, svs5, svs6, svs7
TypeC svs8, svs9
TypeD svs8, svs10, svs11
TypeE svs12
… ..
© Electric Cloud | electric-cloud.com
Onboard applications
Development Continuous Integration Continuous Deployment
Visual Studio.NET
Eclipse
Java
xCode
SCM
Code Analysis
BuildUnit Test
Arti
fact
Man
agem
ent
Release Pipeline
Deploy Target Containers
IIS Apprenda iOS
QA UAT PROD
© Electric Cloud | electric-cloud.com
Onboarding Parameters
[ { "name": "appName", "label": "Application Name", "description": "The name of the application to be onboarded", "defaultValue": "My Application" }, { "name": "sourceLocation", "label": "Source Code Location", "description": "SCM location for CI", "defaultValue": "http://gitlab.mycompany.com/apps/myapp.git" }, { "name": "stages", "label": "Stage names", "description": "Comma-separated list of stages for pipeline", "defaultValue": "Dev,QA,UAT,Staging,Prod" },…
© Electric Cloud | electric-cloud.com
These use cases showed me the power of DSL
• Easier iterative model development• Data-driven model creation• Enable end-to-end process generation
© Electric Cloud | electric-cloud.com
Benefits of EF DSL to enterprise software delivery• Documented process• Executable specification• Ease onboarding of new and legacy projects and
teams• Ability to use mature code-based tools and
approaches• Create and manage very complex delivery processes• Enable working at scale with teams of thousands• Matching the right interface to the particular user
© Electric Cloud | electric-cloud.com
Benefits of Code-based approaches in general
• Leverage mature tool chains and best practices• IDEs• SCM / versioning• Modular design• Test-driven development• Static analysis and other code quality tools
• Ease of Refactoring• Sharing / Collaboration• Scales well• Easier data-driven approaches
© Electric Cloud | electric-cloud.com
ElectricFlow Domain Specific Language, EF DSL• Groovy-based• Native access to ElectricFlow
platform• Supports entire EF API• Enables model authoring and
scripting
And as said before• Easy to learn• Compact• Declarative• Idempotent• Inheritance
© Electric Cloud | electric-cloud.com
ElectricFlow platform addresses Process AutomationEnd-to-end software delivery automation through graphical/Web interface• Centralized• Secure• High scalability• Visibility• Traceable• Fault tolerant
© Electric Cloud | electric-cloud.com
EF DSL Examples - DEMO
• Configuration Management Procedure• Onboarding legacy applications
Procedures Environment models Application models Pipeline delivery discipline
• Spinning up new projects Training set up
© Electric Cloud | electric-cloud.com
Conclusion
When it comes to software delivery,
ElectricFlow UI is great for Visualization Medium Scale content authoring
For large-scale automating the automation EF DSL Gives full access to ElectricFlow platform Enables code-based authoring, or Process-as-Code
© Electric Cloud | electric-cloud.com
Thank youNetworking
Other Systems
ISV, Internet & Entertainment
Heavy Industry
Financial Services
Automotive Medical Devices
Semiconductor
Aerospace /Defense
Mobile Devices
Q&A