WordPress running on Tomcat

As regular reader you may have noticed that the appearance of this blog has changed. After running into a couple of issues and being faced with the option to either manually fix every single link in the old Blog-system or to switch over to a PHP driven system, I was torn. I dont trust PHP enough to let it loose on my system for security reasons. I admit, I love Java beyond reason. What other system allows you to lock down the VM so safely that evil-doers cannot do evil at all?

Luckily, over the past year, I stumbled accross the perfect solution: Quercus. Quercus is a PHP interpreter written in Java. It runs great. Heck, it is not optimized at all (in the sense of compiling PHP to Bytecode, as, for instance, the Rhino JavaScript library does), yet still it outperforms the native PHP interpreters (thanks to Tomcat).

Does it work? Yes, as proven by this machine. Is it complicated to set up? Not at all. Just drop the WAR file in, add your JDBC-driver, copy your PHP files in, run.

And now that writing Blog-Entries is no longer a pain, I’m tempted to write more often.

Post scriptum:

I just noticed that the friggin’ import lost all links, all tables and all images thanks to a overly active “html validator” that strips all tags it does not understand. So maybe I exchanged one can of worms with a just another one.

Update: It seems the “kses.php” file (or Quercus’ interpretation of the same) is to blame for the troubles. The file contains a check on whether a attribute validation definition is a empty-string. For some reason, Quercus  believes that a empty array *is* a empty string. Forcing it to use a stricter check (three equals signs instead of two) solved the issue so far.

This entry was posted in Uncategorized on by .

About Thomas

After working as all-hands guy and lead developer on Pentaho Reporting for over an decade, I have learned a thing or two about report generation, layouting and general BI practices. I have witnessed the remarkable growth of Pentaho Reporting from a small niche product to a enterprise class Business Intelligence product. This blog documents my own perspective on Pentaho Reporting's development process and our our steps towards upcoming releases.