[Gllug] re: OSS CMSs

Russell Howe rhowe at siksai.co.uk
Fri Apr 29 00:27:35 UTC 2005


On Thu, Apr 28, 2005 at 06:00:46PM +0100, Daniel P. Berrange wrote:
> The sheer quantity of code I was able to leverage from CPAN is awesome.

Just as a comparison, most languages in use today will have libraries
available to do what the CPAN modules you used did (although few have
such a convenient and comprehensively indexed archive of said libraries
as CPAN provides). The following is some idea of what I'd use in the
Java world to achieve the same things:

> To name but  a few, Mail::Box provided for loading of arbitrary mail
> box formats and MIME message decoding,

Like JavaMail then :) There's a JavaMail plugin to handle maildir
access on sourceforge which seems to work well.

> Template provided awesome HTML templating capabilites

I guess most Java-types would use XSLT to transform data (in the form of
XML) into XHTML. That's not writing it in Java, of course, it's writing
it in the downright odd language that is XSLT. Java is pretty lacking
when it comes to text manipulation (the addition of regex support to the
core libraries in the 1.4 series helped here, but it's still hardly
something Java can be called good at). An advantage of using XSLT is
that it's pretty hard to produce XML output that isn't well-formed :)

I can't imagine executing an XSLT transform is going to be as fast as
Template either, somehow :)

> and of course little things like DBI / DBD-PG

JDBC, which has drivers available for pretty much every database I know
of, and there's SQL-J IIRC, which is a preparsed compile-time database
library thing. JDBC's PreparedStatements are just the ticket for taking
untrusted input and inserting it into an SQL query (compared to just
concatenating a string together, which so many webapps seem to do,
leaving their databases open to SQL injection attacks). No doubt DBI has
something equivalent.

> Log::Log4perl

AFAIK, a perl implementation of log4j so the operation of the two should
be virtually identical

> Digest::SHA1

javax.crypto.* IIRC

> 'enterprise' java, no thanks - I'd still be working on it a year after
> I'd started & it would be a pale immitation of what I knocked up in 
> Perl ;-P

Can't say I'm all that keen on a lot of the enterprise stuff, especially
the EJB-type bits. Seems a lot of work for a one-man project :) I guess
it might pay off if you have a few hundred developers all working on one
project, but when you hit that kind of scale, I guess the management
difficulties are more trouble than the technical ones.

I do quite like the servlet stuff though, and the new I/O (nio) API
finally provides a clean and efficient way to do I/O in Java (in a way
that isn't really very Java-like - I think it's been ported from
elsewhere).

I agree wholeheartedly with people who say Java is verbose - sometimes
when I'm writing in it, I get the feeling that it isn't for people to
write, but for tools to generate (I have a perl script which generates a
skeleton javabean from a simple definition file, for example :)

-- 
Russell Howe       | Why be just another cog in the machine,
rhowe at siksai.co.uk | when you can be the spanner in the works?
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list