Back from Curucamp 2009
I just came home from Vienna where I attended Curucamp
2009, the probably most unconference ever. ;-)
We were about thirty people, and there was a fair share of
interesting
talks.
Of course, there was a lot of socializing, too. We had real luck with
the weather. And there even was a head measuring contest!
If you are interested in my slides about Simplicity in
Code, you can find them at the usual
place.
NP: Pearl Jam—Unthought Known
Why I use the MIT license
The internet probably is the closest thing to working anarchy mankind
ever had. I don’t want to, and I don’t see any point in restricting
other peoples’ freedom. Since 2004, I therefore license all my new
code under the terms of the MIT license or comparable licenses
(notably the Ruby license).
I do this for pragmatic reasons. I’d prefer to do it like
Bernstein, but this is
unfortunately a lot more hassle for non-private users of my software.
Using MIT is also easier than creating my own licenses.
The MIT and the ISC license fit my idea of software licensing best.
I mainly use MIT because it’s more popular and well known.
I have evaluated putting some works into the public domain (or license
them as CC0), but I can’t do
this easily for various reasons: First, I live and code in Germany,
where you can’t place things into the public domain without already
being dead for a long time. Second, I do not want to give up all my
moral rights, because then the code can actually be used against
myself (mainly “any distortion, mutilation or other modification of,
or other derogatory action in relation to the said work”, I don’t care
about the rest). I do not know if this matters in real life, and I
hope it does it not, but I don’t want to risk it. (Still, I think CC0
is the most important recent addition to the license landscape.)
(In general, I’d even prefer if my code was regarded
authorless—which does not mean I don’t care about it. But neither I
don’t care at all what you do with the code, and I’ll not endorse it
nor want to be identified with it in other ways—especially if you
distribute modified copies! I’ve been considering anonymous or
pseudonymous releases for these reasons. Again, pragmatism strikes:
apart from murky and inconvenient ways to release and ensure archival,
it is problematic for others that depend on the legal system to use my
works.)
I consider it unfortunate that we spend so much energy on licensing
debates, clarification of terms and persecution of violation. Rather,
let’s code. As long as there is a single available copy of free code,
its freedom is kept and can be multiplied at no cost. For code that
is worth anything, it will.
I realize “bad guys” don’t cease to exist—whether they “steal”,
don’t share, lock up code, or have business models in mind you don’t
like. But it’s not my fault they are that way, and neither it is my
job to “teach them lessons”. Good deeds have to come from yourself,
and why should I not give anyone the possibility to do so.
Thus, more power to you! Now go forth and do whatever you think is
right.
NP: Danger Mouse—Revenge
Devil's RailsConf 2009 Dictionary
[This seems to be an appropriate literary device to reconstruct an event
which makes it hard to remember in which order things happened. Also,
it’s easy to be silent on certain things I have nothing
to say of
as well as just rant a bit here and there.]
⁂
888 Noodle Bar:
has good and comparatively cheap lunch at ☞Las Vegas Hilton.
A Hat Full of Tricks with Sinatra:
Blake Mizerany shows how to make a really good tutorial:
By knowing your stuff well and being an eloquent speaker, you can
nicely adapt to the speed of the audience. No preparation required.
Barry Manilow:
the superstar of ☞Las Vegas Hilton.
Use Barry Manilow
key cards to open your door.
Buy Barry Manilow water and Barry
Manilow energy drinks at the hotel’s own Barry Manilow shop.
Bellagio:
less tasteless hotel with a nice buffet and fountains.
Box Lunch:
euphemism for serving cold sandwiches every day.
CabooseConf:
a room where people read their email.
Carpet:
The only thing not carpeted in ☞Las Vegas are the roads. One wonders
why.
Continental Breakfast:
euphemism for toasted bagels and cream, along with
empty coffee containers.
Envy:
excellect place to have Steaks at.
Keynote:
Chris Wanstrath’s
keynote reads so well
I regret having missed it.
Las Vegas:
The paradise of ADHD patients, the land where neon grows
outside, the most tasteless city of the world. Not found here: dogs,
birds and people reading books. Also, anything to not make you spend
money.
Las Vegas Hilton:
an off-strip hotel with that vintage 80’s porn feeling that the
eponymous daughter lacks. Full of ☞Barry Manilow.
Mist:
Place to be smoking a
hookah if you need
to wake up 6 hours later to get your flight.
Nobu:
excellent place to have Sushi at. It was just perfect.
Rack:
the hottest thing at the Conference. Not these. Really, I didn’t see a single
talk that did not mention Rack.
Rails 3 and the Real Secret to High Productivity:
DHH makes me go “I told you so” non-stop for an hour.
Rails Core Panel:
Are you guys letting Yehuda turn Rails into Drupal?
SOCKS over SSH:
Way to surf when the Conference ☞WiFi HTTP proxy goes down. On one
occasion I had 500kb/s for myself.
Sexy Blackjack:
good luck trying to find it in ☞Las Vegas.
Smacking Git Around – Advanced Git Tricks:
Scott Chacon shows how to make a fast-paced and really comprehensive
presentation where everyone can learn something.
SpaceQuest Bar:
at the heart of ☞Las Vegas Hilton, this is where I made $123.50 out of $7.50
with Video Poker.
Speakers Lounge:
a room where people read their email, not
always out of coffee.
Superbook Deli:
serves ice cream at 4am, just in time when you return from downtown ☞Las Vegas
after a few bottles of Jägermeister and ☞Sexy Blackjack.
Tempo:
Bar at ☞Las Vegas Hilton that serves a nice Old Fashioned.
The 4-hour Workweek:
EPIC FAIL by Timothy Ferriss.
I wish I logged #railsconf during
that talk, it was the best part (mail me your logs, if you have them, please).
The GitHub Panel:
best panel, all questions answered (and pre-collected) and fun to listen to.
What Killed Smalltalk Could Kill Ruby Too:
Finally a good (standing-ovation!) keynote, by Robert Martin.
Even if I don’t agree with all points, allowing to make a mess easily
is a problem in most languages I like.
What Makes Ruby Go: An Implementation Primer:
Charles Nutter and Evan Phoenix go into relevant implementation details
and lighten a few dark corners: Who knew super was that weird?
WiFi:
inexistant for free outside, and highly limited at the Conference.
(Seriously, if you do a tech conference for over 1000 people, why do
you only get a 20mbit line?!)
⁂
Finally, I’d like to tell everyone at the conference, whether they
paid lunch, dinner, drinks or the whole trip as well as everyone I
spent nice hours with: thank you very very much! I had a great time,
and I’m looking forward to meet you at a less crazy place.
NP: Sheryl Crow—Leaving Las Vegas
Off to RailsConf 2009
Tomorrow I’m flying to Las Vegas to attend
RailsConf 2009.
If you’d like to meet up, feel free to
contact me.
Also, you should visit the panel I’ll speak at: Tuesday, May 5th,
2009: The Future of Deployment,
“This panel is a chance to get forward thinkers from all the different
parts of the Ruby web stack in one room.”
There likely will be a Rack hackfest (half the core team is there),
maybe as part of
CabooseConf
or even more informally. Stay tuned and watch out for tweets.
NP: Bob Dylan—It’s All Good
Rack 1.0 has been released!
Today we are proud to release Rack 1.0, which was close to almost be
codenamed MiddleWarem4Ever.
See the full release announcement with change log.
Thanks to everyone that helped development!
NP: Bob Dylan—Chimes Of Freedom
Upcoming talks
It’s kind of conference season again! You can see me speaking at
these events:
I’m looking forward to meet you at these events.
All material will be posted on my talks page of course.
NP: De los Muertos—This Changes Everything
Review: Lighttpd
Lighttpd
by Andre Bogus.
Packt Publishing, Birmingham 2008.
223 pages.
[Full disclosure: I have received a copy of the book in exchange for
this review.]
The web server Lighttpd has become rather
popular in the last few years and thus it was just a matter of time
someone wrote a book about it. Packt published Andre Bogus’ book in
October 2008. I review the first edition.
After a short overview of what Lighttpd is, the book starts with a
chapter about installing Lighttpd. It is fairly detailed and contains
installation instructions for many Linux distributions as well as how
to install from source. It explains which configure options there are
and which dependencies one needs to take care of.
Chapter 2 deals with basic setup of Lighttpd. After a quick overview
of how to run Lighttpd the book dives into the configuration files.
This chapter includes a short tutorial into regular expressions (PCRE
style) as well as they are essential for rewriting/redirecting URLs
and configuring specific parts of your site.
Chapter 3 explains how to set up CGI and virtual hosts. It gives an
overview of the three modules for virtual hosting and explains how to
use each one (mod_simple_vhost, mod_evhost, mod_mysqlvhost).
Then, it shows how to setup and configure CGI, FastCGI and SCGI
backends. While the setup is explained pretty well, I missed a
section on debugging CGI, especially since this can be quite tricky at
times. While not really part of Lighttpd, I’d also have expected a
quick explanation on how to setup virtual hosts in the domain name
system.
Chapter 4 is about serving and streaming static files, a task which
Lighttpd really was made for. Traffic shaping, securing downloads
with tokens and FLV streaming are addressed here.
Chapter 5 explains logging and log formatting as well as user
tracking. Again, it would have been nice to mention more tools:
there is a whole section on click stream tracking but the reader wont
learn about any tool he can use to make sense of this data.
The next chapters are about security:
Chapter 6 shows how to setup SSL with self-signed keys, an own CA, or
by buying a certificate. This chapter is a bit too short and doesn’t
detail debugging SSL, either.
Chapter 7 tells how to secure parts of the site with passwords and the
various authentication backends as well as how to avoid DDOS attacks
by using mod_evasive.
Chapter 8 explains how to run Lighttpd in a chroot, possibly separated
from the backends.
Chapter 9 is about optimizing Lighttpd. The author uses http_load
to benchmark the web server and shows a few options that can be
configured in Lighttpd and the underlying OS (Linux and BSD are
addressed) to make it faster. Elementary caching is explained as
well. This chapter ends with an rather useless section on how to
profile Lighttpd with gprof but doesn’t explain how this would help
you to speed up your web server.
Chapter 10 (available
online)
is about migration from Apache. The reader should have no problems
moving simple to medium complex Apache setups to Lighttpd, given that
he can workaround the lack of .htaccess in Lighttpd. This section
also tells how to use Lighttpd as a reverse proxy to forward requests
it cannot (yet) take care of to different web servers.
Chapter 11 shows how to setup a few common web applications: Ruby on
Rails with mod_fastcgi, Wordpress, phpMyAdmin, MediaWiki, Trac,
AWStats and AjaxTerm. Apart from the last, they all use
mod_fastcgi, which makes this chapter not very exciting.
Chapter 12 and 13 contain really original content that is not found
easily on the net: Extending Lighttpd with Lua scripts (Chapter 12)
and with C modules (Chapter 13). The author gives a short
introduction to Lua and provides a few examples of using it to script Lua
with mod_magnet: a random file server and a shoutbox are
implemented. Chapter 13 introduces the Lighttpd API and shows how to
write the random file server as a Lighttpd module. There also is an
example of a module that adds proper doctypes to HTML pages.
The book concludes with an overview of HTTP status codes and a list of
all Lighttpd configuration options.
Conclusion: The book is pretty compact and therefore occasionally too shallow.
But it is well researched (I found no serious technical errors and
just the few typographical goofs that are especially annoying in
source code but seem to be unavoidable in modern technical books) and
documents all aspects of the actual Lighttpd configuration. It
includes many well-commented examples and code snippets. I would have
wished it provided more detail on debugging configurations, setting up
web servers beyond the actual Lighttpd configuration and modern
application deployment (reverse proxying, load balancing…). Also,
I found the index of the book rather lacking (for example, there is no
mention of “Content type” in it). The stressed administrator may
rather straight turn to Google or the Lighttpd wiki (which explains
all options as well) than trying to find them in the book. Last but
not least, I’d like to remark that the book is part of the “Packt Open
Source Project Royalties” and the Lighttpd project gets “some of the
money” Packt makes from each sale.
I can recommend the book to administrators and web developers that are
new to Lighttpd but already have some experience in setting up web
servers/web applications and who would like to get a good overview
of the possibilities Lighttpd provides. Due to the last two chapters,
the book also can be interesting for people that want to extend Lighttpd.
Rating: 4 of 5 points.
NP: Crash Worship—Bajo la Piel
A RailsConf Europe 2008 diary... NOT
Around RailsConf Europe in six words.
Sunday: Arrival by train, St. Oberholz.
Then All-you-can-eat, Tacheles top floor. Yay.
Monday: St. Oberholz, Bratwurst on Rails.
Taught Geoffrey how to use zsh.
Tuesday: Vietnamese dinner with Sean O’Halpin.
Then RejectConf at Pirate Cove (Arr!),
Then to Ambulance Bar and Tacheles Garden.
To bed at about 5 am.
Wednesday: Deutsches Technikmuseum, dinner at Marx.
Then Ambulance Bar, Tacheles first floor.
To bed at about 6 am.
Thursday: Dinner at the Ständige Vertretung.
Then Ambulance Bar (See the pattern?).
Friday: Flight home, way too early.
Thanks and greetings wholeheartedly go to:
Scholle5 for the apartment and WiFi,
Members of #caboose I stayed with,
for the good time and community,
Geoffrey Grosenbach for his unhidden praise,
Sean O’Healpin for dinner and beer,
All barkeepers in previously mentioned places,
Yikes, I accidentally my whole fleshlight!
See you all in near future.
Almost overheard: Rails is getting stale.
NP: Queen Adreena—Princess Carwash
Off to Berlin
Busy packing my stuff to travel to
Berlin where I’ll play lobbyist at
RailsConf Europe 2008
(i.e. I don’t have a ticket.)
Please contact me if you want to
meet up, I’m there until early Friday morning and have lots of free
time.
I’ll be taking my EEE PC with me, so
mail and IRC ought to be available, given I find some free WLAN
(no deal).
I’m staying with Jarkko Laine,
Cristi Balan,
Andrei Bocan,
Manfred Stienstra,
Eloy Duran, and Lars Pind. Gonna have a good time.
Anarchaia will resume publishing Friday, September 5.
NP: Queen Adreena—Medicine Jar
Taming $RUBYLIB with the Z shell
Ok, I’m fed up. Writing a good package manager for Ruby is a fight
against windmills.
So let’s do the easiest thing that could possibly work. Redefining
Kernel#require is a no-go, for it will lead to the gates of
hell.
Installing multiple projects to the same location is error-prone,
requires non-trivial amounts of code and introduces packaging effort.
Luckily, most packages these days run directly from a checkout or
their released archives (and if you provide neither, you’re doing it
wrong).
Essentially, all you need to make it convenient setting and
manipulating $RUBYLIB, “A colon-separated list of directories that
are added to Ruby’s library load path ($:).” The Z shell
(1,
2) to the
rescue!
Add this to your .zshrc (or .zshenv, if you want it in non-interactive
shells as well):
# unique, exported, tied array of $rubylib to colon-seperated $RUBYLIB
# 08aug2008 +chris+
typeset -T -U -gx -a RUBYLIB rubylib ':'
rubylib-add() { rubylib+=("$@") }
rubylib-del() { for i ("$@") { rubylib[(r)$i]=() } }
rubylib-reset() { rubylib=(); [[ -f ~/.rubylib ]] && source ~/.rubylib }
rubylib-reset
This creates a zsh array rubylib which value reflects $RUBYLIB and
vice versa (zsh does the same for $PATH and $MANPATH, for example),
and defines three functions to add and remove paths as well as reset
the variable.
Also, create a file ~/.rubylib where you set the defaults.
I simply use:
rubylib-add ~/projects/{testspec,bacon,rack}/lib
rubylib-add ~/src/{camping,markaby}/lib
Remember, you can use the full power of zsh to set this:
rubylib-add ~/src/rubystuff/*/(lib|ext)(/)
You need to use (x|y) instead of {x,y} here to only expand to
existing files. The final (/) ensures these files really are directories.
Reload your .zshrc, and voila, your packages are accessible from every
Ruby script. Now, if a project has different requirements, just
create a script there to adjust $RUBYLIB. Or use vared to
interactively change the load path.
[Thanks to et for improving rubylib-del.]
NP: Curve—Dirty High
Review: Practical REST on Rails 2 Projects
Practical REST on Rails 2 Projects
by Ben Scofield.
Apress, Berkeley 2008.
284 pages.
[Full disclosure: I have received a copy of the book in exchange for this review.]
The book, targeted at intermediate and advanced Rails users, starts
with a chapter “Why REST?” that tries to explain how REST helps
interconnect applications and reflects the structure of the web.
As examples for such connectivity a few mashups are presented.
The author states that APIs can make web applications much
more useful and interesting, but costly to develop. He contrasts
REST with XML-RPC and SOAP. Finally, the basics of REST are outlined:
It is a client/server architecture based on stateless requests that
describe and transform resource representations. The author argues
that REST makes it easier to develop clients and servers and extend
these applications in the future, last but not the least because
REST is implemented well in Rails 2.
After demonstrating the use of (deprecated) ActiveWebService, the
author shows how these ideas are expressed nowadays in Rails 2,
outlining the history of simply_restful. He continues by
explaining the new styles of URI routing that also dispatch on the HTTP
method like map.resources/map.resource/nesting and map.namespace.
The author also addresses Rails’ support for multiple
output formats and new helpers related to routing. Scaffolding is
discussed and will be used in the book. At last, there is a mention
of ActiveResource to use RESTful Rails applications together.
The third chapter develops the main application of the book dubbed
MovieList. It is used throughout the rest of the book. MovieList, a
site that informs about movies and their releases, lets users express
their interests and displays when new movies with the same actors are
released. The code is not developed test-first, but the downloadable
code contains a test suite. Occasionally the code is
pretty weird, for example it defines setters that are merely
called for their side-effects using #update_attributes. In some
places, explicit iteration over ActiveRecords would have been solved
better by doing it in the database. Also, the generated HTML is
partly unsemantic and hard to scrape (which is not that bad if the
data can be reached by the API, you may argue). The author explicitly
defines notifications and interests for the movies to belong to the
logged-in singleton user (they reside at /user/interests, not
/users/:id/interests), supposedly so one cannot see other people’s
interests. In later chapters, he decides however to at least revert
this for notifications—it would have been better to properly design
it in first place, as it actually is a nice feature and more RESTful
anyway (can you speak of “current users” in a stateless request,
really?) and show how to protect the page for users that don’t want to
allow it to be seen. The author mentions at the end of the chapter
that a “great deal of planning, testing and other work has gone
undescribed”; wouldn’t it have been useful to have these parts in the
book as well? The actual architectural concerns of REST applications
are not really mentioned in the book.
The next four chapters deal with accessing the MovieList applications
from other technology. Chapter 4 uses JavaScript to provide a
widget users can embed on their homepage and shows how to do
full-fledged access to the application using AJAX after extending it
to support JSON. Chapter 5 shows how to access the site using the PHP
framework Squidoo. During this, a feature is added to allow users to
display the movie releases within a time frame. This is the code used
to parse the relative time, and I’m not kidding:
raw_time = params[:time] || '1 month'
time = eval("#{raw_time.sub(/ /, '.')}.from_now")
How this gaping remote code injection hole passed any kind of
technical review is a miracle to me. Ironically, the next
section is called “Injection Flaws”, and addresses SQL injection and
so-called “HTML injection”, which actually is passing anything you
want as parameters. The author then decides to “fix” it by checking
the time parameter in the PHP script calling the Rails application. Duh.
Chapter 6 builds an client for the iPhone, optimized to its interface
constraints: a small screen, popup keyboard and lower bandwidth. It
uses the commonly used approach of defining a new Rails format that is
triggered by a special subdomain or by user agent sniffing.
The chapter shows how to use iUI to make the interface look
native, too.
Chapter 7 shows how to embed the application to Facebook either by
using iframes or the FBML. I have no idea how the contents of this
chapter are related to REST, especially since the FBML approach
actually calls everything using POST.
Chapter 8 is called “Dealing with success” and is about making the
application faster and more robust. Apart from the classic caching
approaches (which work very well in REST due to the idempotency of
GET, but see below) and foreshadows of denormalization,
it contains a few general hints on Rails and database performance. It
also addresses throttling access to the API by using API keys
and setting up auditing to monitor the site.
Finally, Chapter 9 tries to place “Rails in the enterprise” and
explains the chances, but also the problems of REST and Rails in the
enterprise. It contains a small example of how to create a RESTful
interface for a SOAP backend.
Conclusion:
Generally, I found the book lacking. Instead of shifting focus to the
design and architecture of real-world REST applications and showing up
the patterns that can be used to help development, the book shows how to
combine a simple CRUD application with half a dozen of buzzword loaded
Web 2.0 stuff. The semantics of REST are only half-heartedly addressed
(a third of page 13 discusses what the HTTP methods mean),
the idempotency of GET merely assumed (it’s actually in a
parenthesized half-sentence on page 72), and the actual means of
applying REST (proper status codes, correct/multiple content types)
are not made explicit. Instead of wasting over 15 pages on
screenshots unrelated(!) to the application and another 2 pages on
showing a WSDL that is very much useless, the reader would have
had more benefit from a table of HTTP status codes and content types.
Also, writing a REST client in Ruby is not addressed by means other
than (the limited, non-general) ActiveResource.
I think this sounded too negative, please bear with me:
The book is okay. It’s well written, and if you like a whirlwind tour
of Web 2.0 things one can do it’s a good read. It’s just not really
about REST, or at least not what I’d expect of a book about REST.
Rating: 3.5 of 5 points.
NP: Dandi Wind—Hostages
Workshop on Self-sustaining Systems 2008
These are my personal notes from the Workshop on Self-sustaining
Systems (S3).
[A quick note beforehand: The descriptions make use of a metric called
“lines of code” (LOC), which widely is regarded as being insufficient
for measuring program size. Due to lack of better means, I decided to
mention them nevertheless. Take them with a grain of salt.]
The conference started after lunch, but we got there earlier so we had
the chance to socialize with the HPI
people already.
⁂
Ian Piumarta gave the first invited talk on his
Late-bound lambda object architecture, wherein he decided to fight the fact
that software tends to become too complex by finding out how much you
can say with how little. He started by contrasting the three cubic
miles of paper that is the US case law to Maxwell’s four tiny
equations which are able to fully explain all electromagnetic
phenomena.
Moving to software, he showed the source code line counts of some
popular projects, and we could see, for example, that OpenOffice.org
has more lines of code than the entire FreeBSD operating system.
Comparing lines of code with the size of literary categories, he
decided that 20kLOC, which roughly resemble a 400 page roman, are the
maximum size of a program a programmer has the chance of fully
understanding.
He continued explaining how it is possible to get much done in such
a limited amount of code by showing off how simple things like shape
rendering, which only consists of a few elementary transformations, is
enough to render fonts and essentially provide a full graphical
interaction system.
He gave a quick tour of other interesting ideas to be further
investigated, such as multiple subjective perspectives, which result
from the realization that objects have several roles, or regarding
computation as “fields” (re)acting on particles, a concept which makes
it easy to specify complex interactions between many objects.
Since predicting anything is difficult, he argues that it highly
important to be as dynamic as possible, by using the fewest minimal
abstractions that allow for any possible feature/paradigm to be added
to the language/system.
His design combines functions and objects into the foundation of his
system, COLA. Functions,
represented as s-expressions provide the proto-behavior, while
proto-structure expresses form by providing objects that messages are
sent to. They provide the dichotomic base, since without
function, form cannot be animated while function has no representation
without form. This results in a self-describing structure.
(Actually, after the talk he told me they are trying to unify
functions and objects into one thing, I’m very curious about the
result.)
His talk was larded with memorable insight such as looking at GTK+ and
noticing “C is highly deficient and wasteful” or encouraging the
students to look at the “old” papers where technology was severely
limited because “sometimes progress is behind you”.
⁂
The next talk was by Christophe Rhodes, who spoke on
SBCL – A sanely bootstrappable Common Lisp. After a short overview
of Common Lisp, he summarized the history of
SBCL, which started as a fork of CMUCL in 1998.
The main reason of the fork was that CMUCL was horrible to
bootstrap and it actually wasn’t possible to compile CMUCL without
already having the last version of CMUCL before that.
Christophe Rhodes emphasized the importance of a system being able to
rebuilt itself from a “blueprint” since it makes the result a lot
clearer, easier and predictable. He showed an example of a bug in a
core data structure which was easily fixed by changing the structure
and recompiling the system—without the ability to rebuilt from
scratch, magic hackery would have been required to modify the existing
structures to be compatible enough until they could replace
themselves.
SBCL nowadays can be compiled using half a dozen of different CL
implementations and does, once built, not any dependencies on the build
environment.
This unusual level of self-sustainability has many benefits: it is
more fun, enables quicker turnaround, makes the system more
future-proof, and doesn’t limit improving the core of the system to
hackers with magic abilities. Instead, every developer can work on
the code because in the end it’s just another big Lisp program.
Because of this, more people can help with the system and maintain it,
thereby having more control over the destiny of the system as a whole.
⁂
Charlotte Heerzel was the next, presenting
Reflection for the masses, in which she showed how to implement
3-Lisp
using CLOS. She noticed that programming languages are made powerful
by abstractions, but there are cases where one wants to get rid of
them, for example if you need access to the current continuation.
Reflexive languages, on the other hand, allow the programmer to
control internalization, normalization, and externalization within the
language.
She showed lots of code, implementing a small Lisp interpreter in CPS
and then adding structural reflection by exposing the internal data
structures as abstract data types and behavioral reflection by
introducing reflective-lambda, which has access to the current
continuation, environment and code. For example, this allows to
implement when as a first-class function.
⁂
The first day ended with two social events: first, there was a boat
trip around Potsdam, where I had the great luck to sit on a table next
to Richard P. Gabriel and Pascal Constanza. We had a long interesting
discussion with them about the lack of (helpful?) limitations in
programming, what designers really do, how Java became popular, the
danger of the obvious and demonising copy and paste programming. I
learned one thing about how rpg decides which poems to publish, which
I cannot keep back:
Richard P. Gabriel writes a poem each
day, and once a year, he needs
to select six of them for publishing (six seems to be the usual amount
the publisher wants). So how does he do it? Using a computer, he
randomly picks sets of six, until all of them don’t suck. Then he
sits down and revises them.
We crystallized this as the essence of design: to choose the things
that don’t suck.
Afterwards, we had a dinner buffet on a restaurant boat until night.
⁂
The next day started with Daniel H. H. Ingalls (say it in German!)
demonstrating The Lively Kernel – a self-supporting system on a web pagex.
He admitted that web programming is complicated, but
implementing Morphic in JavaScript seemed like an easy thing to do.
While he explicitly mentioned that he is not proud of the code, he
thinks it’s easy enough and works well.
The whole Lively Kernel is
rendered using dynamically generated SVG and doesn’t include any
(visible) HTML at all. All drawn stuff are vector objects. In good
Smalltalky manner, the system uses MVC extensively.
After a short demonstration with some turtle graphics and live-code
editing, he pointed out some of the non-obvious features of it: For
example, to support multiple people working on it, they introduced a
change-set format for JavaScript which allows to check in modified
parts of the system into version control. Also, they have a pretty
sophisticated system for profiling by dynamic method rewriting to
insert measuring code.
The whole Lively system at the moment is a mere 10kLOC of JavaScript
and already includes many details such as rich-text-boxes.
On the topic of security, Dan Ingalls proclaimed that his security
philosophy was like this: “Make it work, then make it secure,
and I hope someone else does step 2.”
⁂
Carl Friedrich Bolz presented a joint-work of eight Pythonists and
Squeakers titled
Back to the future in one week – Implementing a Smalltalk VM in PyPy
which they started in October during a five day
sprint.
PyPy, initially a
Python implementation in Python, but now moving towards a general
compiler tool-chain, enables one to write highly flexible language
implementations because most things are late-bound. Therefore,
garbage collection, object layout and the threading system can be
exchanged easily and allow for lots of experimentation. PyPy aims to
autogenerate dynamic compilers from interpreters written in a reduced
set of Python called RPython with nevertheless allows full-fledged
compile time metaprogramming.
They already implemented all Squeak bytecodes and most of the
primitives. The resulting system,
SPy, can load unmodified Squeak
images and run simple benchmarks. It is roughly 10x slower than
Squeak itself, and they plan to support the graphical builtins in the
future as well.
The team continued hacking on SPy in a sprint in Berlin just after the
S3.
⁂
Guillermo Adrián Molina next introduced Huemul, a Smalltalk
implementation that directly generates native code. It is a very
small system of only 4.5kLOC since it doesn’t try to do everything but
instead reuse existing code. For example, he uses libc, pthreads,
setjmp/longjmp, GTK+ for the UI and OpenGL. The system is
MIT-licensed and inspite of lacking real optimizations already pretty
fast: It runs roughly 832 million bytecodes/s and therefore is comparable
to the performance of commercial Smalltalk systems.
Huemul looks very interesting and
certainly is a thing that deserves more attention.
⁂
Are bytecodes an atavism?, Theo d’Hondt wondered when he
noticed that people are fixated on virtual machines: They think
it’s the only way to write a fast system.
However, interpreters are the simplest way to express the semantics
of a language.
After a glimpse of the history of bytecode from BCPL over Pascal-P to
Smalltalk, Self and Java, he presented Pico,
a tiny language implemented using CPS that is smaller than Scheme that
was roughly as fast as PLT Scheme (as of 2004)
Based on his experience with Pico, he decided to write PicoScheme,
which is written in a subset of C and works by compiling s-expressions
into an abstract syntax tree that then is interpreted. Soon he
realized that “Scheme isn’t all that simple to implement”, but now he
has a very promising implementation of the most parts of Scheme
(nothing really relevant is missing) that is as fast as PLT by now.
It also is very compact: the GC only has 150 LOC.
After the talk, he promised to open PicoScheme to the public in the
future.
⁂
The last talk was called On Sustaining Self by Richard P. Gabriel.
I only can recommend to take any chance to hear him
speaking because he’s doing excellent presentations—I’m unable to do
his audio-visual impressions justice, so please excuse the rough
sketches: The talk started off with playing Hogni Lisberg’s cover of “All
along the watchtower” while Noble and
Biddle’s eternal
words of their Manifesto in “Notes on Post-Modern
Programming”
appeared on the screen. “There must be some way out of
here!”
The ultimate goal of all computer science is the program. The
performance of programs was once the noblest function of computer
science, and computer science was indispensable to great
programs. Today, programming and computer science exist in
complacent isolation, and can only be rescued by the conscious
co-operation and collaboration of all programmers.
There are three ways to build self-sustaining systems according to
Gabriel: First, Designed Perfection, which is what most people try
to do today; it is very efficient, but entropy will get you. Second,
Instinctual Adaption, which is resilient and flexible. Third,
Learning, which is costly, but gives the best results in a highly
dynamic environment.
A poem assembles on the screen; to brilliant guitar music there
appears:
slowly
dawning
is
night
and it morphs into:
slowly
dawning
insights
He proclaims:
Abstraction ignores the relevant,
therefore it requires ignorance!
He does a case-study on
Levittown, which
overcame the limitations and plannedness of itself and turned into a
non-designed suburb.
He presented a case of artificial evolution showing the FPGA
evolution experiment
that generates very effective chip designs that
nobody really understands how they work.
Finally he enters an dialogue with himself asking “How are cities
designed?” At first look, they look modular, but they are so full of
interconnected dependencies that they are impossible to modualize
really. Also, the nature of the city is not planned.
In the end, the recognizance: Design is an illusion.
(I highly recommend you to watch the video when it is online.)
⁂
Summary: Attending the conference has been a great pleasure.
Although being rather short and small (only one-and-a-half days and
maybe 50 attendees), there were top-notch invited talks and many
important people (and also many unknown, but friendly, clever and
interesting ones!) around that everyone simply could talk to. The
social events were well organized (free dinner, free beer) and
actually allowed to socialize.
I seriously hope S3 can turn into a periodic conference because I’d
really like to attend it again.
[Let’s also mention the not-that-good-stuff, just for the sake of
completeness and so you see there’s not much to dislike:
introductionary marketing speeches; the “Workshop” in the name
misrepresents the conference; occasional WiFi failure.]
NP: Bob Dylan—I Believe In You
Off to Potsdam: Attending S3
Tomorrow I take the train to
Potsdam to attend the
Workshop on Self-sustaining Systems
(S3), which means I
get the chance of meeting rpg and many other
people that worked on Lisp, Self and related cool stuff in real life.
The stuff I’m working on got not
finished by far, but maybe I can write down enough on the train to
explain it to interested parties.
If you want to hook up, don’t hesitate to contact
me. I’m there until Saturday
morning.
Anarchaia and chris blogs will resume publishing Sunday, May 18.
NP: Manu Chao—Politik Kills
Celebrating Three Years of Anarchaia!
It has been another
year of your
favourite (near) daily favourite dose of links, IRC quotes, lyrics
and quotes?
Lots has happened in that time! Tumblelogs really turned mainstream,
new platforms like Soup appeared, and
tumblelogging was featured at the Telegraph, Chaosradio Express and Rails Podcast.
Time for the yearly
statistics
(previous year in parentheses):
- Anarchaia as of today consists of
- 996 posts (669)
- 18499 snippets (13555)
- 12797 links (9445)
- 2100 pictures (1440)
- 1148 IRC quotes (979)
- 610 #ruby-lang quotes
- 371 #ruby-de quotes
- 34 #rpa quotes
- 17 #rubyist.org quotes
- 14 #haskell-blah quotes
- 10 #haskell quotes
- 10 #lisp quotes
- 82 other quotes
- 1860 lyrics (1242)
- 379 quotes (311)
- 205 thoughts (138)
- totaling 4.8 megabytes, 443416 words and 85119 lines.
Thanks for all your kind mails, contributed links and other
pleasantness. I still enjoy it as much as I hope you do as well.
However, Anarchaia will have to change in the future: when my study
begins (roughly October), I won’t have the time any more to do a daily
issue. But I will try my best to make at least a weekly version of
it.
Now, on to another year of tumblelogging!
(BTW, chris blogs turned four this week as well. 48 posts this year
and still no new blogging software. I’m working on it, really!)
NP: Grotus—Good Evening
Off to Seelbach
Tomorrow I’m going to leave early for
Seelbach deep in the Black Forest
where I’ll spend the rest of the week educating myself on civil
service (which I finished for two thirds already, but hey, who cares).
Anarchaia and chris blogs will resume publishing Saturday, March 29.
Please notice that this means I will not be able to attend Euruko
2008 in Prague this year. That’s sad,
but I can’t help it (not that I’d have anything to talk about).
Enjoy the program.
Regarding conferences, I am planning to go to the Workshop on
Self-sustaining Systems in May
and RailsConf Europe
in September (I hope there will be a CabooseConf Europe, really).
I expect to have occasional Internet access in Seelbach, else mail
will have to wait. It’s my first travel with the
EEE.
NP: Grateful Dead—Promised Land