OSDC, Day 3

The last day of OSDC started with Andrew Tridgell, of Samba and Rsync fame, talking about the fight with Microsoft for the protocol documentation. And, just because I wasn’t paying enough attention, I learned that it was Sun who started the request for protocol documentation, not the Samba team, although, in the end, it was only the Samba team and the FSF Europe in court with Microsoft to get the documentation. In the end, they created a foundation, Protocol Freedom Information Foundation (PFIF) to allow anyone to read those documents, which encompass more than just the SMB/CIFS protocol. Also interesting was the fact that Tridgell heard that some people inside Microsoft really wanted to make those protocols open, to prove that they were really good programmers and did not need to hide behind closed doors. The keynote ended with Tridgell pointing that Microsoft did a public release of their protocol documentation, including more protocols than the ones listed in the PFIF directory. And, because they are public now, you don’t need to be a sub-contractor of the PFIF to get the documents.

After the keynote, I went to see the Python presentations. The first one was “The State of Python” by Anthony Baxter. He spoke about the current changes in Python 3.0, which is at full swing in the news (like Reddit, Ars Technica and such) and I knew most of the changes by going to the SyPy meetings. If you’re not aware, Anthony put a collection of a few links in in a TinyURL link. The things you probably don’t know (and I wasn’t aware till I saw the presentation) is that there will be a 2.7 release in about 8 months to provide further information how to convert your applications to Python 3.0, there should be a 3.0.1 release around 6 months with bug-fixes and a 3.1 in about a year with some better standard modules (and I’m guessing it means that modules will adhere more to the PEP8.) He also mentioned that a “Programming in Python 3.0” book should be available in the US in about a month.

Still in the Python line, I went to see Michael Hudson talking about “The PyPy Project And You.” PyPy is a very interesting project but something keep me distracted enough to not take enough notes (note to self: do not open IM when in a conference.) What I noted is that they have what they call LOP architecture/problem: A language L, for an output O, for a platform P. Because of the way PyPy is designed, they can take any language L, generate an output O for a platform P in any possible combination (when they have such L, O and P, of course.) They can do what IronPython and Jython do, taking Python as a language and generating an CIL/JVM output (which are basically “platform-less”, since the VM itself doesn’t change in any platform.)

Last Python talk in the conference was Alex Holkner with “Game development with Pyglet 1.2”. My flatmate keeps talking wonders about Pyglet and, after this, I have to agree with him. The API is incredible clean and, as I’m saying recently about my small projects, it’s pretty cute (and Pyglet having way more lines of code than mine, you can be pretty sure it’s as cute as this.)

After the Python sessions, I went to see Stewart Smith talking about “LD_PRELOAD for fun and profit (or evil)”. For those that don’t know, LD_PRELOAD can be used to load libraries before the code execution, so you can, as Smith shown, create a library with redefines fsync() to not do anything. Just as an example, Smith pointed that some tests, which took around 23 minutes to complete, took only 6 with the “hacked” version of fsync(). He also demonstrated how to use LD_PRELOAD to load a library that overwrote open(), close() and the family to get a backtrace.

Jonathan Lange closed the sessions before the lightning talks with “Your code sucks and I hate you! Code review for human beings”. He spoke about the experience of the Bazaar team with code reviews, not only pointing how you could ask for code reviews when sending patches to other projects but also how to answer code sent by other people for reviewing (kinda like an “etiquette of code reviewing”.)

After the lightning talks (which I won’t say what I saw ’cause I’m still ashamed that I didn’t wrote the speakers names again), Adam Kennedy (which, yet again, I didn’t wrote down, but Slashdot saved me) took the stage to talk about “The Sekrit”. He spoke about this story with Perl, his “distribution” (I think I can call it that) “Strawberry Perl” and how he managed to make a distribution of Perl 6, which he gave to Larry Wall. Also, he told us that he was approached by a Microsoft employee asking if he needed any help. If you clicked the link above, you’ll notice that Microsoft is offering free virtual machines with almost every single supported Windows version for free for all CPAN users to test their modules.

The closing keynote was Pia Waugh talking about the OLPC-AU project. The “One Laptop Per Child” is starting its way into Australia, but Pia followed the distribution of the laptops to children around the Pacific and how kids love their laptops. For us, developers, she pointed the OLPC-Friends website, where we can help improve the OLPC “from the inside”.

And that was it for the OSDC 2008.

OSDC 2008, Day 2

The second day of OSDC started with Larry Wall, the creator of Perl. At first I thought he would ignore the elephant in the room, but all his talk was about Perl 6. He shown the parser and the weird new operators (like “»+«” and no, this is not a mistyping) which means I’ll have a harder time trying to understand Perl code. But, on the other hand, their changes on the regular expressions make them a lot easier to use and a lot more logical (well, once you understand the basics of regular expressions.)

After the opening talk, I went to see Joshua May talking about “Going mobile – tips, tricks and tools for building mobile web-apps”. He basically summarized all the things I heard the mobile developers talking in the office: It’s freaking hard to make something that would work on every mobile. WURFL is here to help with descriptions of capabilities on mobiles. Another very interesting point was the Facebook mobile application which have a special “Call” link on it, ’cause it is easier to call someone than leaving a message and he also suggested that, instead of a “Contact us” form, business should have a “Call us for suggestions” or something around those lines, ’cause, again, it’s easier to call someone and tell them about something than typing a message on a phone.

Then it was Ben Balbo with a quick demonstration of how to stream video with a talk about “Streaming the world for free”. Basically, only using free software, you have DVgrab to capture video; FFmpeg, VLC and Mencoder to encode the video; HTTP, RTSP, RTMP as streaming protocol; Darwin Streaming Server, VLC, LScube, Red5 and Helix Server as streaming server and VLC, MPlayer and Helix Player as, well, players. On a quick demonstration, he showed the stack of DVgrab, VLC, HTTP, Darwin and QuickTime Player playing a real time video using his laptop. He also demonstrated Kyte.Tv played a video capture from his mobile phone.

The third talk was Silvia Pfeiffer talking about “An open source ‘YouTube'”. The system they build for the University of Queensland uses the FedoraCommons (not to be confused with the distribution) as the archiver/storage (FedoraCommons can store a lot of stuff, like documents) and they use Fez as a front-end to retrieve that information and display it.

Following her talk, John Ferlito joined Silvia to talk about “MetaVidWiki: When you need a web video solution”, which mixes MediaWiki (Wikipedia) with video playing. They also menioned the failed attempt of the W3 Consortium of making Ogg Theora (the free media codec) the default media format for the new <video> tag in HTML 5. As a solution they presented Mv_Embed, which is a Theora-capable player that can work with MetaVidWiki to stream the videos.

After lunch, I went to see Andrew Bennetts talking about “How to make a FAST command line tool in Python” and his experiences with Bazaar. Just to demonstrate where the basic problem is, he run two commands: time python -c "", which basically runs nothing, taking 0.013ms and time python -S -c "import os; os._exit(0)", which doesn’t load the site module and forces an “unclean” exit, before the garbage collector can do anything, reducing the run time to 0.008ms. So, basically, the big culprits are imports. For that, both Bazaar and Mercurial have a “lazy import”, which is capable of doing the proper imports only when requested. Also, a lot of imports are bad right now, like String module, which imports the regular expression module, which is slow. Also, same goes to urllib, even when you just want to use the encoding stuff there (it loads the socket module, which loads the _ssl modules, which is incredible slow and large to load.) Some suggestions he gave was use PyFlakes to find unused imported modules. Later, in the questions part, I got the sad news that locally importing modules (e.g., doing import inside a function) does not improve the load speed, which means most of my new code in Mitter is bad.

Then I went to see “Managing category structures in relational databases” by Antonie Osanz. He basically explained how to use nested sets in a relational database. I saw nested trees in Uni, but I couldn’t understand how that works properly and it seems I stil can’t. But basically you keep a left and right information pointing where the element belongs in the set. It makes insert and delete slower (’cause there are more records to be updated than just one) but search is way faster (and the query is incredible simple.)

In the same database line, I went to see Jonathan Oxer talking about “Self-Healing Databases: Managing Schema Updates in the field”. His suggestion is basically never run a schema upgrade script, but you code your ORM layer to, in case of error running a query, check for probably upgrades (e.g., table creation script, column creation script), run it and then re-execute the query. Yes, you can have problems of two users trying to access your site just after an upgrade and two scripts running at the same time, but things could probably go fine if you don’t capture the error of the upgrade procedure (I’m not sure about data convertion.)

The last talk in the day was “MySQL Optimisation by design” by Arjen Lentz. He mostly talked about the good practices we usually apply. The good stuff, though, came in the little tips. For example, you can add a small C comment inside your SQL query and that comment will appear in your logs. He also suggested that you should worry about replication and write your code thinking about doing requests in a group of servers and updates in another group, so your application is ready to work in a master-slave environment (updates in the server, requests in the slaves.)

And this day I decided to stay around and see the Lightning talks. Honestly, I have a problem with 30 minutes presentations (it’s too short) and I was kinda worried about presentations in only 5 minutes. But it was, nonetheless (and yes, I love that word.) Unfortunately, I wrote the name of the presentation but forgot to write down the presenter name. Shame on me. So we had:

  • Golly, a Corwin’s Game of Life with an impressive size;
  • That joke about “if languages where cars”;
  • Faster Beer, where the presenter make use of Corepy to speed up his Pythton application (I think it was Michael Hudson, but my memory fails me here);
  • “So you’re a kick ass coder”, which pointed how we, as developers, should get more involved in the community;
  • “Ladies Get In Free” by Pamela Fox about a suggestion to bring more girls to this kind of conference;
  • “SiliconBeachAustralia.org”, a developer community;
  • “Freeway 2.0 on Zend Framework”, which I completely lost ’cause I decided to check something different (sorry about that);
  • “Counting Your Users Without Download Statistics”, which explains some tactics used to count users using surveys;
  • “SQL vs NP”, which was a really crazy talk with SQL, first making a text/ASCII-code fractal and then solving the traveler problem using just SQL and PL/SQL;
  • “Geek my ride”, presented by Jonathan Oxer showing how he did add a computer in the trunk of his car, with power source, Wi-Fi and G3;
  • “OSDcLang for Mobile Devices”, also by Jonathan Oxer, with a simple, Turin-complete, Brainf**k-like language running on mobile devices — HIS CAR! (see above)

OSDC 2008, day 1

Ok, first “real” day of the conference.

The opening keynote was made by Chris DiBona, Google open source manager and license extraordinarie (or something along those lines.) He made some points about the grown of Summer of Code in Australia (with the sad note that only 7 students registered, even with 68 tutors), the number of licenses used by Google, Google usage and contribution of open source code… And yes, suddenly, it start sounding like “Here, Google is a friend Open Source!” propaganda, but DiBona manage to point that most of what he was talking was to make a point to other companies and how they could make a step into and alongside open source. But, apart from the little propaganda side (I can guess that it was completely unintentional), the graphs he showed, like the number of students and tutors through the years of Summer of Code in Australia and the number of licenses used by Google and other small peals, where really interesting.

The first session I saw after the opening keynote was Michael Neale talking about “Rule based systems – using rules to manage business logic”, mostly because I worked with a system written in C where we had to write all the business rules and such. Well, I surely wasn’t expecting a talk about decision trees, expert systems and logical programming, but it was interesting nonetheless. The interesting bits to me were some talk about logical programming and how rule based systems approach that. Even more interesting was knowing that Clips can generate rules by analyzing other rules.

Then I went to see Nicolas Steenhout talk about “Web accessibility and Content Management Systems”, mostly ’cause I’m terrible annoyed by websites that force me to use the mouse (looong time memories of using Lynx/Links ’cause it was the only thing that run properly on Linux and because I’d like to be a “real nerd”) and ’cause I really dislike the way sites are built these days. He pointed the current state of WCAG (Web Content Accessibility Guidelines): 1.0 is too old and 2.0 is not finished yet. He also mentioned the problem that the Sydney Olympics 2000 website had due not having any accessibility (they were sued about that) and how Target was also sued for not providing accessibility in their website.

Third session was Tennessee Leeuwenburg and “Google AppEngine + ExtJS prototyping demonstration.” That was one presentation that didn’t went well. Because the wireless was down and everyone had no internet at all, there was no prototyping and, obviously, no demonstration. So we saw some nice screenshots about AppEngine and some ExtJS screenshots and… that was it. I’m pretty sure the 30 minute space to talk about a topic was also a problem.

Next was Thomas Lee and “Python Language Internals: From Source to Execution”, which was a pretty good demonstration of the Python code. And by Python code I mean the very core of Python. What he did was, using the trunk code of Python, add a new command, from the parser, to the very end of creating a bytecode for it. Really impressive and, honestly, a big surprise that Python code is clean even when it’s not written in Python (most of the changed code was C code.)

Then Andrew Bennetts and “Python’s Unittest module: an under appreciated gem”. I was expecting a lot of weird tricks with unittest, but it seems that after a whole year using it, there was nothing new I could get from it. On the other hand, I got some pretty good list of extensions for Unittest, which provide a few more things that I may use in the future. The canonical (pun intented, as you’ll see) of such extensions is in Pyunit-Friends project in Launchpad.

“Extending Nagios with Python Plugins” by Maneschi (whose name I managed to completely lose somewhere) was more about Nagios than Python which was completely my fault. Anyway, it was an interesting talk, pointing some code used to collect information to Nagios.

Lastly, I went to “Getting Your Average Joe to use Open Source Software” by Peter Serwylo. Nothing new, I know, but he pointed some “gentler” methods to make people use Open Source (like keeping the user files and such — something that I barely thought after being constantly annoyed by “technical support” calls from my parents.) I think the way he described his methods were more in the way of “show the users what they can do” than “convert them!”, which seems to be the most commom way of making people use free software.

And I completely skipped the Lightning talks, and the Dinner Keynote.

OSDC 2008, Day 0

No, I’m not using a developer’s way of counting (’cause every good language starts counting in 0, anyway — like the GPL v2 had a “rule 0”), but the first day I can’t really call it a “conference”. It was more like “Google Showing You What They Have — And helping you building stuff with that”.

They shown three of their open technologies: OpenSocial, OpenLayers and AppEngine.

OpenSocial is the API for building social network applications, something like the Facebook API for applications. Not hard, just a bunch of JavaScript commands you can use to get the current user, the
user who’s the owner of the profile, the profile information of the user looking at the page and things like that.

OpenLayers should be the API for accessing Google Maps but the really gem in the presentation was Mapstraction, a JavaScript API layer abstraction (what a mouthful) to several map providers, like Google Maps and OpenStreetMap. And, because it’s an abstraction, you can easily switch between providers without having to rewrite your whole application.

AppEngine is the famous web-app development environment that Google provides for free, unless you have a huge userbase and need more space/bandwidth. Honestly, it looks a lot like Django, except that
the configuration files are WAAAAY simpler and the API looks a little bit more logical to me: you have an URL, which points to an object, which should have a get() and a post() methods, which are called depending on the HTTP call the application received. The hard bit is the DataStore object. You create your databases model much like Django models (with a few diffrent properties) but there is no relational
references in that. Google answer is that it’s hard to keep relational data safe when you’re using a cloud and massively distributed databases and, with my experience with a simple MySQL replication I have to agree with that. So, because you don’t have relationships, you need to build things using a flat table all the time (in other words, goodbye database formal norms.) It’s a little bit tricky to get over it, but not impossible.

The coolest thing of that is that, after about 20 to 30 minutes of explanation and some URL pointing, you were given a task to build something using those tools. And you had like one hour to put something together. I failed my OpenSocial application (still want to complete that), my Maps looks a little bit cool (you can see it here) and I had some issues with that flat structure of DataStore, so I couldn’t finish my project (but I still want to complete that and put it online.)

Besides that, nothing else. But, for a “Developers” conference, it was pretty cool.