bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud
DESCRIPTION
CodeCampIasi25Oct2014TRANSCRIPT
![Page 1: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/1.jpg)
No fiddle, efficient development on the Google Cloud Platform
Dmitry NefedkinGoogle Cloud Platform Solutions Engineer, Google
Bogdan BoteaLead Developer, Appsbroker Consulting
![Page 2: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/2.jpg)
● Founded 7 Years ago, UK based● Google Reseller, Consultancy, Managed Services & Products● Google EMEA Partner of the year 2012● Worked on some of Google’s most prestigious projects● UK Premier Apps Reseller, Cloud Platform Service Provider,
We are also a Premier Search Reseller● GEO, GSA, Platform & Apps Certified
Who are Appsbroker?
![Page 3: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/3.jpg)
Please note that some of the slides have been removed.
Please come to our next event to get updated on the latest information about Google for Work and Appsbroker.
![Page 4: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/4.jpg)
Agenda■ Google awesome infrastructure - Dmitry■ Before the clouds■ Appsflow on App Engine■ Live coding■ Q&A
![Page 5: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/5.jpg)
![Page 6: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/6.jpg)
Google confidential | Do not distribute
Enrich your work environment.
Enable your information workers.
Drive innovation.
Live in a modern workplace.
Why Cloud Computing?
![Page 7: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/7.jpg)
Google confidential | Do not distribute
Enterprise Cloud Platform market will exceed $22B globally by 2015.2013
![Page 8: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/8.jpg)
IT Trends
The decreasing cost of storage enables virtually limitless storage in the cloud. $600 can buy enough storage for the world’s music.
(Source: McKinsey Global Institute May 2011)
Computing as a utility is now available for easy purchase, provided from massively efficient data centers.
(Source: Nicholas Carr, The Big Switch, 2008)
The internet allows for a model of real-time access to new innovation, information and applications from a wide range of devices.
AffordableCapacity
On-demandcomputing
Instantaccess
![Page 9: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/9.jpg)
For the past 16 years, Google has been building out the world’s fastest, most powerful, highest quality cloud infrastructure on the planet.
![Page 10: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/10.jpg)
Cloud Platform is built on the same infrastructure that powers Google.
![Page 11: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/11.jpg)
Google's Network Spans the Globe
![Page 12: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/12.jpg)
Google's Global OpenFlow Network
![Page 13: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/13.jpg)
2002 2004 2006 2008 2010 2012
Google Innovations in Software
ColossusDremelMapReduce
SpannerGFS Big Table
![Page 14: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/14.jpg)
Images by Connie Zhou
Wired, 'Google Throws Open Doors To Its Top Secret Data Center', October 2012
Google's Platform"[Google's] ability to build, organize, and operate a huge network of servers and fiber-optic cables with an efficiency and speed that rocks physics on its heels.
This is what makes Google Google: its physical network, its thousands of fiber miles, and those many thousands of servers that, in aggregate, add up to the mother of all clouds."
- Wired
![Page 15: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/15.jpg)
IaaS PaaS SaaSInfrastructure-as-a-Service Platform-as-a-Service Software-as-a-Service
Google Cloud Platform
Cloud Computing
![Page 16: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/16.jpg)
IaaS PaaS SaaSInfrastructure-as-a-Service Platform-as-a-Service Software-as-a-Service
ApplicationsDataRuntimeMiddlewareO/SVirtualizationServersStorageNetworking
ApplicationsDataRuntimeMiddlewareO/SVirtualizationServersStorageNetworking
ApplicationsDataRuntimeMiddlewareO/SVirtualizationServersStorageNetworking
PackagedSoftware
ApplicationsDataRuntimeMiddlewareO/SVirtualizationServersStorageNetworking
Cloud ComputingYou Manage Vendor Managed
![Page 17: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/17.jpg)
Storage App ServicesCompute
Cloud Storage
Cloud SQL
Cloud Datastore
Compute Engine
App Engine
BigQuery
Cloud Endpoints
Google Cloud Platform
![Page 18: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/18.jpg)
Mobile Gaming
Big Data
Storage
High Performance Computing Digital Marketing
![Page 19: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/19.jpg)
4 Million active applications in our cloud
![Page 21: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/21.jpg)
No fiddle, efficient development on the Google Cloud Platform
Bogdan BoteaLead Developer, Appsbroker Consulting
Vasile IrimiaGoogle Cloud Platform Developer, Appsbroker Consulting
![Page 22: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/22.jpg)
Appsbroker team
![Page 23: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/23.jpg)
Agenda■ Google awesome infrastructure - Dmitry■ Before the clouds■ Appsflow on App Engine■ Live coding ■ Q&A
![Page 24: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/24.jpg)
Today’s developers
![Page 25: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/25.jpg)
Flip the focus
![Page 26: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/26.jpg)
Copyright 2014 Google Inc
GAE Architecture And Optmization
Use Case - Real Time Earthquake Monitor
NIED
App Engine
Metrics collected at
NIED
NIED pushes the image file to GAE every second
Clients pulls the image every two seconds
● GAE Web App By NIED Japan + Googleo National research Institute for
Earth science and Disaster prev.o The blinking dots represents real
time Peak Ground Acceleration ● YouTube video How it worked at the
March 11, 2011 earthquake● 20,000 concurrent users
10,000 reqs/sec at peak
![Page 27: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/27.jpg)
Web Application challenges● Scalability
● Reliability
● Cost efficiency
Designing for Scale and Reliability
How do I design a web service that is scalable and reliable like this?
![Page 28: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/28.jpg)
Copyright 2014 Google Inc
GAE Architecture And Optmization
To Build in Traditional Way...
➢ Hardware Failures
➢ Traffic Spike
➢ Growing Big Data
➢ Complex Design
➢ Complex Dev.
➢ Complex Admin
➢ Cost
What About
![Page 29: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/29.jpg)
Copyright 2014 Google Inc
GAE Architecture And Optmization
To Build with Google App Engine
✓ Hardware Failures
✓ Traffic Spike
✓ Growing Big Data
✓ Simpler Design
✓ Simpler Dev
✓ No Admin
✓ No Initial Funding
How About
![Page 30: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/30.jpg)
Agenda (to redesign)■ Google awesome infrastructure - Dmitry■ Before the clouds■ Appsflow on App Engine■ Live code ■ Q&A
![Page 31: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/31.jpg)
Appsflow
![Page 32: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/32.jpg)
Appsflow - Data model
● HRD Datastore
● Sharding
● Denormalization
![Page 33: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/33.jpg)
Appsflow - HRD DatastoreDatastore RDBMS
Query language flexibility
SQL-like query language● Limited to simple filter and sort
Full support of SQL● Table JOIN● Flexible filtering● Subquery
Reliability and Scalability
Highly scalable and reliable Hard to scale
![Page 34: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/34.jpg)
Appsflow - Service layer
● Business logic & transaction management
● DI
● Task Queue API
● Cron jobs
![Page 35: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/35.jpg)
Appsflow - Task QueueUse Task Queue API to execute background work
Queue queue = QueueFactory.getQueue("workflow-queue");
queue.add(TaskOptions.Builder.withUrl("/backend/taskqueue").
param("nodeId", node.getKeyAsString()));
![Page 36: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/36.jpg)
Appsflow - Cron jobsUse Cron jobs to execute periodic tasks
<?xml version="1.0" encoding="UTF-8"?>
<cronentries>
<cron>
<url>/checkworkflows</url>
<description>Periodically check for blocked workflows</description>
<schedule>every day 00:00</schedule>
</cron>
</cronentries>
![Page 37: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/37.jpg)
Appsflow - Cloud Endpoints
● Expose standards based REST interfaces with built in Authorization
● Use auto-generated, strongly typed, mobile optimized client
libraries for Android, iOS and web.
![Page 38: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/38.jpg)
Appsflow - Memcache
MemchacheService cache = MemcacheServiceFactory.getMemcacheService();
…
User user = cache.get(“accessToken”) ;
if (user != null) {
return user;
} else {
// retrieve user details and update the datastore
cache.put(“accessToken”, user, Expiration.byDeltaSeconds(DURATION_IN_SECONDS));
return user;
}
![Page 39: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/39.jpg)
Snapchat
Delivers 400 million photos a day
![Page 40: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/40.jpg)
Agenda■ Google awesome infrastructure - Dmitry■ Before the clouds■ Appsflow on App Engine■ Live coding■ Q&A
![Page 41: Bogdan botea, dmitry nefedkin no fiddle, efficient development on the google cloud](https://reader034.vdocuments.us/reader034/viewer/2022052508/559364121a28ab9e478b47ba/html5/thumbnails/41.jpg)
$500 in Cloud Platform credit to launch your idea!
Build. Store. Analyze.On the same infrastructure
that powers GoogleA voucher will be sent to your email
Click ‘Apply Now’ and complete the application with
promo code: codecamp-con
1
2
3
Go to cloud.google.com/starterpack
Start using Cloud Platform now!
4 Create a new Project in Cloud Console,
activate the billing and apply voucher -
http://console.developers.google.
com/billing/redeem