Beef up your RSS2 template for consumption with the Google Feed API Slide Show Control
There can be no doubt about it, RSS Feeds became the connecting backplane for the internet. Like Yahoo Pipes a while ago, the new Google Feed API is building its functionallity on top off standartized RSS feeds. For the feeds API, just providing a standardized RSS feed is enough to offer you a free ride. And a jolly good ride it is. The Slide Show Control is rich in features. Most major photo banks are supported and the actual controls allows for fine grained control of timings and sizes. The funny thing is, the API pretty much covers most of what we discussed at work on the friday before the weekend the API was released.
For the public timeline of our all-online-in-browser-photobooth-application foto-foo at /i-d media we wanted to add RSS feeds from which to build slide show like applications displaying a constant stream of fresh images. I decided to give it try and found this RSS2 rxml template on dzone.com which i filled with my data.
Various things happend, but no image was to be seen and the browser stalled a couple of times. First thing i found out was, “standard” Feed actually means it uses the Media RSS extension. This means the feed header has include the Media RSS namespace:
xmlns:media="http://search.yahoo.com/mrss/"
xmlns:dc="http://purl.org/dc/elements/1.1/"> which in rxml looks like:xml.rss "version" => "2.0", \
"xmlns:dc" => "http://purl.org/dc/elements/1.1/", \
"xmlns:media" => "http://search.yahoo.com/mrss/" doNext thing to do is adding a <media:group> to all the feed items: <media:group>
<media:title>"#{img.title}"</media:title>
<media:content type="#{img.type}" medium="image" url="#{img.url}"/>
<media:credit role="#{img.credit.role">#{img.credit.txt}</media:credit>
<media:description type="plain">"#{img.desc}"</media:description>
<media:keywords>"#{img.keywords}"</media:keywords>
<media:thumbnail
width="#{img.thumbnail.width" height="#{img.thumbnail.height"
url="#{img.thumbnail.url}"/>
</media:group> your media group Bonus: feed reader compliance
handling images in RSS feeds is part of the vaguely borderline of rich media feeds where things like the Media RSS extension are actually made for. For Atom it seems media handling is defined a little better but the Feed API depends on RSS2. All this variations are hard to grok for some feedreaders but I wanted to have my foto-foo RSS stream also in my Reader, but the
<description><a href='#{img.link}'><img src='#{img.url}'/></a></description>
and voila, your Slide Show complient rss image feed works equally well in your normal feed reader.i know this is all rough and dirty, but it works for me, might help you a bit, and i dont like to drown in spec reading for to long today. Find my RSS2 rxml code snippet on dzone and mess it up in any way you like.
have fun.
Technorati Tags: rss, mrss, ruby, rxml, rails, foto-foo, google-feed-api
SecondLife jetzt auch in 3D
thank good it’s friday, grossartige nachrichten fuer alle die schon immer wussten was polygone und triangle meshes sind aber sich in SecondLife wie mit auf dem Ruecken verbundenen Armen gefuehlt haben muessen. Seien wir mal ehrlich, bei aller Begeisterung darueben das 3D virtuelle Welten nun scheinbar tatsaechlich Einzug in den Mainstream halten werden(siehe Gardner Report: 80 Percent of Active Internet Users Will Have A “Second Life”), so sind wir doch alle einig das das in-world modelling von SecondLife schon immer ganz grosser Mist war. Nur jemand der vollkommen unbedarft in Sachen 3D Content Produktion war konnte wahrscheinlich ertragen sich auf das steinzeitliche Niveau des Linden Lab clients zu begeben. Alle dich kenne sind dazu auf jeden Fall viel zu verwoehnt gewesen.
Aber das koennte nun alles ganz anders werden. Angeblogged durch den wie immer gut informierten Mark Wallace werde ich mir nun sofort Sculpted Prims ansehen. Durch einen wuesten Hack, so wie das auf den ersten Blick aussieht, haben Linden Labs wohl ohne grosse vorankuendigung, quasi durch die kalte Kueche die tuer aufgemacht zu 3D Conten Produktion in vollkommen neuen dimensionen. Vieleicht war ihnen das ein bisschen peinlich? Sie verwenden die Farbkanaele aus den Texturen um darin die X,Y,Z Raumkoordinaten der Sculpted Objekte zu koodieren. Grossartig! Genau richtig so. Paul Haeberli, Miterfinder von (Open)GL hat gesagt: “hack means usefull, dirty hack means extremly useful”, genau so seh ich das auch. Und besonders amusiert war ich natuerlich auch weil mein Freund Henrik und ich, genau daselbe gamacht haben als wir in unseren Radiosity Renderer das Problem hatten dringend notwendige Informationen irgentwie in ein falsch designtes System zu quetschen das dafuer einfach nicht vorgesehen war. Aber das war bevor es das internet gab :-( daher auch mal keine links dazu. Vielicht finde ich noch ein paar Dias,
anyhow, LindenLabs rulez, yep, Ja ich denke die sind auf einem guten Weg. Klar, der client, das backend, das system, alles mist, alles schlecht designed. Egal! creativity thrieves best under contraints! BETAMAX!
und nun zurueck ans geraet.
Technorati Tags: secondlife, virtual, 3d, converter
ruby user group berlin: JRuby, YARV/1.9, omdb.de and more
We had our 2nd ruby users group berlin meeting yesterday with two speakers and the demo of the yet to be released omdb.org project.
First was Tim Lossen giving a good round-up of the JRuby developments. Not of much interest to me because i have’t touched Java in a while. There was a common understanding that JRuby is a good thing and will pave Rubys way into the enterprise world, and with Sun now as official backing partner, JRuby is heading for a 1.0 release this summer for Javaworld confererence. You can already run JRuby based Rails applications inside you IBM Websphere Application server, Yeah! But can you run a Rails application with JRuby from inside a Java applet on your client browser? Hm, interesting idea, we couldn’t answer that yesterday.
Next was the talk by Murphy about the state of the ruby 1.9 release. Murphy mainly used Mauricio Fernandez eigenclass for reference and gave a really great overview around the three main themes of this topic: Roadmap, New and changed features and performance. Everybody loves the hand drawn roadmap image(which i can’t find now) and while a Ruby2.0 release being something from a far utopian future, we might see a 1.9 release later this year. I’m actually not following the 1.9 developments but became inspired to check again. Enumerators for examples reminded me to my STL/C++ years, just now without the template pains :-) Interessting were his comments on performance. Tim already showed some charts which related the JRuby to some other implementations and Murphy made some own benchmarks which were pretty much in line with Tims data. The general information is that 1.9(==YARV) is a couple of times faster, ranging from 3 to 10 times faster. BUT! and that is a big but, Murphy did report that on the real life applications he tested, the speed-up was close to insignificant for various applications. This is because the the performance tuning in 1.9 seems to be focussing on benchmark relevant stuff. And real life application are hardly build from benchmark functionallity. This sounds like, been there, seen that before. History(benchmark tweaking) is repeating itself. For me it doesn’t matter. When others can do 4000 requests/second, ruby/rails is definitly fast enough for me.
Finally Benjamin Krause showcased his upcoming OMDB project(tech blog, development version, live). OMDB is a IMDb in wikipedia style with a creative commons licence. 16501 People(see comment) 16000 movies are already in the database and once it will open up, everybody can extend it. Thats a cool idea conceptually and what he showed technically was nothing less than the equivalent to an “Full House” in poker. For example the subsecond async response times for fetching actors from a huge database which were made possible by his ferret magic. impressive.
And this also led to the agenda for the next meeting where Benjamin will give a talk about ferret on Rails. Everybody wanted to see more of it. Also we will have a talk by Adam about AmzonWebServices: S3 and Rails on EC2 . I’m looking forward to it. And about the open mic section, i’m pretty sure we are releasing our foto-foo into the wild.
And for you to have some fun, we plan to record the talks next time and put them up as podcasts to fit with your online consumption habits. Murphy and Tim also promised to upload their talks for online viewing (to the wiki i guess).
looks like the ruby users group berlin is consolidating.
Technorati Tags: ruby, usergroup, YARV, jruby, omdb, imdb, idmedia, berlin,
bubble bursting version numbers
With all due respect,
New versioning, 0.12.2 —> 2.2.0:
is the most ridiculous version number jump i have seen i a while. Yahoo just released a new version of their Yahoo! UI Library and pull this little marketing trick.
This is even more extreme than in the good old new economy times when marketing geniuses where pushing their fail-ups towards their IPOs.
Don’t get me wrong, YUI is a fine piece of work and the yuiblog a delighting source of inspiration. But no marketing blah-blah whatsoever will make me understand the reasoning behind going from below 1.0 to 2.2 in a single step. Get real, start at 1 please.
cheers
Technorati Tags: yui, yahoo, javascript, gui, library
crontab’ed linden mania with hpricot
a kind of buzzwordy post title, i know, but hey, at least i kept the unavoidable second life out of it. For reasons far from being thrilling enough to tell here i pulled the latest hpricot release and made my server pull the latest stats from linden labs frontpage every 6 hours. I’m kind of sad I could not get it up before the (ridiculous)3293499 residents mark, but once SL will hit the billion, it will still look like a pioneer. So here is the beef: I made a cronjob screenscraping secondlife’s stats from their frontpage. A nice graph from the data i will put up soon hopefuly. And stay tuned for the raw data feed if you like. Lets see, a week i guess, before it becomes a nice exponential curve.
- get value elements from the stats div
v = Hpricot(open("http://www.secondlife.com")).search("#SL_stats strong") - make it digestible
v.map { |e| e.innerText.gsub(/[$,]/, "").to_i } - dump the stuff
# is left as an exercise to the reade
and mine you’ll get right here.
rails 1.2.1 got “Mehrwertsteuererhoehung”
Sorry for the german in the title, but i just stumbled over the coincidence of the Rails 1.2.1 release lines of code increased conforming to the german VAT update we got this januar. VAT is now 19% in Germany and ruby came from 6246 to 7428 lines of ruby code. That is an 18.924111431316 percent increase, which rounds up quite nicely to 19%. I checked against the last pre-1.2 release .
With 7428 lines of code rails still stays a lithe and lissom young framework. All the best for the REST.
cheers
Technorati Tags: rubyonrails, release, 1.2.1,
one browser to rule tham all?
huch, da hat mich dion aber erschreckt.
in a surprise move, they have created Microsoft Firefox 2007 that mimics a lot of features from Mozilla Firefox.
soweit sind wir also schon. Nach dem ersten Schreck allerdings und einem kurzen Blick über die Seite sortiert sich die Welt jedoch schnell wieder ins gewohnte.
have fun
Aus für Amateure
Die Niederländer legen die Latte mächtig hoch in Sachen Webenwicklung. Peter Paul Koch berichtet über das neue Accessebilty Gesetz in Holland. Auf Quirksmode schreibt er schon seit Jahren für geordnetet Verhältnisse im Sachen CSS, HTML und Javascript. Er war einer der ersten, bei dem ich systematische Lösungen gefunden habe, die sich wohltuend von den cut-copy-paste Orgien der unzähligen Cargo-Cult Adepten abhob.
Das Gesetz ist zwar schon seit letztem Jahr in Kraft, aber wer liest sowas denn schon? Wie kann man auch ahnen das die Leute was von ihrem Handwerk verstehen und Regeln wie die folgenden festlegen:
- valid HTML 4.01 or XHTML 1.0
- CSS and semantic HTML and separation of structure and presentation
- progressive enhancement
- the W3C DOM (instead of the old Microsoft
document.all)- meaningful values of
classandid- meaningful
altattributes on all images
Und das gilt wohlgemerkt:
As of 1 September last year, every website built for a government agency is required by law to use [die so festgelegten Regeln]
, und von denen gibt es 125! In der Konsequenz bedeutet das die Vertreibung der Armateure aus dem Geschaeft mit öffentlichen Webseiten. Zum anderen aber macht es die Produktion teurer und Regierungen sind auch nur Kunden die am Ende immer Geld sparen wollen/müssen. Da per Gesetz aber alle bestehenden Regierungsseiten bis 2011 entsprechend angepasst werden müssen entsteht auf jeden Fall ein lukrativer Markt. Auf diese Weise werden qualifizierte Leute gefördert und der gesamten Branche ein Qualifizierungsanreiz aller erster Güte gegeben. Und Qualität ist ja noch immer das beste Geschäft, PPK auf jeden Fall scheint sich zu freuen. Volkswirtschaftlich ist Qualifikation in Zeiten der Globalisierung sicher eine probates Mittel für ein an natürlichen Rohstoffen ja so reiches Land wie Holland. Davon sollte man lernen.
Und nun, wer Traute hat, der kann sich ja mal selbst versuchen. Ich weiss nicht welcher Affe mich geritten hat die full flash version der neuen Homepage meines Arbeitgebers zu checken, aber hey! Die 80% können sich sehen lassen, dass ist deutlich besser als die 58% für das Posting auf Ajaxian zu dem Artikel in Quirksmode, und das ist ja schliesslich das Zentralorgan des Web2.0.
My personal favorite: “meaningful values of class and id", ganz, ganz großartig, nachdem ich heute mal wieder rätsend darüber saß wofür wohl “pb-id” stehen mag.
cheers
Technorati Tags: accessebilty, css
ruby for system adminstrators
From the “Weichet von mir Dämonen!” department here is a little helper i found for the would-be ruby savvy system adminstraters. The Daemons ruby gem by Thomas Uehlinger is a very welcomed replacment for the shell and perl scripting mess you do for half of the day.
Daemons provides: …. scripts to be run as a daemon and to be controlled by simple start/stop/restart commands.
… run blocks of ruby code and control these processes from the main application.
…offers many advanced features like exception backtracing and logging and monitoring
…and automatic restarting of your processes if they crash.
I spread the word here as part of my ruby evangelizing efforts to bring light into your scripting hell and as maybe your first step onto the path of ruby enlightenment.
have fun
