Package management with Fuel

Mentor: Marcus Denker
Second mentor: Carlos Ferro
Level: Intermediate
Accepted student: Martín Dias
Invited students: Martín Dias
Students interested: Martín Dias(very)

(Student proposal by Martin Dias)


Pharo has tools for managing packages like Monticello, but they work by compiling all the source code again. That has several annoyances:

One is the time required to do that. Smalltalk compiler is not fast to work on large pieces of code, so if you want to install a big package, you need a lot of time compiling it. Why should you compile it again, given that it was all compiled when you exported the package? The bytecodes will be the same again, you know... If you just could load the Classes and Compiled Methods instead of compiling it all again, you can save time.

Other point is that you cannot build packages with objects; just the source code goes in them. For instance, you need special stuff to tell the user that she needs to run/evaluate installation code. Exporting packages with an object serializer, you could include pre-installed classes, singletons, etc.

Besides, managing packages this way makes easier a tidy un/installation of a package, leaving all the previous versions of methods loaded. And you could handle better the "migrations" that happen when you want to load code for a class whose shape has changed; the source code will not compile in that case.

Parcels do that in VW with Parcels, and has proven great utility. We want to do it with Fuel on Pharo.

Fuel is a general purpose binary serializer. It already saves and loads classes without using a compiler. Package management implies facing additional challenges like check dependencies, run pre- and post-scripts, overriding existing classes or methods, tolerate superclass shape changes, run system validations, send notifications, clean uninstall, and others.

Benefit for the Student

Complete understanding of the life cycle of classes and packages in the system.

Benefit for the Community

Pharo (and eventually also Squeak) users will have the alternative to load classes with the features described above. Additionally, this would be useful in bootstrap image experimentation.

Updated: 17.4.2012