Tag Archives: myopera

From disaster to stability: the scaling challenges of My Opera (Surge 2010)

I just read John Allspaw's blog post about his talk at Surge 2010. John's talks were among the best of the conference IMO. So I was amazed to read his post.

I was really honored to take part in this conference as speaker. Just before my proposal being accepted, I had bought the book Web Operations. When the Surge speakers list was announced, I was thrilled to discover that many contributors to the book, including Allspaw, were also speaking at Surge, and even more honored to have the privilege to being in the same group and knowing them in person.

If you're interested in the talk I presented, while the Omniti folks bring up videos and slides on the Surge website, you can download them from Slideshare:

I hope the video is delayed, so I can avoid the embarrassment for a little while :-)

A couple of bugs fixed on the varnish accept-language VCL extension

Today I received a report of a bug in how the Opera.com startup page was presented to some browsers. In particular, people with Brazilian language.

This was traced down to being a bug in the accept-language.vcl extension that we are using on both My Opera and Opera.com.

In particular, the bug had to do with static buffers being reused and overwritten during the Accept-Language string parsing, essentially due to my non-optimal C skills :) Now this bug is fixed and new test cases were added, so to hopefully avoid regressions in the future.

So now clients with Accept-Language containing strings like pt-BR, es-ca, zh-CN, etc… will be correctly recognized by the VCL code, and they will get the correct page served by varnish.

As always, thanks to Opera, the code is freely available, and I have to say it's not really experimental dangerous stuff anymore. It's been quite proven in the last few months (these few bugs excluded). At least your Varnish server shouldn't explode :-) Have fun!

embed.ly supports My Opera urls

On My Opera, we started using the OEmbed specification a long time ago. The goal was to provide an easy way to get metadata information, for example from albums or pictures. Example: given a picture URL on My Opera:

http://my.opera.com/365/albums/showpic.dml?album=2721921&picture=42077711

we wanted to give our users a way to extract metadata information about that URL in an easy way. That's what OEmbed is about. So you have the following OEmbed API url:

http://api.my.opera.com/service/oembed?url=http%3A//my.opera.com/365/albums/showpic.dml%3Falbum%3D2721921%26picture%3D42077711

and the result of an HTTP GET to that URL is:

{
   "width" : "3443",
   "author_name" : "giulia-maria",
   "author_url" : "http://my.opera.com/giulia-maria/",
   "provider_url" : "http://my.opera.com/",
   "version" : "1.0",
   "provider_name" : "My Opera Community",
   "height" : "2293",
   "url" : "http://files.myopera.com/giulia-maria/albums/2721921/DSC_5396.JPG",
   "title" : "April 27, 2010. Pink jasmine or pink lilac?",
   "type" : "photo"
}

So that gives you some useful metadata if you need to embed the picture in a page of yours, or even within a widget. Various sites have been supporting OEmbed for many years now. You can see a brief list on oembed.com. However, now there's a new service called embed.ly that works as a oembed "hub", as it transparently supports URLs from many different websites.

And that includes My Opera too! Try it here:

http://api.embed.ly/embed?url=http%3A//my.opera.com/365/albums/showpic.dml?album=2721921%26picture=42077711

or try it with your favourite site.

The MySQL Sandbox

I learned about the MySQL Sandbox last year in Lisbon for the European Perl conference. I remember I talked about it with Giuseppe Maxia, the original author. I promised him to try it.

I wasn't really convinced about it until the first time I tried it.

That was when on My Opera we switched from master-slave to master-master replication. It was during a weekend last November. I was a bit scared of doing the switch. Then I remembered about MySQL Sandbox, and I tried it on an old laptop.

I was absolutely amazed to discover that I could simulate pretty much any setup, from simple to complex, master-slave, master-master, circular multi-master, etc…
It was also very quick to setup, and it's also very fast to install new sandboxed servers.
You can setup a 5 servers replication setup in less than 30 seconds.

MySQL Sandbox is a Perl tool that you can easily install from CPAN with:

$ sudo cpan MySQL-Sandbox

You get the make_sandbox command that allows you to create new sandboxes. Right now I'm trying it again for a maintainance operation we have to do on My Opera soon. I'm using the master-master setup like this:

make_replication_sandbox --master_master --server-version=/home/cosimo/mysql/mysql-5.0.51a-....tar.gz

so I can simulate the entire operation and try to minimize the risk of messing up the production boxes while also getting a bit more confident about these procedures.

MySQL Sandbox, try it. You won't go back :-)

Just disabled Technorati ping from My Opera

I just found out that pinging Technorati atm is really slow, so I disabled this service by overriding the default production configuration.

It seems every Technorati ping took around 180 seconds, which is a bit round as number, so I guess their service is either timing out, or we started sending wrong data, or to the wrong URL, which is again weird, because we didn't change anything… :-)

Let's see tomorrow…

Improved slideshow in Dragonfruit

In the new Dragonfruit release, we also worked on an improved, or completely new, photo album slideshow functionality. This replaced our LightBox based slideshow that worked, but had some quirks here and there.

I think the new slideshow is really awesome, and if you didn't try it yet, you should try it now!.

Take a look at these albums:

by derspecht, http://my.opera.com/365/albums/slideshow/?album=704336

by AgnetaM, http://my.opera.com/365/albums/slideshow/?album=722249

And these are my own :-)

From the 365 group, http://my.opera.com/365/albums/slideshow/?album=769801

And one of my first photo albums on My Opera:

http://my.opera.com/cstrep/albums/slideshow/?album=504322