Waleed, thanks for sharing your experience. It is very useful. On 27 March 2012 11:44, Waleed Abdulla <[email protected]> wrote:
> > Waleed is the sleeping giant on this list. Every so often he steps out > of > > the shadow says something like “I made this change and it cut my > instances > > by about 450” or ... > > Haha. Having a huge monthly bill is *not* something to celebrate :) > > > > >> Waleed, we'd love to hear some war stories if you feel like writing >> about your lessons learned :-) > > > - About two years ago, the App Engine team organized a meetup for a few > early adapters to meet with the App Engine team. In one conversation with > one of the App Engine developers, he casually said: So you're using App > Engine in production?! You're very brave. I don't think I would do that. > > In hindsight, he might've been right. The App Engine was so unstable > then. I think the early-adapters had more confidence in it than it's own > developers. > > - One thing I learned the hard way was how to write code with errors in > mind. I'm sure everyone who's been on GAE for a while has learned that as > well. GAE is a distributed system and failures happen a lot. It's not a > fault in GAE, but rather the nature of distributed systems. On GAE, though, > you're running on a distributed system right from the start, not only after > your app grows. So the only responsible approach is to assume that any code > you write will sometimes crash midway. Writing idempotent code comes > naturally to me now. Learning how to order which entities to save first and > which to save last is another useful skill to reduce data inconsistencies > when the datastore times out and the rest of your function doesn't execute. > > - Recently, I've been storing structured data in single entities more > often. It's not for every case, but there are so many situations in which > the best way to store your data is to simply convert everything to a json > string and store it in a text property. And not only to cut cost, but it > actually makes a lot of sense to be able to load one entity and immediately > have a rich data structure with everything you need for that operation. I > believe the new NDB supports structured properties out of the box now. > > - It still surprises me sometimes how much can be done with so little > code. Back in 2009, Bill Katz was one of the early developers excited about > GAE. He's one of the sharpest people I've met. Among many things, he built > a full-text search > library<http://www.billkatz.com/2009/6/Simple-Full-Text-Search-for-App-Engine> > that > was simple and elegant. It supported full-text search with stemming and > multi-word searches, and it was all done in about 500 lines of code (and a > stemming library). I've been using it since and I'm very happy with it. > It's the reason I'm not too desperate for the App Engine team to launch > their long-over-due search feature. > > I'd love to hear your stories as well if anyone is interested in > sharing. > > Waleed > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > -- with regards, Maxim -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
