2015-11-05 aws tech summits hk
TRANSCRIPT
Teddy Chan CEO& Co-Founder
• Who am I
• What is AfterShip
• How aftership scale
• Share some examples
Something about me
Something about me
Something about me
Something about me
Problem
Where is my order?
Shipment tracking APISupporting 270+ 318 carriers
<5 Team member Built everything
That’s not right!
What we want
We build product, not technology
KISS
20+ Team member Built the product only
Problem
AWS DNS failover
Problem for nodejs
redis.lexxas.ng.0001.use1.cache.amazonaws.com
10.0.1.100Master
Problem for nodejs
redis.lexxas.ng.0001.use1.cache.amazonaws.com
10.0.1.100Master
10.0.2.200Slave
Problem for nodejs
redis.lexxas.ng.0001.use1.cache.amazonaws.com
10.0.1.100Master -> Slave
10.0.2.200Slave -> Master
Problem for nodejs
redis.lexxas.ng.0001.use1.cache.amazonaws.com
10.0.1.100Master -> Slave
No DNS lookup again!
Solution for nodejs
ioredis
https://github.com/luin/ioredis
2015 Sept 19
Money is another problem
80% cheaper
- On demand
- Reserved
- Spot
EC2 Instances Purchased Options
EC2 Instances Purchased Options m3.large
http://calculator.s3.amazonaws.com/index.html
Op#on Hourly Discount
OnDemand 0.1330 --
1-yReserved 0.0810 39%off
3-yReserved 0.0520 61%off
Per Instance Prices & Projected Costs (all in USD)
EC2 Instances Purchased Options m3.large
http://calculator.s3.amazonaws.com/index.html
Op#on Hourly Discount
OnDemand 0.1330 --
1-yReserved 0.0810 39%off
3-yReserved 0.0520 61%off
Spot 0.0165 88%off
Per Instance Prices & Projected Costs (all in USD)
Spot Instance
- Cheap, very cheap
- Will be terminated at any time
- Good for worker, non-long process
How
EC2 Instances Purchased Options
Spot Instance
- Almost suitable for all services
- 6th Jan 2015
-
- 2 mins
https://aws.amazon.com/blogs/aws/new-ec2-spot-instance-termination-notices/
Let’sshowyousth
28
• 8 combination+ (zone + type)
• Stateless application the best
• Backend process need to
handle graceful shutdown
• Double performance but ¼ of
original price
OpenSource
hDps://github.com/aJership/
30