Write Great Code
in the Cloud
![](https://media2.giphy.com/media/FALQSnocJzr3y/giphy.gif)
Linda Nichols
@lynnaloo
![](https://media3.giphy.com/media/1S3vm6ISM2gDu/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/6614874/10373785_10152510872774047_1339805137394219664_n.jpg)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
#serVAless
Virginia is for Lovers
JavaScript
^
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/2358039/ninjacat_500.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/8578119/revconflogo.png)
#jaVAscript
What is Serverless?*
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
#serverless
* "Serverless" is a catchy, made-up, marketing term.
Kind of like, "Cloud."
What is Serverless?
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
#serverless
-
Fully-managed services
-
Event-driven architectures
-
Pay for only what you use
-
Focus on applications
-
Fewer wasted resources
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
-
Less time writing redundant code
-
Support for all* programming languages
-
Less concern about infrastructure
-
Built-in services and libraries means less code
-
FaaS map to microservices
-
Faster time to production
It's for Developers!
But there are servers?
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
#serverfull
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/8578125/Screen_Shot_2021-05-17_at_10.05.42_PM.png)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Let's Talk About Serverless
and developers
![](https://media3.giphy.com/media/xT8qBkxurG8BVukOVa/giphy.gif)
^
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Developers Have Lots of Opinions
JavaScript
^
![](https://media2.giphy.com/media/3o72EUgNr1GswFpyfe/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
They Love Process and Best Practices
![](https://media0.giphy.com/media/3o72FiKtrMAjIb0Rhu/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
-
Favorite editor
-
Favorite language
-
Favorite frameworks
-
Code formatting tool
-
Formatting tool for code prettiness
-
Real-time static code analysis
-
Consistent rules and formatting
Developers Want (need):
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Vim
VS Code
Emacs
Atom
IntelliJ
Visual Studio
Eclipse
Notepad
Lint
Prettier
EditorConfig
pylint
eslint
Mechanical Keyboard
Stack Overflow
Java
.Net
npm
nuget
Ruby
CoffeeScript
Python
Rust
TypeScript
yarn
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
- Pair-programming
- Your opinionated testing framework
- Unit tests
- Integration tests
- Code coverage up to 90%
You Must Test the Code:
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Wait, should we have written the tests before the code?!?
![](https://media4.giphy.com/media/3o72F9zlgL99s2bTO0/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
- Use opinionated revision control system
- Current popular branching strategy
- Squash those insignificant commits
- Very detailed commit messages
- Branch names match the task
Then Commit the Code:
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Github
Gitlab
Visual Source Safe
Bitbucket
Gitflow
Github Flow
Subversion
CodeCommit
GitOps
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
-
Pre-commit hook
-
Push the code to a dev branch
-
Issue a pull request
-
Code analysis and builds are passing
-
Make sure all of the tests are passing
-
Request a code review
Merge the Code into Master:
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Your branch isn't up to date??
Why aren't the tests passing?
Why did you use tabs and not spaces?
Squash those commits!
The linter is failing!
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Sometimes, reviewers can be tough.
![](https://media1.giphy.com/media/xT8qBgC5HriPFDgFby/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
OK, LGTM. Merged.
![](https://media2.giphy.com/media/l0MYzparXxoEJSIb6/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Cue the CI/CD Tool:
![](https://media2.giphy.com/media/xT9DPxB17BOTWHMnRu/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Travis CI
Azure Pipelines
Gitlab CI
Jenkins
Circle CI
Bamboo
CodeDeploy
Flux
Github Actions
LaunchDarkly
CodeBuild
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
What about code written for the cloud?
![](https://media4.giphy.com/media/wWh2rKVimP6Vs9SUA4/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Pre-recorded Demo Time
![](https://media2.giphy.com/media/3o72EYZQqVH6aIrGYE/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
![](https://media0.giphy.com/media/xT8qB72Dfmxd8nv9DO/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
![](https://media2.giphy.com/media/l0K435hG58tS8zCuY/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Unfortunately, no service is fully-managed enough to format, test, and debug your messy code.
![](https://media0.giphy.com/media/3o72EZ6EzqhOs0fy1O/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
So, why do those who hold process so dear, throw it all away when they write code for the cloud?
![](https://media1.giphy.com/media/xT8qB7ENEz4Ba1fdtK/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Because cloud development is new and can be a little scary.
![](https://media3.giphy.com/media/l0HFiVWWUQyI2wv9S/giphy.gif)
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
But all of the development practices that we love, still apply in the cloud.
and there are many, many new tools and services to support your process.
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
My (highly opinionated) Toolset
- Static Code Analysis: Eslint
- Enforcing Style: EditorConfig
- Pre-commit Style: Prettier
- Revision Control: Github
- Testing: Mocha
- CI: Github Actions
- Editor: VS Code
- Language: JavaScript
- Cloud: Azure*
Demo
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
https://www.github.com/lynnaloo/only-zuul
![](https://media3.giphy.com/media/3o72EZKeW67ZP5ZNuM/giphy.gif)
Who is the best Ghostbuster?
Conclusion
- No-ops does not mean no DevOps
- Online editors != revision control
- Love your linter
- Put your editor to work
- Testing in prod is not testing
- Abstraction is not CI/CD
- Don't abandon what's important
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/4199753/43-twitter-512.png)
@lynnaloo
Thank you
![](https://media3.giphy.com/media/1S3vm6ISM2gDu/giphy.gif)
![](https://media4.giphy.com/media/xThtar0e9kO3WkwQ1O/giphy.gif)
Credits
![](https://s3.amazonaws.com/media-p.slid.es/uploads/152953/images/6625366/IMG_3733.jpg)
Travis Webb
YOLO Programmer
Write great code, in the cloud
By Linda Nichols
Write great code, in the cloud
Write great code, in the cloud - JS World 2021
- 840