SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our User Agreement and Privacy Policy.
SlideShare uses cookies to improve functionality and performance, and to provide you with relevant advertising. If you continue browsing the site, you agree to the use of cookies on this website. See our Privacy Policy and User Agreement for details.
Successfully reported this slideshow.
Activate your 14 day free trial to unlock unlimited reading.
Faster! Faster! Accelerate your business with blazing prototypes
Bring your ideas to life! Convince your boss to that open source development is faster and cheaper than the "safe" COTS solution they probably hate anyway. Let's investigate ways to get real-life, functional prototypes up with blazing speed. We'll look at and compare tools for truly rapid development including Python, Django, Flask, PHP, Amazon EC2 and Heroku.
Bring your ideas to life! Convince your boss to that open source development is faster and cheaper than the "safe" COTS solution they probably hate anyway. Let's investigate ways to get real-life, functional prototypes up with blazing speed. We'll look at and compare tools for truly rapid development including Python, Django, Flask, PHP, Amazon EC2 and Heroku.
I’m Drew Engelson I
work for Celerity - “The business acceleration consultancy” - We help get companies “unstuck” I help organizations decide what tech to buy or build - National Geographic Society - PBS - American Diabetes Association Then we make it happen
The challenge Build a
simple, fully functional prototype - A basic web service for image transformation Requirements - Pass in a source image url, desired height and width - Pull down the image to server - Resize the image on the server - Return derivative image
The challenge ur l =
ht t p: / / f ar m s t at i c f l i c kr . c om 7138/ 7576110858_d66eec 09f 5_z . j pg 8. / w dt h = 200 i hei ght = 200 Photo: Tomcrenshaw @ Flickr
Surveyed a few frameworks
PHP - Zend - CodeIgniter Python - Django - Flask - Bottle I know, there are many other choices… Which is your favorite?
Compared on Learning curve
Ease of bootstrapping dev environment Ease of development - # of files created or touched - # of lines written or modified - Complexity of code Speed of deployment - Need to share with others, right? Note: This is a very non-scientific study
i mp o r t
c S t r i n g I O i mp o r t r e q u e s t s f r o m PI L i mp o r t I mag e f r o m f l as k i mp o r t F l as k , r e q u e s t , s e n d _ f i l e ap p = F l as k ( _ _ n ame _ _ ) @ap p . r o u t e ( ' / ' , me t h o d s = [ ' GET' , ] ) d ef res i z e( ) : u r l = r e q u e s t . val u e s [ ' u r l ' ] r e q = r e q u e s t s . ge t ( u r l ) r e s o u r c e = c S t r i n g I O. S t r i n g I O( r e q . c o n t e n t ) i mag e = I mag e . o p e n ( r e s o u r c e ) i mag e = i mag e . r e s i z e ( ( i n t ( r e q u e s t . val u e s [ ' w' ] ) , i n t ( r e q u e s t . val u e s [ ' h ' ] ) ) , I mag e . ANTI AL I AS ) r e s o u r c e = c S t r i n g I O. S t r i n g I O( ) i mag e . s ave ( r e s o u r c e , ' JPEG' ) r e s o u r c e . s e e k ( 0) r e t u r n s e n d _ f i l e ( r e s o u r c e , mi me t yp e = ' i mag e / j p e g ' ) i f _ _ n ame _ _ = = ' _ _ mai n _ _ ' : ap p . r u n ( d e b u g = Tr u e )
Resources http://flask.pocoo.org/ https://www.djangoproject.com/
http://codeigniter.com/ http://bottlepy.org/ http://framework.zend.com/ Josh Linkner - http://www.inc.com/articles/201106/josh-linkner-7-steps-to-a-culture-of-innovation.html I know, there are many other choices… What’s your favorite?