Archive for the 'Web' Category

Page 2 of 14

Conditional GETs in App Engine

I’m currently working on an app in Google App Engine that polls feeds periodically and then does stuff with them. I suppose I could use that pubsubhubbub thingy but I have a feeling that most feeds aren’t using this yet.

Anyway, I did a quick naive implementation of polling about every hour or so. Apparently the feed parser I’m using is pretty inefficient because it’s eating up a lot of resources (relatively speaking) on App Engine. I remembered that the http protocol is pretty smart, and there’s a way to figure out if stuff has changed since the last time you grabbed it.

Google’s urlfetch doesn’t seem to support conditional GETs (someone tell me if I am wrong). I looked around and found a few tutorials on how to accomplish this in Python using urllib2. The tutorials weren’t exactly what I wanted, so I had to change a few things here or there. Here’s a snippet of code that I’m using:

import urllib2
feed = Feed.get() #my feed object has a etag, last_modified and url property
req = urllib2.Request(url)
if feed.etag:
    req.add_header("If-None-Match", feed.etag)
if feed.last_modified:
    req.add_header("If-Modified-Since", feed.last_modified)
try:
    url_handle = urllib2.urlopen(req)
    content = url_handle.read()
    headers = url_handle.info()
    feed.etag = headers.getheader("ETag")
    feed.last_modified = headers.getheader("Last-Modified")
    feed.put()
except Exception, e:
    logging.info(e) #just says 304 didn't change
    return
dostuffwith(content)

This handles my use case, which is doing work if the feed is new, and ignoring it if it hasn’t been modified. I could probably wrap this into a function that returned false if it the file hadn’t changed, and the content if it was new… Probably will do that next.

Performance vs. Brand Advertising on iAd

I’ve got some more thoughts on iAd after trying iAd out on one of my apps for about a month now.

As I noted in an earlier post, Apple responded to a really low fill rate on their iAd program by enabling developer ads. Developer ads are simple banner ads that entice a user to download an iPhone app. Here’s what the use case looks like via Business Insider:

To Apple’s credit, the workflow is actually pretty good. It doesn’t require users to leave the app to download another one.

Since developers can’t really afford the insane $2 cost per click that the big media customers pay, Apple is charging $.25 a click instead, and no cost per impression. Theoretically, this should mean that the fill rate would be very high (as long as developers are not maxing out on their daily spend limit or too aggressively filtering out apps). Yet I’ve noticed a pretty big fall in fill rate (from about 30% to 20%) in the last month.

I think the main issue is that Apple never really intended iAd to be used for performance advertising. Performance advertising is about getting that direct action (in this case, an app download). Apple’s been pushing iAd as a great Brand advertising solution (where the user is not expected to go out and buy Dove soap from their phone). That’s why the premium brands are willing to pay so much per click and impression. By comparison, AdMob ads on the iPhone seem to be more geared toward performance advertising.

By introducing developer ads, I think Apple has tried to appease publishers at the cost of the perceived premium value of iAds. Sure, the developer ads aren’t as flashy as the premium advertisers’, but $.25 versus $2 a click for the same piece of real estate is quite a difference. Add the perception that iAds for developers are not cost-effective and you could come to the conclusion that Apple is doing it wrong. It doesn’t help that the premium brand advertisers seem to be frustrated with the process of dealing with Apple as a gatekeeper.

So what can Apple do to fix this? They should go back to their specialization: doing one or a few things really well. They should focus on iAd as a brand advertising platform. They should work on getting as many large partners onto iAd as quickly as possible. This will alleviate the growing pains that publishers (including me) are feeling with fill rates. Right now it seems like Apple is reacting rather than acting; following rather than leading. They need to show that they’re serious about carving their own niche in the mobile advertising space.

What Happened to Yahoo (and What Could Happen to iAd)

I recently read an essay by Paul Graham on what happened to Yahoo. In it, he describes how Yahoo acted like a media company when it was really technology company, and how funky management made it into what it is today. One quote struck me as relevant today:

By 1998, Yahoo was the beneficiary of a de facto Ponzi scheme. Investors were excited about the Internet. One reason they were excited was Yahoo’s revenue growth. So they invested in new Internet startups. The startups then used the money to buy ads on Yahoo to get traffic. Which caused yet more revenue growth for Yahoo, and further convinced investors the Internet was worth investing in. When I realized this one day, sitting in my cubicle, I jumped up like Archimedes in his bathtub, except instead of “Eureka!” I was shouting “Sell!”

Having just integrated iAd into one of my iPhone apps I’ve noticed that pretty much all of the ads are for other apps. Most of these apps are “free,” and I assume that they could potentially be using iAd for revenue as well. This is a result of low fill rates for iAd and Apple wanting to offer developers a way to advertise their apps. It makes sense, but one has to wonder exactly where all the money is eventually going (Apple gets a 40% cut of iAd revenue), and who has the incentive to keep that system running.

A while ago I wrote my predictions for iAd. I didn’t foresee Apple opening iAds up to developers who wanted to advertise their apps. That’ll help the fill rate, but I can’t see it helping CPMs when developers have something like a $0.25 CPC and it was reported that the larger media campaigns like Dove were closer to $2 CPC. Seems like another race to the bottom, just like paid app prices.

Amazon Ad Targeting Fail: IE8

I just got this ad while shopping at Amazon. This is an ad targeting failure for a number of reasons.

  • I am using Chrome, which is better than IE8
  • I am on a MacBook Pro, which isn’t even supported by IE8
  • I was not shopping for a new browser, I was shopping for video games

I went ahead and clicked on the link for the lulz. I ended up getting to this strange terms page with a bunch of links to download the software for different (Windows) operating systems. How bad of a user experience is that!?

It appears they are after a quick buck with this “partnership” and really don’t give a crap about going about it properly. Too bad for them. At least they have an ad feedback box for me to mock them with:

Worth At Least 45 Seconds of Your Time…

Let’s see, how long has it been since I started a new blog? Probably too long ago if I can’t remember.

My mom sends me insane attachments in emails. They’re usually collections of strange pictures and drug recall warnings. I have a theory that Asian ladies communicate primarily by sending Powerpoint presentations to each other.

These emails are way too awesome to keep to myself, so I started a blog to document them. I called it “Worth 45 Seconds” because one it was included in the subject heading of one of my favorite emails. You can see that one on Worth 45 Seconds. I’ll be adding more periodically as I sift through my backlog and as my mom keeps sending me new email forwards.

Books

Hung Truong's  book recommendations, reviews, favorite quotes, book clubs, book trivia, book lists

Capitalism!