<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Blog &#187; Techniques</title>
	<atom:link href="http://blog.earlystageit.com/category/techniques/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.earlystageit.com</link>
	<description>IT topics of interest to early stage companies</description>
	<lastBuildDate>Fri, 16 Jul 2010 16:04:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='blog.earlystageit.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://www.gravatar.com/blavatar/966ccbbc0eab06abc88a7c11f347cf46?s=96&#038;d=http://s2.wp.com/i/buttonw-com.png</url>
		<title>Blog &#187; Techniques</title>
		<link>http://blog.earlystageit.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://blog.earlystageit.com/osd.xml" title="Blog" />
	<atom:link rel='hub' href='http://blog.earlystageit.com/?pushpress=hub'/>
		<item>
		<title>Woven Clouds: OpenID</title>
		<link>http://blog.earlystageit.com/2010/01/31/woven-clouds-openid/</link>
		<comments>http://blog.earlystageit.com/2010/01/31/woven-clouds-openid/#comments</comments>
		<pubDate>Sun, 31 Jan 2010 12:29:49 +0000</pubDate>
		<dc:creator>J</dc:creator>
				<category><![CDATA[Techniques]]></category>
		<category><![CDATA[Google App Engine]]></category>
		<category><![CDATA[OpenID]]></category>
		<category><![CDATA[Tips and Techniques]]></category>

		<guid isPermaLink="false">http://blog.earlystageit.com/?p=320</guid>
		<description><![CDATA[When it comes to building services using the cloud, one often comes across the need to weave different cloud-based offerings together. One example is OpenID. I blogged about it last year. In this post, I would like to take it to the next level and offer a programming pattern for using it with specific examples [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=320&subd=earlystageit&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<p>When it comes to building services using the cloud, one often comes across the need to weave different cloud-based offerings together. One example is OpenID. I blogged about it <a href="http://blog.earlystageit.com/2009/05/04/barriers-to-entry-userids/" target="_blank">last year</a>. In this post, I would like to take it to the next level and offer a programming pattern for using it with specific examples for Google App Engine. JanRain&#8217;s <a href="https://rpxnow.com/" target="_blank">RPX API</a> makes it easy to incorporate.</p>
<h3>Ingredients</h3>
<p>When you sign up with RPX and register your application, you get:</p>
<ol>
<li>A application ID,</li>
<li>An iFrame widget and</li>
<li>An API token.</li>
</ol>
<p>When signing up, the domain names need to be provided. These are domain names from which an authentication request may originate. In our case, that includes localhost and www.example.com.</p>
<h3>Recipe</h3>
<p>Create a login page and place the iFrame widget on it. The iFrame will point to something like</p>
<pre>src="https://example.rpxnow.com/openid/embed?token_url=appRpxURL"</pre>
<p>where appRpxURL is a URL served by the application. When a user interacts with the login page, RPX calls the application at this URL with a token and the application is expected to turn around and request information about the user. This Google App Engine <a title="OpenID interaction code sample" href="http://www.earlystageit.com/srcCodeShow/OpenID.py" target="_blank">code fragment</a> illustrates the interaction (to access it, you will need to use an OpenID login). At this point, the application knows the user id. This part is documented in a number of places on the web.</p>
<h3>Integration</h3>
<p>In a number of the applications we develop at Early Stage IT, the user id is stored in a session variable using <a title="Session Management Utilities" href="http://gaeutilities.appspot.com/" target="_blank">GAE Utilities</a> for the remainder of the session. The above-cited code fragment shows this also. The application is still responsible for determining what the user is entitled to do. The first thing to do in handling a user request is to verify that the user has the requisite application capability. This is illustrated in the last part of the sample code.</p>
<p>When the user logs out, clear the cookies by calling theSession.terminate()</p>
<h3>If you use it…</h3>
<p>…please cite this blog post. Feedback — positive or negative — gratefully accepted.</p>
<br />Filed under: <a href='http://blog.earlystageit.com/category/techniques/'>Techniques</a> Tagged: <a href='http://blog.earlystageit.com/tag/google-app-engine/'>Google App Engine</a>, <a href='http://blog.earlystageit.com/tag/openid/'>OpenID</a>, <a href='http://blog.earlystageit.com/tag/tips-and-techniques/'>Tips and Techniques</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/earlystageit.wordpress.com/320/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/earlystageit.wordpress.com/320/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/earlystageit.wordpress.com/320/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/earlystageit.wordpress.com/320/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/earlystageit.wordpress.com/320/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/earlystageit.wordpress.com/320/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/earlystageit.wordpress.com/320/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/earlystageit.wordpress.com/320/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/earlystageit.wordpress.com/320/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/earlystageit.wordpress.com/320/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=320&subd=earlystageit&ref=&feed=1" />]]></content:encoded>
			<wfw:commentRss>http://blog.earlystageit.com/2010/01/31/woven-clouds-openid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">J.Singh</media:title>
		</media:content>
	</item>
		<item>
		<title>Google App Engine Hackathon</title>
		<link>http://blog.earlystageit.com/2009/10/14/hackathon/</link>
		<comments>http://blog.earlystageit.com/2009/10/14/hackathon/#comments</comments>
		<pubDate>Wed, 14 Oct 2009 12:16:42 +0000</pubDate>
		<dc:creator>J</dc:creator>
				<category><![CDATA[Techniques]]></category>
		<category><![CDATA[Training]]></category>
		<category><![CDATA[Google App Engine]]></category>

		<guid isPermaLink="false">http://earlystageit.wordpress.com/?p=267</guid>
		<description><![CDATA[This Hackathon will introduce software engineers to Google App Engine. It will be free of charge, first-come-first-served but preference will be given to software engineers in the web development area. Event Details: Location: Aprigo, 460 Totten Pond Rd suite 660, Waltham, MA. I would like to thank Aprigo for their sponsorship of this event. Date: [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=267&subd=earlystageit&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<div class="wp-caption alignright" style="width: 155px"><img title="Google App Engine Logo" src="https://www.google.com/accounts/ah/appengine.jpg" alt="App Engine Logo" width="145" height="111" /><p class="wp-caption-text">Google App Engine</p></div>
<p>This Hackathon will introduce software engineers to Google App Engine. It will be free of charge, first-come-first-served but preference will be given to software engineers in the web development area.</p>
<p><strong>Event Details:</strong></p>
<ul>
<li><span style="text-decoration:underline;">Location</span><strong><span style="font-weight:normal;">: Aprigo, 460 Totten Pond Rd suite 660, </span></strong>Waltham, MA. I would like to thank Aprigo for their sponsorship of this event.</li>
<li><span style="text-decoration:underline;">Date</span>: November 6, 2009<strong></strong></li>
<li><strong><span style="font-weight:normal;"><span style="text-decoration:underline;">Time</span>: 9:00 am to 4:00 pm </span></strong></li>
<li><strong><span style="font-weight:normal;"><span style="text-decoration:underline;">Meeting capacity</span>: 10 people</span></strong></li>
<li><strong><span style="font-weight:normal;"><span style="text-decoration:underline;">Food/drink</span>: bring your own / buy in the building.</span></strong></li>
<li><strong><span style="font-weight:normal;">Sign up: <a href="http://www.eventbrite.com/event/471862353" target="_blank">Eventbrite</a>.<br />
</span></strong></li>
</ul>
<p>It is <em>not</em> an <em>introduction to web programming</em> or a <em>Google Apps</em> session. It is assumed you know server-side web development — perhaps ASP, JSP or PHP. Please note, <em>this session will be based on Python</em>. Still, it is not a programming language class — the emphasis will be on learning the available APIs which are common between Java and Python on GAE. <span style="color:#0000ff;">If you have any questions about whether you will get much out of the hackathon, please <a href="http://www.earlystageit.com/contact" target="_blank">contact us</a>.</span></p>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">Agenda</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">The idea is to familiarize everyone with the basic App Engine APIs.</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">1 hr &#8211; Getting Started &#8211; What is App Engine</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">1.5 hrs &#8211; Coding</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">15 mins &#8211; Introduction to Users API</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">1.5 hrs &#8211; Coding/lunch</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">15 mins &#8211; Introduction to UrlFetch and Mail APIs</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">1.5 hrs &#8211; Coding</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">15 mins &#8211; Introduction to Images and Memcache</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">1 hr &#8211; Coding</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">45 mins &#8211; Let attendees present the apps they worked on/wrap up</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">Prep Work</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">Attendees should plan to bring their own laptop.</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">Prior to the session, it would be helpful to have walked through the Hello World example:</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">http://code.google.com/appengine/docs/python/gettingstarted/</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">The Development Environment section of the above link suggests downloading Python 2.5 and the App Engine SDK. Please download these ahead of time.</div>
<div id="_mcePaste" style="position:absolute;left:-10000px;top:0;width:1px;height:1px;">The Download App Engine SDK page also has instructions on downloading and</div>
<p><strong>Agenda <span style="font-weight:normal;">The main goal is to familiarize everyone with the App Engine and how you can use it to build your web application &#8220;in the cloud&#8221;. </span></strong></p>
<ul>
<li>1 hr &#8211; Getting Started &#8211; What is App Engine</li>
<li>1.5 hrs &#8211; Coding</li>
<li>15 mins &#8211; Introduction to Users API</li>
<li>1.5 hrs &#8211; Coding/lunch</li>
<li>15 mins &#8211; Introduction to UrlFetch and Mail APIs</li>
<li>1.5 hrs &#8211; Coding</li>
<li>15 mins &#8211; Introduction to Images and Memcache</li>
<li>1 hr &#8211; Coding</li>
<li>45 mins &#8211; Let attendees present the apps they worked on/wrap up</li>
</ul>
<p><strong>Prep Work</strong></p>
<ul>
<li>Attendees should plan to bring their own laptop.</li>
<li>The Development Environment section of the above link suggests downloading Python 2.5 and the App Engine SDK. Please download these ahead of time.</li>
<li>The <a href="http://code.google.com/appengine/downloads.html" target="_blank">Download App Engine SDK</a> page also has instructions on downloading and setting up a development environment such as Eclipse. This is not mandatory.</li>
<li>It is helpful to have walked through the <a href="http://code.google.com/appengine/docs/python/gettingstarted/" target="_blank">Hello World example</a> ahead of time. We will be going over it again in the first couple of hours of the session so it is optional, <em>not mandatory</em>, to have done this.</li>
</ul>
<p><strong>Example Applications<span style="font-weight:normal;">. Attendees are welcome to bring their own application ideas to work on during the Hackathon. For the main example, we will work on an application in the spirit of <a href="http://www.cafesurvey.com/" target="_blank">Cafe Survey</a>. Another possibility is to create a <span style="text-decoration:underline;">wiki</span> or a <span style="text-decoration:underline;">blog</span> application.</span></strong></p>
<br />Posted in Techniques, Training Tagged: Google App Engine, Training <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/earlystageit.wordpress.com/267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/earlystageit.wordpress.com/267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/earlystageit.wordpress.com/267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/earlystageit.wordpress.com/267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/earlystageit.wordpress.com/267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/earlystageit.wordpress.com/267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/earlystageit.wordpress.com/267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/earlystageit.wordpress.com/267/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/earlystageit.wordpress.com/267/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/earlystageit.wordpress.com/267/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=267&subd=earlystageit&ref=&feed=1" />]]></content:encoded>
			<wfw:commentRss>http://blog.earlystageit.com/2009/10/14/hackathon/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">J.Singh</media:title>
		</media:content>

		<media:content url="//www.google.com/accounts/ah/appengine.jpg" medium="image">
			<media:title type="html">Google App Engine Logo</media:title>
		</media:content>
	</item>
		<item>
		<title>Cloud Development</title>
		<link>http://blog.earlystageit.com/2009/07/25/the-early-stage-it-manifesto/</link>
		<comments>http://blog.earlystageit.com/2009/07/25/the-early-stage-it-manifesto/#comments</comments>
		<pubDate>Sun, 26 Jul 2009 01:42:24 +0000</pubDate>
		<dc:creator>J</dc:creator>
				<category><![CDATA[Requirements]]></category>
		<category><![CDATA[Techniques]]></category>
		<category><![CDATA[Technology Strategy]]></category>
		<category><![CDATA[Agile Development]]></category>
		<category><![CDATA[Amazon AWS]]></category>
		<category><![CDATA[Cloud Computing]]></category>
		<category><![CDATA[Cloud Development]]></category>
		<category><![CDATA[Entrepreneurship]]></category>
		<category><![CDATA[Google App Engine]]></category>
		<category><![CDATA[Issue Tracking]]></category>
		<category><![CDATA[SaaS]]></category>
		<category><![CDATA[Source Control]]></category>

		<guid isPermaLink="false">http://earlystageit.wordpress.com/?p=209</guid>
		<description><![CDATA[What are some of the hurdles we have encountered with Cloud Development? What mechanisms have we used to overcome them? The problems posed by the different cloud platforms are different. I will be writing on this topic in a series blog posts. I expect to blog on these topics. If you know of others, please [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=209&subd=earlystageit&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<p>What are some of the hurdles we have encountered with Cloud Development? What mechanisms have we used to overcome them? The problems posed by the different cloud platforms are different. I will be writing on this topic in a series blog posts. I expect to blog on these topics. If you know of others, please let me know. These list items will get hyperlinked over time.</p>
<ol>
<li>Cloud Development for Google App Engine</li>
<li>Cloud Development for Amazon EC2</li>
<li>Managing software delivery from outsourcers</li>
<li>Managing evolution of database configurations</li>
<li><a href="http://blog.quantitecture.com/2009/02/26/trends-in-load-and-performance-testing/" target="_blank">Performance and Stress Testing</a></li>
<li>Security Testing</li>
</ol>
<p>In this introductory post, I want to cover activities that cross all platforms. The premise of Cloud Development is that the company does not own any hardware. Under these circumstances, how does software development get done?<span id="more-209"></span></p>
<p><em>Tight control over source code is essential.</em><em> </em>This need does not go away with Cloud Computing. It becomes more important! It used to be that if you lost track of the latest source, you could always look at the working machine. No longer, not consistently anyway. In the<a href="http://groups.google.com/group/google-appengine?hl=en&amp;pli=1" target="_blank"> Google App Engine support forum</a>, there is a predictable weekly request from someone or the other for Google to help them retrieve their latest source code. The answer is always the same (no, can&#8217;t be done).  The team needs to use the source repository frequently to build from.  The source repository should be backed up, versioned and secure. What should be under source control? <em>Everything! </em>That includes<span style="text-decoration:underline;"> source code</span> (duh!), <span style="text-decoration:underline;">install scripts</span> (Rightscale scripts, for example, for creating an environment), <span style="text-decoration:underline;">security settings</span>,  even <span style="text-decoration:underline;">database configurations</span>. This last item will require further discussion; more on it in a subsequent post.</p>
<p><em>The issue tracking database</em> is the team&#8217;s second most important asset, after source code. It too needs to be backed up, versioned and secure<sup>†</sup>.</p>
<hr /><sup>†</sup> Here are a couple of recommendations to &#8220;rent&#8221; source code management and issue tracking software from:  <a href="http://www.dynamsoft.com/index.aspx" target="_blank">DynamSoft</a> and <a href="https://www.projectlocker.com/" target="_blank">ProjectLocker</a>. We use the former in our practice but both come well recommended.</p>
<br />Posted in Requirements, Techniques, Technology Strategy Tagged: Agile Development, Amazon AWS, Cloud Computing, Cloud Development, Entrepreneurship, Google App Engine, Issue Tracking, SaaS, Source Control <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/earlystageit.wordpress.com/209/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/earlystageit.wordpress.com/209/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/earlystageit.wordpress.com/209/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/earlystageit.wordpress.com/209/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/earlystageit.wordpress.com/209/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/earlystageit.wordpress.com/209/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/earlystageit.wordpress.com/209/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/earlystageit.wordpress.com/209/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/earlystageit.wordpress.com/209/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/earlystageit.wordpress.com/209/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=209&subd=earlystageit&ref=&feed=1" />]]></content:encoded>
			<wfw:commentRss>http://blog.earlystageit.com/2009/07/25/the-early-stage-it-manifesto/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">J.Singh</media:title>
		</media:content>
	</item>
		<item>
		<title>Accessing Amazon Web Services from Google App Engine</title>
		<link>http://blog.earlystageit.com/2009/01/03/leveraging-the-cloud/</link>
		<comments>http://blog.earlystageit.com/2009/01/03/leveraging-the-cloud/#comments</comments>
		<pubDate>Sat, 03 Jan 2009 14:43:40 +0000</pubDate>
		<dc:creator>J</dc:creator>
				<category><![CDATA[Requirements]]></category>
		<category><![CDATA[Techniques]]></category>
		<category><![CDATA[Amazon FPS]]></category>
		<category><![CDATA[Google App Engine]]></category>

		<guid isPermaLink="false">http://earlystageit.wordpress.com/?p=61</guid>
		<description><![CDATA[Amazon.com has put together a set of services (AWS) that allow you to rent, not buy, your infrastructure. They are extremely competitive and competent. Despite the use of the word simple in the naming of these services, simple they are not. Echoing Einstein perhaps: things should be as simple as possible but no simpler. A gem: [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=61&subd=earlystageit&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<p>Amazon.com has put together a <a href="http://aws.amazon.com/" target="_blank">set of services (AWS)</a> that allow you to rent, not buy, your infrastructure. They are extremely competitive and competent. Despite the use of the word <em>simple</em> in the naming of these services, simple they are not. Echoing Einstein perhaps: <em>things should be as simple as possible but no simpler. </em></p>
<p><em><span style="font-style:normal;">A gem: Amazon knows a thing or two about payments and money transfer; no surprise that <a href="http://aws.amazon.com/fps/" target="_blank">Amazon FPS</a> (flexible payment system) should be a unique part of the offering.</span></em></p>
<p>When it comes to writing applications, <a href="http://code.google.com/appengine/docs/whatisgoogleappengine.html" target="_blank">Google App Engine (GAE)</a> is more constrained but ramp-up is easier and more amenable to agile development — a necessity for Early Stage companies.</p>
<p>How can we leverage the robustness of AWS from the simple (but constrained) environment of GAE? We tried to call FPS services from GAE to see. The remainder of this post is about tips and tricks for doing so. Fair warning, it&#8217;s a bit technical.<span id="more-61"></span></p>
<h2>Scenario</h2>
<p>We&#8217;re building a GAE application that will handle its billing and collecting through Amazon FPS, so what we really need is an interface class in GAE that would access FPS (from Google&#8217;s servers to Amazon&#8217;s).</p>
<p><a href="http://s3.amazonaws.com/awsdocs/FPS/20070108/fps-dg-20070108.pdf" target="_blank">FPS offers</a> SOAP as well as REST interfaces. REST, being closer to GAE&#8217;s <code>urlfetch</code> API, was the interface of choice. The trickiest part of the interface is secure signing of the URL. Any flaws in it and the FPS engine will give a terse &#8220;denied&#8221; message and send you back.</p>
<p>We defined an FPS class to encapsulate this behavior and all classes in our application that need to interact with FPS inherit from this class. The function <code>MakeURL()</code> returns a URL that is ready to send to Amazon. Here&#8217;s the code for the FPS class:</p>
<pre style="color:#000099;background-color:#CCCCFF;font-size:85%;">class FPS(object):
    host = '' # Populate in the derived class
    Args = {} # Dictionary. Populated with FPS parameters in the derived class
    Args['Timestamp'] = datetime.datetime.now().isoformat()
    def encode(self, aws_secret_key, str, urlencode=False):
        hm = hmac.new(aws_secret_key, str, sha).digest()
        b64_hmac = base64.encodestring(hm).strip()
        if urlencode:
            return urllib.quote_plus(b64_hmac)
        else:
            return b64_hmac

    def MakeURL(self):
        sorted_header_keys = self.Args.keys()
        sorted_header_keys.sort(key=str.lower)
        rqst = ''
        for header_key in sorted_header_keys:
            rqst += header_key + self.Args[header_key]
        encd = 'https://'+self.host+'/?'
        for header_key in sorted_header_keys:
            encd += header_key + "=%s&amp;" % urllib.quote_plus(self.Args[header_key])
        encd += 'Signature=%s' % self.encode(SECRET_AWS_KEY, rqst, True)
        return encd</pre>
<p>You will also need to import a bunch of libraries (<code>datetime base64 hmac httplib urllib re sha sys time</code>). They are all part of GAE. Everything else is part of building the application and left as an exercise for the reader.</p>
<p>Oh, and one last thing: the Getting Started Guide calls for downloading a number of artifacts (AWS Access Key ID, AWS Secret Access Key, X.509 Certificates and Private Key, and various SDK components). You will need the <span style="text-decoration:underline;">ID</span> and the <span style="text-decoration:underline;">secret key</span> but <span style="text-decoration:underline;">none of the other components</span>.</p>
<p>Copyright © 2009, J Singh</p>
<br />Posted in Requirements, Techniques Tagged: Amazon FPS, Google App Engine <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/earlystageit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/earlystageit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/earlystageit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/earlystageit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/earlystageit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/earlystageit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/earlystageit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/earlystageit.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/earlystageit.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/earlystageit.wordpress.com/61/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=61&subd=earlystageit&ref=&feed=1" />]]></content:encoded>
			<wfw:commentRss>http://blog.earlystageit.com/2009/01/03/leveraging-the-cloud/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">J.Singh</media:title>
		</media:content>
	</item>
		<item>
		<title>Building a Web Site</title>
		<link>http://blog.earlystageit.com/2008/12/15/building-a-web-site/</link>
		<comments>http://blog.earlystageit.com/2008/12/15/building-a-web-site/#comments</comments>
		<pubDate>Mon, 15 Dec 2008 17:00:38 +0000</pubDate>
		<dc:creator>J</dc:creator>
				<category><![CDATA[Techniques]]></category>
		<category><![CDATA[Building Web Applications]]></category>
		<category><![CDATA[Google App Engine]]></category>

		<guid isPermaLink="false">http://earlystageit.wordpress.com/?p=5</guid>
		<description><![CDATA[Do you want to build a web site or a web application? Alternative Methods for Building Web Sites If all you want is a web site displaying information about your company, consider these alternatives for building and hosting your web site yourself: Google Sites. Some folks consider it &#8220;simplistic&#8221; but it is sure to grow [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=5&subd=earlystageit&ref=&feed=1" />]]></description>
			<content:encoded><![CDATA[<p>Do you want to build a web <em>site</em> or a web <em>application</em>?</p>
<p><strong>Alternative Methods for Building Web Sites</strong></p>
<p>If all you want is a web site displaying information about your company, consider these alternatives for building and hosting your web site yourself:</p>
<ol>
<li><a href="http://sites.google.com/" target="_blank">Google Sites</a>. Some folks consider it &#8220;simplistic&#8221; but it is sure to grow in scope and sophistication.</li>
<li><a href="http://www.microsoft.com/smallbusiness/products/office/microsoft-office-live/default.aspx#overview" target="_blank">Microsoft Small Business</a>.</li>
<li><a href="http://webhosting.yahoo.com/ps/sb/index.php" target="_blank">Yahoo Small Business</a>.</li>
<li>A comprehensive list of <a href="http://www.thefreecountry.com/webhosting/index.shtml" target="_blank">other services</a> available.  These provide the &#8220;iron&#8221; &amp; the tools and you can build the services using standard web technologies.</li>
</ol>
<p>There are also a number of firms that will do it for you for a fee. Search for the words &#8220;website creation service&#8221;. Among the more interesting ones we found:</p>
<ol>
<li><a href="http://www.ircusa.com/InternetResourceCenter/sitepricing.html" target="_blank">IRCUSA</a>. Prices vary from $250 (1 page) to $3000 (~12 pages).</li>
<li><a href="http://www.register.com/build-a-website.rcmx" target="_blank">Register.com</a>. $12.95/month. Cheap but ugly.</li>
<li><a href="http://www.waller.co.uk/create.htm" target="_blank">Richard Waller</a>. About $1000 for a 6-page web site.</li>
<li><a href="https://www.godaddy.com/gdshop/hosting/dream_website.asp?app_hdr=&amp;ci=13611" target="_blank">GoDaddy</a>. About $65/month.</li>
</ol>
<p>(If you research any of the options further, or find an interesting new one, please post a comment and let us know. Thanks in advance.)  In any case, you will need to come up with what the web site will say, unless you want to hire a marketing company to do it with you.</p>
<h3><span id="more-5"></span>Building a web application</h3>
<p>A web application is more than a web site.  If your users log in to make purchases, to view their portfolio, to communicate with their friends, they are using an application that they interact with.</p>
<p>This post is about how to build a simple web application for not much money, using the Google App Engine.  You can build web sites using these techniques but you <em>may not</em> want the hassle.  The goal is to aquaint you with resources available on the internet for building and hosting a web application. <a href="http://www.quantitecture.com" target="_blank">Quantitecture web site</a> as well as <a href="http://www.quantitecture.com" target="_blank">Early Stage IT web site</a> were built using the techniques described here. We request that, if you build your site based on these techniques, you include a reference to this blog on your site. We can undertake custom development of features especially for your site. Please <a href="http://www.quantitecture.com/contact" target="_blank">contact us</a> to discuss details.</p>
<p>Caveat emptor. Quantitecture or Early Stage IT or the author of this blog shall not be held responsible for any expenses you incur as a result of using these techniques.</p>
<h3>Getting Started</h3>
<p>Assuming you decided you wanted maximum flexibility in building a web site and didn&#8217;t want to use one of the methods listed above, you will need:</p>
<ol>
<li>Download <a href="http://code.google.com/appengine/docs/gettingstarted/" target="_blank">Google App Engine</a>. It&#8217;s free. If you will be doing any significant programming to power your web site, best to pick up a book on Python since Google App Engine is programmed in that language.</li>
<li>This is the most formidable part of the exercise for a newbie: <a href="http://code.google.com/appengine/articles/eclipse.html" target="_blank">Downloading and configuring Eclipse</a> to use as the Integrated Development Environment. Also install &#8220;Web Development Tools&#8221; while you&#8217;re at it — they include a nice HTML editor although you won&#8217;t need most of the other components. Strictly speaking, Eclipse is optional and you can just edit the files in Notepad. Using Eclipse makes the job easier, though. It&#8217;s free.</li>
<li>A name for your site. We use <a href="http://www.godaddy.com" target="_blank">GoDaddy</a> as the domain registrar but <a href="http://www.linkedin.com/answers/technology/e-commerce/TCH_ECM/426997-399261" target="_blank">their values could compel you to look elsewhere</a>. You can type in a name and see if it is available. Try others if it is not. You can spend a lot of money on a web site name but with some creativity, you may be able to get one for $10/yr or so.</li>
<li>A logo. You will need this in GIF or JPEG formats. You can spend a lot of money on a logo. We built the <a href="http://www.quantitecture.com" target="_blank">Quantitecture</a> logo using <a href="http://googlefont.com/" target="_blank">GoogleFont</a>. It&#8217;s free.</li>
<li>A FavIcon (optional). See those little icons that show up on browser tabs? They&#8217;re FavIcons. We used Microsoft Office to create the little red Q on the Quantitecture web site and converted it to the right format using a FavIcon creation tool. We used <a href="http://www.iconico.com/colorpic/" target="_blank">ColorPic</a> to match the color of the Q to the red in our logo. It&#8217;s free.</li>
</ol>
<p>Once you have gone through Hello World example for Google App Engine, preferably using Eclipse, and tested it on your local machine, upload the code and see it run on the web.</p>
<p>This would be a good time to follow uploading instructions to connect your domain (www.example.com) to the uploaded code. The folks at Google wrote the instructions with a great deal of precision. They should be followed meticulously. They work!</p>
<p>Once you have accomplished this and can see your Hello World application connected to www.example.com, please contact us via the link on this blog. We can give you a starter set of files to get your web site off the ground.</p>
<h3>Changing the layout</h3>
<p>If you want a different layout than what our starter files give you, you can change it. The magic to controlling layout of your web site is in CSS. You will need to change the CSS that is included in the starter files. A good book on CSS is worth the investment if you will be going this route. You do not need to change the HTML if you want to change the layout. Here is a <a href="http://www.dynamicdrive.com/style/layouts/" target="_blank">web site</a> that offers many possible layouts for you to use.</p>
<h3>If you have questions</h3>
<p>Any questions should be sent by e-mail and will be responded to as time permits.  If you need a prompt response, please call us for our per-hour rates.</p>
<br />Posted in Techniques Tagged: Building Web Applications, Google App Engine <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/earlystageit.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/earlystageit.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/earlystageit.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/earlystageit.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/earlystageit.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/earlystageit.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/earlystageit.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/earlystageit.wordpress.com/5/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/earlystageit.wordpress.com/5/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/earlystageit.wordpress.com/5/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=blog.earlystageit.com&blog=5823501&post=5&subd=earlystageit&ref=&feed=1" />]]></content:encoded>
			<wfw:commentRss>http://blog.earlystageit.com/2008/12/15/building-a-web-site/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="" medium="image">
			<media:title type="html">J.Singh</media:title>
		</media:content>
	</item>
	</channel>
</rss>