Upgraded blog software

I have just finished upgrading my blogging server software (Pebble) from a custom version of version 1.9 to a standard version 2.2. Apart from file truncation issues the migration went fine. RSS feeds should be at their normal address and basically no one should actually see the change unless they visit the homepage. The only items missing is my custom theme. If you experience any problems please let me know by commenting or by sending me an e-mail (lekkim [at] heisterberg.dk).

One nice addition to Pebble 2.x is the support for comment thread RSS feeds which is something I really think the developerWorks blogs should implement. Apart from this there is a host of new nice features.

Patch to Pebble 2.0-RC2 submitted

I have submitted a patch to Simon Brown (author of Pebble) to make it possible to handle additional filetypes using the core Pebble 2.0 framework. I have done it by modifying the net.sourceforge.pebble.domain.FileMetaData and moving the information about the possible filetypes to an enum (net.sourceforge.pebble.domain.TypeEnum). This enum may be subclassed in my application which is built upon Pebble to provide support for additional filetypes. I have used the enum from Jakarta Commons Lang because Java 5 enums doesn’t support subclassing.

The filetypes usable by the Pebble instance is configured using a factory (net.sourceforge.pebble.domain.TypeEnumFactory) which is instantiated and set in the net.sourceforge.pebble.Configuration object using the applicationContext-pebble.xml file. The actual bean set is configured from the included pebble_import_factories.xml file since I need to replace the factory easily from my build.xml. I also need to replace the FileDAOFactory so that bean definition has been moved to the xml-file as well.

The applicationContext-acegi-security.xml has been modified as well to import a bean instance from pebble_import_acegi.xml since I also need to be able to easily add something here from my build.

I have also added the possibility of specifying whether the individual filetypes may be managed and whether new directories may be added to the containing filetype directory by the user.

I have put the patch file itself on my blog for downloading. The patch should be applied to the Pebble 2.0-RC2 source tree.

Comment SPAM – again…

The easiest way to block comment SPAM is to turn of comments altogether. Another way is to turn of comments to existing posts periodicly which is the way I do it (using a cron job). I’m running Pebble for my blog so disabling comments and trackbacks in bulk is easy using Perl and regular expressions:

perl -pi -e 's/<commentsEnabled>true/<commentsEnabled>false/' `find . -name [0-9]*.xml`
perl -pi -e 's/<trackBacksEnabled>true/<trackBacksEnabled>false/' `find . -name [0-9]*.xml`

This is the same approach as I have been used previously to rename categories.