As I mentioned before, few hours more until Qt Developer Days 2008 at Hilton Munich Park. Feel free to contact me at ariya.hidayat@gmail.com if you are around!
/me is getting ready for the flight.
If you are a KDE contributor you can have your blog on Planet KDE. Blog content should be mostly KDE themed, English language and not liable to offend. If you have a general blog you may want to set up a tag and subscribe the feed for that tag only to Planet KDE.
To have your blog added file a bug in Bugzilla listing your name, svn account (if you have one), IRC nick (if you have one), RSS or Atom feed and what you do in KDE. Attach a photo of your face for hackergotchi.
Alternatively, Planet KDE is kept in KDE's SVN. If you have an account you can add or edit your own feed:
Planet KDE is one of the public faces of the KDE project and is read by millions of users and potential contributors. The content aggregated at Planet KDE is the opinions of its authors, but the sum of that content gives an impression of the project. Please keep in mind the following guidelines for your blog content and read the [http://www.kde.org/code-of-conduct/ KDE Code of Conduct]. The KDE project reserves the right to remove an inappropriate blog from the Planet. If that happens multiple times, the Community Working Group can be asked to consider what needs to happen to get your blog aggregated again.
If you are unsure or have queries about what is appropriate contact the KDE Community Working Group.
The majority of content in your blog should be about KDE and your work on KDE. Blog posts about personal subjects are also encouraged since Planet KDE is a chance to learn more about the developers behind KDE. However blog feeds should not be entirely personal, if in doubt set up a tag for Planet KDE and subscribe the feed from that tag so you can control what gets posted.
Posts can be positive and promote KDE, they can be constructive and lay out issues which need to be addressed, but blog feeds should not contain useless, destructive and negative material. Constructive criticism is welcome and the occasional rant is understandable, but a feed where every post is critical and negative is unsuitable. This helps to keep KDE overall a happy project.
Only have your blog on Planet KDE if you actively contribute to KDE, for example through code, user support, documentation etc.
KDE covers a wide variety of people and cultures. Profanities, prejudice, lewd comments and content likely to offend are to be avoided. Do not make personal attacks or attacks against other projects on your blog.
For further guidance on good practice see the KDE Code of Conduct.
As I mentioned before, few hours more until Qt Developer Days 2008 at Hilton Munich Park. Feel free to contact me at ariya.hidayat@gmail.com if you are around!
/me is getting ready for the flight.
I've been running KDE4 desktop since May and I've constantly suffered from poor desktop performance and various graphics card related problems. Now I've solved those problems: I've bought an ATI card. Despite NVidia releasing the new Linux driver and suggesting to tweak several performance-related configuration options, I still decided to go and spend $50 on the new video card. Here is the long story why...
On my NVidia GT8600 KDE4 had several types of performance problems:
#!/bin/bash
nvidia-settings -a InitialPixmapPlacement=2 -a GlyphCache=1
Option "PixmapCacheSize" "3000000"
Option "AllowSHMPixmaps" "0"
Option "OnDemandVBlankInterrupts" "True"
Right now Plasma can load and display MacOS Dashboard widgets .. but not all of them. If you look at the API reference from Apple you'll see that there are 6 properties (or callbacks) and 8 methods that are available in the JavaScript runtime for these widgets.
Right now Plasma implements exactly zero of them in the Dashboard ScriptEngine, causing several widgets to fail when loaded.
Implementing most of these would be pretty trivial, and they can all be done one at a time. The six properties all have equivalents in the C++, so it would just be a matter of hooking those up. The eight methods are all easily implementable using the KDE libraries and several would probably one-liners (such as the openApplication or openURL methods), the preferences flip ones would require a small amount of HTML+JS hacking to do the flip animation .. leaving just system method which likely are used for calls that don't exist outside of MacOS in many cases but which could still be provided as a JavaScript wrapper around QProcess.
Personally, I'm not overly motivated to work on this given everything else that's currently on my plate. It's one of those things that I will eventually get to because it needs to get done, but that's not overly inspiring, is it? ;)
It occurred to me that this would be a great little project with a very manageable scope, working on a very small body of code that is a plugin (so you don't need to reload the desktop as a whole or deal with long compiles) that would give immediate results and can be worked on one piece at a time to go from zero to fourteen.
If you are interested in working on this, please drop me an email or visit us in #plasma on irc and I'll get you started.
This is another post about collection backends in Amarok. The others posts explained the switch to MySQL embedded and tried to address some of the concerns. Jefferai also wrote a few things about Nepomuk in Amarok (and why it will not fully replace the sql based collections) which I want to comment on and add to.
There are user asking: “There is Nepomuk in KDE for storing meta data why the switch to MySQL embedded you could just use Nepomuk and drop sql collection all together.” With reasons like: “Nepomuk can do this and that better and one storage in KDE for everything is best.” They are not complete wrong, there are good reasons to use Nepomuk (data sharing between applications, system wide searching, using strigi(and taglib) for collection scanning at a central place for all applications once, interconnect the data with other data (like let Kmail store where I got that song from), and others)
But Jefferai is right when he says that Nepomuk can not replace the sql collection for everyone and every use case. At least not for the short and longer midterm (;-)).
Why? Not everyone will or could run Nepomuk for different reasons. The most important one: It is a quite complex big software in terms of memory usage (though I think that will improve in time and the amount of available memory in computers is growing fast) and CPU usage. Another issue is: At least in the short and midterm it it will be significant slower than the MySQL based collection. It is not useless slow but well sqlite isn’t useless slow either (faster than Nepomuk atm) and people complained. So: For slower older computers, lightweight media devices, mobile devices, big collections, java “haters” even a perfect done Nepomuk collection with a bug free Nepomuk (we are not there yet…) would be out of question.
I expect some of those issues to improve over time. (I hope we will see a faster C/C++ based storage backend for Nepomuk). But still Nepomuk is a new technology and there is not much experience with it yet amoung users, developers and important here “developing users” (those who create small scripts and apps to work on the sql data from amarok to do different things with that, mostly for their own usage).
Don’t get me wrong: I like Nepomuk and it possibilities for Amarok. It is not useless slow. In fact I am using it as my main collection backend in Amarok for months now. But it is in a similar state as KDE 4 in pre 4.0 days. You could use it but it not feature complete, it is not really stable it has its issues and there will be major changes to some of its parts. Well I hoped to have it (and the related Nepomuk service) in a better shape by now. Sorry for that, my time is very limited at the moment but work has not stopped fully and I am still planing to bring it into a useful shape.
A few words on the Nepomuk service: It will monitor Nepomuk/Strigi for new music and use taglib to read data Strigi can not read (yet?) to fill it. It then creates new music (tracks, artists and so on) resources in the Nepomuk storage. It should also inform interested applications about new music. Overall it aims to have always all music of the user in an easy to access way available for use in media players, music management applications and others.
That should make it easier (and faster!) for Amarok (and others) to use the data.
For example at the moment (ontology not final) to get a QStringList of all artists of the music on the computer in your application is as easy as (when using Strigi, Nepomuk and the unreleased service) :
QStringList artists;
QList<Nepomuk::Resource> artistsResources
= Nepomuk::ResourceManager::allResourcesOfType( "http://purl.org/ontology/mo/MusicArtist" );
foreach( Nepomuk::Resource &artistResource, artistResources)
{
artists << artistResource.label();
}
The flexible Amarok 2 collection framework will allow both (Sql and Nepomuk) collection living together at users choice and maybe in a few years Nepomuk (with faster backend?) could become the default.
Available from
http://poppler.freedesktop.org/poppler-0.10.0.tar.gz
Differences with latest stable series (0.8.7) are quite interesting, you can see them all at the Poppler 0.9 Releases list of http://poppler.freedesktop.org/releases.html.
As a summary it includes:
* Initial JavaScript support
* JPEG2000 decoder based on OpenJPEG
* Some crash fixes
* Better support of malformed files
* Some rendering improvements
So you should be all using Poppler 0.10 now to get a better PDF experience ;-)
There has been a lot of chatter lately regarding Amarok's switch to MySQL as its only SQL backend. A decent amount is FUD -- either by people simply pushing back against change, or by people that simply don't understand the decision. Some of it (particularly Adriaan's blog post) has been insightful and interesting, but miss the mark in terms of why this change was made. This post attempts to explain why this decision was made, what it really means for you the end-user, and why you should have a cup of tea and relax.
I want to point out first that I said that MySQL is going to be Amarok's only SQL backend. A2's collection system is very powerful. Just take a look at how varied music sources from Shoutcast, Jamendo, Magnatune, Ampache, MP3Tunes, as well as local sources like iPods and your local file system, are treated as equals in A2. A collection is a collection, and is limited only by what capabilities it advertises it can support (and of course, it can supply its own custom capabilities). It's not currently enabled, I don't think, but there's a Nepomuk-based collection option too. So take heart -- this change only affects Amarok's internal SQL collection, and not other sources (although those sources can store information in the SQL database if they wish to cache information).
Since I mentioned Nepomuk, it's time to discuss another common question/demand/complaint: KDE has this nice Strigi-Nepomuk thing going on...why aren't we using it for scanning music and storing information? There are a couple main reasons. The first is that Strigi and Nepomuk are optional, not required. (Update: Strigi is required, but Soprano isn't, so Nepomuk as a whole is still optional.) We can't rely on the user installing them, and even if they are installed, we can't rely on the user to configure them properly (remember that we're going cross-platform, making it even less likely). The second reason is speed: Amarok's custom collection scanner is extremely fast and pulls out specific pieces of information with TagLib. Strigi is, by comparison, very slow (it calculates hashes of all files, which means it needs to read the entire file) and pulls out less information. (Update: According to the Strigi developer, and despite what is said on kde-apps.org, Wikipedia, and even the author's own home page, it does not calculate hashes by default. So it's possible that Strigi, if properly configured, could be as fast as Amarok's internal scanner, although whether it would pull out all necessary information, I don't know. If it's configured to calculate SHA1 hashes of all files, then it will indeed be far slower.) On a local hard drive, it may not be a big issue, but it sure is a huge issue when you throw networked storage into the picture, which is a very common scenario. I've also heard, though don't remember specifics, that querying and such through Nepomuk is rather slow, compared to a normal SQL database. Regardless, though, remember that when the Nepomuk-based collection is finished, tracks sourced through a Nepomuk-based collection will have their metadata changes saved back to Nepomuk. So, it's not that the SQL collection is in place of Nepomuk -- they are entirely independent. (Update: I forgot to mention that a Nepomuk collection already exists. It was developed by a GSoCer over the summer. I'm not sure what its status is as far as making the 2.0 release, but we Amarokers both like Strigi/Nepomuk and are excited about the idea of opening up the app and having all your music available right then and there with no pre-configuration. But there is a place for the SQL collection too. As I said: they are complimentary technologies.)
With those topics out of the way, on to the meat.
First, it is important to understand an important pair of facts. Number one: we are not database guys. Sure, we can store data in them, and more or less come up with a working schema, but none of us are gurus/wizards/jedis/etc. This leads in to number two: maintaining three databases was driving us crazy. Every time a minor schema change was needed, it had to be coded up for all three types of databases. Modifying a schema could be trivial for one database type, and super difficult (or impossible) for another. People would report bugs that we couldn't reproduce, only to find out that it was because we didn't quite understand how one database or another behaved (or in some cases, none of the active devs were using that type). And so on. So from the beginning of A2 development (and in our fantasies during A1 development) we knew we wanted just one database.
(We did actually look at abstraction layers like QtSQL and others. I'm not going to comment on them much, as I didn't do the evaluation, but in general they were found to not be flexible enough to handle all of our needs without doing some custom SQL coding (especially in the cases of things like schema changes), which kind of defeats the point. If you want to know more/want to insist that they are, try asking eean, as I think he did the evaluations.)
Now we had to choose the type. At first, SQLite seemed like a good choice. Using transactions, it's decently fast. It's pretty stable (those that complain about odd MySQL bugs should talk to markey, as he, being the SQLite maintainer in 1.4, can attest that SQLite's had its fair share). However, there were a few problems that in the end knocked it out of the running. The first problem is performance. Although for people with small collections it performs fairly well, people with large collections that switched to the MySQL or PostgreSQL backends in A1 would report enormous speed gains when operations performing complex or many queries were performed, such as adding many entries to the playlist, scanning files, or filtering/searching in the collection. Since we want to accommodate users with large collections just as well as those with smaller collections, and since digital music collections aren't getting smaller, the speed increase for our users with large collections was quite important. Many of our developers, after the switch to mysqle (as we call it, though that's not the official name), have noticed huge speed increases in their day-to-day use of A2, so that speed increase is carrying through to the embedded server as well as the normal server. That was the first knock against SQLite.
The other blow for SQLite came for a totally different reason. Many users (myself included) have multiple computers sharing a single Amarok database. Assuming all the computers have access to the music at the same mount point (and a few other things are configured right), this allows you to scan once, play everywhere, update the same ratings no matter where you play it, and more. Even if your aren't sharing the database among multiple computers, many users want their database stored on a particular server for speed, security, or backup reasons. If you think either of these isn't a common use-case, you'd be quite wrong. MySQL and PostrgreSQL were quite happy with this workload. It's a total no-go for SQLite, simply because it's designed for a different purpose. So SQLite had two big knocks against it. K.O.
However, just as we can't rely on the user to set up Strigi/Nepomuk correctly, we can't rely on them to get their tables set up in MySQL or PostgreSQL. So we needed the database to be embeddable, so that it could just work for the user without any setup necessary on their part. MySQL, with libmysqld, had the seeds of this in the 4.1 series, it works decently in 5.0, and it's becoming fully supported (AFAIK) in 5.1. PostgreSQL, on the other hand, does not have any such thing. (They have an interesting and cool concept of their own of embedded SQL though. Update: apparently that is part of the SQL standard. Still pretty cool. Still totally different from what we mean when we are talking about an embedded server.)
So this leaves us with -- as you guessed -- MySQL. It may not be any particular person's favorite database (although it is for plenty), and I don't know how much overhead it really has in embedded form, but it fit the bill. It's both embeddable and can run standalone on the local or a separate machine (yes, this is not supported yet in A2, but it will be). It is fast and robust for large collections. It is well understood by the development team. And most of all, it is a single-backend solution that fills all of our needs.
If you're still unhappy about our decision, I'm sorry. We try to please most and can't please everyone. But we're the ones that develop and support this thing, and so we made a decision based both upon our needs as developers and the real-world use-cases from the collective feedback of thousands of users that have contacted us over the last few years. Please remember that even if most of the comments on the Dot, or to this post, (i.e. much of the sudden visible feedback) are from people that are unhappy with our decision, it is a decision that will actually suit the vast, vast majority of our users better than the other options we currently have.
We're a project that is known for being good to our users -- we listen to them, we try to implement features they want, try to be responsive with support. It's one of the things that got us where we are today. So please, dear readers -- put some faith in us. This has not been an easy decision -- we've discussed, we've argued, we've thrown things, we've made up, we've had an after-the-make-up orgy or two -- but in the end it's what we collectively felt was the right way to go, and we feel that, in the long run, it will make Amarok even mores awesomer. Hopefully you'll feel that way too.
MySQL is a database. I don't like it. It hurts my brain, not only because of its infamous help 'no help installed; consult help' messages. But then again I've never delved deep into database performance or use. I've always stuck with Postgres for ease of installation and configuration. So I don't have enough baggage to engage in a technical criticism of it; just somehow I don't like it.
It's also controlled by a large corporation, which gives Team FUD ample opportunity to do what it does best. I sometimes do stuff with that large corporation, so my commenting here is open to plenty of accusations of bias. I'll do so anyway.
It struck me that the recent Amarok beta announce on the Dot got no less than three comment threads about the database. So it's clearly a topic people care about, or are at least willing to get snippy about.
A lot of things in KDE need a database, in the sense of a persistent store of indexed tabular data. There's plenty of implementation options to choose from, such as an XML store, SQLite (public domain), Postgres (BSD 1-clause) and MySQL (GPLv2+BSD.sleepycat). Which things need a database? The first two that come to mind are Amarok and Kontact; Kontact is the Personal Information Management suite and it uses the desktop-independent Akonadi server as a datastore. So I'll write about Akonadi and Amarok (pur