It finally happened: MP3tunes sued

Update/Disclaimer: It seems that Mp3tunes was sued as far back as November after practically poking EMI with a stick, but only now decided to ask for help. Be sceptical.

We were all scratching our heads on how Mp3tunes was pertaining to remain below the RIAA radar with such a blatant attempt to provide a service to their customers. As fate would have it, they finally got around to doing what many were expecting a long time before. Nevermind if the service is actually illegal (it does not seem to be) if others are helping the music labels make more money and/or discover their products, they deserve to be sued to oblivion!

Sometimes you have to wonder just how much more suicidal Music labels can get.

It’s not going to be a major blow to anyone in any sense of the way as a lot people were using it just as an online backup (including me) instead of an actual streaming service. Since they recently decided to stop providing free unlimited storage, the utility of it dropped like a stone.
Expect Mp3tunes to soon cave in under financial pressure and EMI to boast about a major blow or whatever.

The following is the email I received in my inbox this morning, I’m not the first to post it so you’ve probably read it elsewhere but just in case…

Dear MP3tunes Customer,

Let me start by saying that as the CEO of MP3tunes I appreciate your support over the last few years. Your suggestions and patience have helped us build the Locker system we have today. We just launched AutoSync that makes managing your music collection easier than ever.

As you may be aware, the major record label EMI has sued MP3tunes, claiming our service is illegal. You can read about the case here. Much is at stake — if you don’t have the right to store your own music online then you won’t have the right to store ebooks, videos and other digital products as well. The notion of ownership in the 21st century will evaporate. The idea of ownership is important to me and I want to make sure I have that right and my kids do too.

I would like to ask for your assistance in our battle for personal music ownership. We need your help because we are a small, 15-person company battling an international giant. They would like to make us spend all of our money paying legal bills. Here’s what you can do to help:

1) Please upgrade to a Premium account. This week MP3tunes is launching 3 service levels. I hope you will consider signing up for one of the paid levels. This will not only help us pay for the costs of our service (machines, storage and bandwidth) but a portion will go to cover our legal costs in our case with EMI.

2) If you have a chance to talk publicly about our cause on your blog, with friends, reporters or even EMI personnel please do so. MP3tunes is working hard to design a secure personal music service. We don’t promote sharing of music in any manner. We want people to legally acquire their music. But once they do, we think it’s important that you be able to use it how you want for your personal use. The AmazonMP3 store says: “You may copy, store, transfer and burn the Digital Content only for your personal, non-commercial, entertainment use.” and this is what MP3tunes allows you to do.

You have my commitment that I’ll continually battle for your right to store your music online and listen to it anywhere on any device. I hope you’ll consider helping MP3tunes in our battle. Thanks.

— Michael Robertson
CEO
MP3tunes.com

For those noot familiar with this person btw, it is the same one who in the past started my.Mp3.com which was, unsurprisingly sued back in 2000 and lost (this last bit of info taken from Crunchgear). Michael Robertson just can’t get any love from the Recording Cartel…

Damnit, gimme my extensions back!

I am wondering when are my Firefox extensions finally going to be ported to Firefox 3. Currently the recent version of my favorite browser is just so much better to use that it truly annoys me to have to make a choice between either my extensions or a faster, sleeker, sexier experience.

Yes, I can force the extensions to work but too many of them just can’t handle the awsomeness of it 🙁

So please, dear developers of firefox 2 plugins, get around to making them work with fx3. Don’t leave us hanging until after the beta versions and beyond…

Hacked Simplelife

At the request of a commenter who is also playing around with his simplelife plugin, I’m uploading my currently hacked version.

It’s not pretty so you won’t be able to change all options on the profile (only the ones included in the original) but I’ve included comments in the code so you should be able to figure out what is what.

You will need the Simplepie core WordPress plugin in order to use it.

Currently this version supports the following extras (Over the original simplelife)

In order to make it work for your own lifefeeds, you will need to edit the php code directly. You will have to edit either the ones I’ve set up (for example, change your digg username) or add your own.

To add a new feed you need to do the following

  • Add the new class for it (Defining colour, background and icon)
  • Add a new variable for the feed url
  • Add a new variable for the title that will be used in the chart. Optionaly you can set it to something specific but if you don’t want to, the script will just draw it out of the feed
  • Add a new variable for the counter.
  • Add the new feed url variable in the SimplePie array. Your new feed will need dates so don’t use something like Ponyfish.
  • Create a new if statement (just follow my comments)
  • Optionally, if you’re using getboo or something similar, add a new switch for the subtags
  • Add the title and counter variables to the chart if you want them tracked. You’re better off copy-pasting one of the current entries in the middle and pasting it below. If you copy and paste to the bottom of the chart, you’ll probably add an extra comma where you shouldn’t. Don’t forget to change the small chart as well.

If you have any questions, let me know.

PS: I am currently waiting for version 1.3 to come out so that I can merge all my changes in the new code but it seems to be taking too long. I think I might as well start beatifying it in order to upload it as standalone.

Download the hacked version of the Simplelife WordPress plugin here.

How to track anything and everything in your lifestream

Usually, most lifestream services out there only allow you to track specific places and usually these places are only the most popular like facebook, flickr, del.icio.us etc. Furthermore they only give you limited control on the look.

This is mainly the reason why I went for my own hosted lifestream. It allows me to track anything I can get a feed for as well as modify it as much as I want to look the way I want it.

However there is always the problem of how to track things that do not provide a feed of some sort. Sure, you might be able to use co.mments to track you blog comments but what if you want to log the comments you left on a forum, in a bug tracker or in a private location? How about when you need to track something completely different than that, like an email of yours to a mailing list or a new torrent you’ve uploaded?

The answer is: Simple. Bookmarking.

All you need to do is utilize an online bookmarking service like del.icio.us or getboo to tag your actions and then use the tag feeds to import them into your lifestream. Not only then can you get a feed for the various actions of yours, but if you utilize extra tags, you can categorize it further afterwards, provided your lifestream services can play with categories.

For example, I am currently bookmarking all the comments I leave on the internet and tag them as “mycomments“. If you check these bookmarks you will also see that they are further tagged as “blogcomments”, “comment_start” etc. Once a comment is tagged, Getboo provides it as a tag feed which I import into my google reader lifestream (for archiving purposes). Finally, my lifestream takes that and depending on the original tag feed the item comes from, it formats it appropriately in the list. Thus you will see all the comments use the same icon & colour while the FSD actions another. However they are both in the same service (getboo) and in the same feed (Google reader lifestream).

Not only that, but if you look deeper you will see that even items from the same source have further differences. Under the FSD class you can see items marked as “Voted Up”, “Buried” or “Commented on”. They are all however coming from the same original getboo tag feed and this is where the tags/categories of a bookmarking service come especially handy. Using the amazing capabilities of SimplePie and some newfound php knowledge I’ve cooked up a method to query the categories of each lifestream item and further format them based on what I find.

At this point, (with only free software tools mind you: getboo, wordpress, simplepie and simplelife) I have a lifestream that is much more inclusive than, I believe, any other option out there, and the capabilities I have are truly endless.

Currently, I am planning to getting logs for mailing lists, bug fixings, wiki edits and whatever else I do on the intertubes. Once everything is ready, I just need to wrap everything up and give it to you as an enhanced WordPress plugin 😉

PS: I suggest getboo throughout this article because del.icio.us is already used by many other lifestreams out there already. If you start bookmarking your actions there, you’ll get them double unless you unregister del.icio.us totally it from your service. That will mean however that your normal bookmarks won’t be tracked anymore. By using an alternative, you avoid that fate and get the best of both worlds.

Oh, and did I mention that if you really have to, you can also host your own getboo? 😉

So what are you waiting for. Start tagging 😉

Using a Google Reader as a lifestream archive

After I set up my lifestream to track a host of custom actions (like comments on other blogs, or votes on FSD) I discovered that many of the feeds I was using were having a item limit (from 10 to 20). That meant that if I made, say, 11 or more comments in various other blogs, the older ones would dissapear from the list, even if the date was still in the limit I’ve set. Only the newer 10 would always be shown and it would seem as If I made no comments below that date.

It was not a bigg issue but I really wanted it to work right so as to get a more accurate overall idea of where I am spending my time (graphs and so).

I remembered then, that Google Reader seems to always have the option to go back into older posts in the feed, up to the time that you made the subscription through it. This meant that it archives everything in that feed and stores it in its own server (Damn that Google storage is endless). Also, Google Reader has the option to put various subscriptions under a specific folder/tag, allowing you to read all the subscriptions together.

It also allows you to make that tag public. A Public tag allows anyone to see the feeds that you share through it but also gives you a feed to subscribe in turn. This feed, unlike the original ones, can provide feeds data as far back as the time you made the Google Reader subscription (and even further if someone else had subscribed to it before you, I believe). All I needed to to is append ?n=# at the end of my google reader feed where # is the number of items I want to see each time the feed is polled. (I selected 100)

So there I had it. An easy way to make an arvhive of my tracked activities without setting up my own database.

The only problem now was to make the lifestream plugin recognise from which feed in turn each item comes and then assign it the correct class. This was a more challenging question as my previous method to compare the original feed with the current item’s could not work. I discovered that I could filter by the items target link but since I wanted to use the same service to track different activites, it would always filter them the same way. In case you’re wondering, I use Getboo to bookmark pages that I commented on as well as FSD articles I’ve voted up, down or commented (Since, unfortunately, FSD does not provide such feeds by itself until now). The number of things I track through Getboo will only increase as I find more actions that don’t provide feeds.

Thus I needed some way to the original feed through my Google Reader lifestream feed.

Well, how very fortunate of me that Google Reader publishes an Atom feed and not only that but it includes the source of the original feed for your convenience. 😀

A little trial & error with the (truly excellent) SimplePie APIs, and I’d managed to find and write the code that I needed to use.


if ($feedurl == $greader_lifestream_feed) {
if ($source = $item->get_source()) {$source_url = $source->get_permalink();}
if (stripos($source_url, 'twitter') !== false) {
$class = 'twitter';
$tf_counter = $tf_counter+1;
$current_title = 'Status Update (Twitter)';
}
if (stripos($source_url, 'mycomments') !== false) {
$class = 'comments';
$extra_text = 'Commented on: ';
$getboo_comment_feed_counter = $getboo_comment_feed_counter+1;
$current_title = 'Comments Elsewhere';
}
if (stripos($source_url, 'fsd') !== false) {
$class = 'fsd';
$extra_text = 'Voted up: ';
$fsd_counter = $fsd_counter+1;
$current_title = 'Votes up on Free Software Daily Article';
}
}

And yes. I’m proud of my little code snippet. 😀

So now, if I have any feed with a sufficiently low item limit, all I need to do is subscribe to it through Google Reader and add the appropriate if statement in my plugin code and presto! Instant archiving. There is only a (very) slight problem in the sense that the lifestream update is delayed by the time it takes for google reader to refresh the original feed and then update the public tag.

All I need to do now is figure out a way to separate items in the google reader feed through the category tags that getboo provides. That would be sweet as it would cut down on line number but unfortunately the get_category() simplepie function does not seem to work as intended for me 🙁

How to hunt for WordPress performance hogs

So after my previous post on how I discovered my major causes of wordpress pain, I kept looking on what is causing my other delays. Eventually, while looking at my source code, I discovered that my wordpress page was always reporting how many SQL queries it took and how long they took to complete. Looking at the footer, this was done by this command:

<?php echo get_num_queries(); ?> queries. <?php timer_stop(1); ?> seconds

Now, I understood that this was very helpful but I couldn’t understand why it was returning a time like 10 seconds when the page was loading for 4-5. A quick google search for this code however did lead me to a page that was explaining how to Keep WordPress overhead down. Through there, I realized that those seconds were some sort of CPU time taken to draw those queries.

Through this then, I now had a semi-accurate way to monitor the impact of each plugin on my site. I only needed to figure out which parts of the site were hogging down the queries and increasing the load time.

I created a quick table in a Spreadsheet and started logging down the differences.

  • First, I made the performance text visible, so that I don’t have to look at the source code each time (You can still see it by scrolling to the bottom of the page)
  • I disabled the WP-Cache so that the queries are done every time
  • I then started disabling each plugin in turn and reloading a page. Then I compared that with the previous loading time (where the plugin was enabled.) I noted down the difference in queries and the average/approximate CPU time difference.

Unfortunately since the CPU time tended to vary from load to load, I couldn’t get an accurate number of the difference. The table I made in the end looked something like this

Plugin name Queries CPU Time Taken
Bad Behaviour 1 5
Hide Text 0 Negligible
Greeklish 0 Negligible
One click install 0 Negligible
SimplePie WordPress Plugin 4 Negligible
Security Scan 1 1

After I went through all the plugins, then I started doing the same thing with my various widgets and snippets of code in my theme that might be causing this.

Once this was done, I had one likely suspect plugin and a few widgets that were probably contributing to this slowdown. You see, my theme, a very heavily hacked HemingwayEx, was using some custom widgets in order to draw from WordPress the latest comments, recent posts and whatnot. These widgets queried the database each and every time a page would load which was quite frankly impractical.

Fortunately a short time before, I had discovered the very useful bundle of post plugins. They were also there to hunt for recent comments & posts and related posts and they also included a built-in caching mechanism! As sweet as it gets.

I quickly modified my widgets to run this code instead and the results were wonderful. By disabling also the single other plugin I found that was slowing things down, Bad Behaviour, I’ve now managed to drop the loading time considerably (or so it seems for the time being). Not only that, but I’ve managed to put a few new toys to use that do a better job than HemingwayEx’s built in functionalities.

Currently my site seems to load lightning fast compared to before but I’m not absolutely convinced this will not change once my shared hosting environment gets bogged down. Hopefully, even if that happens I will still have a much much better performance than before.

I am still stuck at around 65-80 queries per page load but I can’t figure out where they come from. I am hoping that I’ll eventually be able to trace it but for now it seems enough.

Btw, I just loved the functionality of the Post Plugins to measure their own execution time and report it back to you. This is something that all plugins should be doing in order to give the web designer an idea on what is going on with his site. I’m going to work to see if I can implement that in the Lifestream plugin I’m working on and then see if I can place it on other plugin as well.

Btw (2), Can anyone explain why more people don’t take advantage of the Plugin cache plugin? I am fairly certain that a number of heavy plugins (like Popularity contest) could make good use of it.

As always, if you have any more ideas on where to look and tweak to improve my WP performance even more, I’ll be glad to hear them (AKA Whining because no one is commenting on my blog :P).

PS: It’s a pity that I had to disable Bad Behaviour as it worked quite well until now. I also don’t like to reply too much on just a single anti-spam plugin. Unfortunately, the performance hit was undeniable and I’d rather my site doesn’t take an extra 3-4 seconds to load every time.

Squashing Wodrpess Performance Bugs

I think I’ve finally managed to trace down and smite all the things that were making my site so Gawd awfully slow. I had finally been annoyed enough by 30 sec loading times that I just had to do something about it.

Initially I thought it was with my host, and I did contact support about it via Email. They did check out the MySql slow logs and noticed some strange queries from BadBehaviour, but when this little plugin blocks around 1000 bots per week, it’s not worthwhile to disable it :).

In Dreamhosts’s opinion I should try and disable my plugins and then switch to another theme to check. Well, even though it was painful, I did it but it didn’t really make much of a difference. My site still seemed to be slow. However a test site I created had a quite normal speed. Perplexing

Initially I thought that it might just be the difference in DB size and indeed, my other WP sites, which have much less content that this, seemed to be loading faster (albeit slightly).

Fortunately a few google searches led me to some good content. Initally I discovered Firebug from a post explaining how it can help you diagnose WordPress performance issues. That was quite helpful to tell the truth. I managed to immediately spot that the WordPress Automatic Upgrade (WPAU) and the Popularity Contest were severely slowing down my Dashboard. I also found a few items in my theme that were just taking too long to load (like my FSF badge for some reason). Disabling them dropped the load time but I still had a problem.

You see, for some reason there is a 5-9 second loading time from the time I click on a link, to the time the page refreshes and starts to load. Firebug, unfortunately, will not give you any information on what is causing this, other than to tell you that the link is loading. It will not even take into account this initial loading time when giving you the total load time of the page (thus a page taking 13 secs will be reported as taking 4.5). Since this loading time dissapeared

This meant that I had no idea what was causing it, so back to the search I went. This time I managed to find a more interesting post on Improving WordPress performance which not only gave some great info, it linked to some other sources. Unfortunately, most of the tips given were to be used on a private server and were not really applicable to a shared hosting service like mine. Of course, this person was talking about receiving 500.000 hits a day, whereas I’m barely receiving 3000…a month. Still I applied the wp_config.php edit although it didn’t seem to make much of a difference.

My final hint came from wolfie who advised that I remove all widgets and links that point to other addresses as these may increase the loading time. I did that and I also took down the Popularity contest as well, just to see the results.

It seems it worked. The initial loading time has dropped to around 4-5 seconds. Although I don’t have as much bling in my site anymore, I am hoping that the increase in speed will make up for it. Unfortunately 4-5 secs is still quite bad and while I still don’t have any idea where to look in order to fix that, it’s at least better than 6-9 secs + 4 secs of extra stuff. With the WP-Cached page, the load seems to be instantanteous OTOH so at least that helps. Still for a ~100 hits per day, it certainly should not happen.

As an aftereffect, I decided to finally update this site to WP 2.5 as the functionality of Popularity contest was the only thing preventing it. At least I now have a snazzier Dashboard 🙂

After improving my performance I decided to also start a WordPress Performance page on the dreamhost service wiki. I would urge all of you, Dreamhost customers or not, to take a look and improve this page so that others that have similar issues can find a focal point to troubleshoot. I also hope to see tips specific for Dreamhost shared hosting customers eventually.

If there is a good WordPress improvement page or tips that I should check btw, feel free to let me know. Also, if you have any idea what causes these ~4 secs of initial loading delay, I would be really glad to hear it.

Charted life

I’m not the one to pat himself on the back for the smallest thing, but I must say that I feed quite proud about my latest little hack in my lifestream.

I was initially inspired by yahooza’s lifestream (via the lifestream blog) after I saw that little chart on the right side. He used the google charts API to achieve which seems quite easy to use and very impressive for online use. Thus I digged in my Simplelife plugin and started hacking around.

You can see the result below. For my limited php knowledge, this was quite a achievement 🙂

My personal pie chart

Of course the above is a static image, but within my lifestream page, this is updated dynamically every time the page loads. I like 😀

Of course, this will soon be available to you all since the Simplelife v1.4 is coming out soon and the author would like to implement some of my ideas in it.

Now all I need to do is to find a way to get the dynamic image in a format that I can put in other places without having to run the script along with it 😀