Application and web app technologies

In article <1136226294.170886.159690@z14g2000cwz.googlegroups.com>,

January, 2006.

I do not intend to start any kind of flame war, but only to seek advice
about different technologies concerning which I am mostly ignorant.
[...]
I have been tasked by me IT department with investigating different
technologies for what will be a total rewrite and major update of our
applications.

From your post, it is not clear what these applications do. That may
hugely influence any advice you can get.

For instance: if you are running weather simulations on your back end,
Fortran and C would probably be good choices for part of your system. If
you are mostly running static web pages, your choice of CMS will
probably have more impact than your choice of scripting language.

Moreover, you do not tell who will do the maintenance on these systems.
If it is "IT", the choice might move towards C/C++ or a C/C++-like
scripting language.

[...]
The problem with Perl is that it seems dowdy and oldfashioned,

Never dismiss anything because it 'seems' bad. Your 'seems
old-fashioned' is someone else's 'proven technology'. You should work on
objectifying this statement (because I am not a Perl fan, I expect that
this will be possible).

A real important part of this is database connectivity. We use a number
of different databases, Access, SQL Server, Datatel (the big University
DB), PostgreSQL (my favorite), MySQL, and a couple of others.

Any decent scripting language will be able to connect to most, if not
all, of these.

* Java/JSP -- We have already made the decision to go with Java, but
we haven't started with it, and have not committed to Java.

If your 'deciding to' does not imply commitment, you have larger
problems then choosing a technology.

* Ruby -- We have a Ruby advocate here, but no one knows anything
about it.

Never trust an advocate who knows nothing about the thing (s)he
advocates.

However, you should really take a look at Ruby on Rails
(www.rubyonrails.org). It is both good under the hood, and well-marketed
(check out some of the videos)

* C/C++ -- I mention this only because this is what IT uses. We have
no interest in C/C++, unless it really is the best.

If your web apps contain stuff that needs high performance and is CPU
bound, you should keep these in as a language. Calling C/C++ code from
any decent scripting language is easy. Also, if you need commitment from
IT, choosing a less than best language may be a good idea.

Having said that, as far as I know, there are good reasons C and C++ are
not really popular for the development of web applications.

We want something that we can use across the board, from web apps to
sys admin

Why would you? programming languages all have their strengths and
weaknesses. Good programmers will be able to choose a midway path
between standardisation on a single language and using the best language
for every task.

Reinder

···

cartercc@gmail.com wrote:

Thanks for your post. I see from the tone of the replies that I may
have made a 'huge' mistake in using the ngs for research.

From your post, it is not clear what these applications do. That may
hugely influence any advice you can get.

Just about everything. For two cases in point: (1) We have a web
enabled application for faculty members to do things like posts
attencence, print rosters, etc., which is updated four times a day from
the big DB. The big DB uses a product named Datatel, and our webapp
runs on SQL Server. Our Perl script queries Datatel, runs a number of
queries, downloads the data, shakes it a bakes it, and then shoves it
into SQL Server with DTS. This is one of our most important
applications and it is an absolute monster to do manually. (2) We also
run a little app to generate email accounts for new employees, which is
not a big deal unless you happen to be a new employee who doesn't have
an email address. Our applications run the gamut from the large,
critical apps to the convenience ones.

Never dismiss anything because it 'seems' bad. Your 'seems
old-fashioned' is someone else's 'proven technology'. You should work on
objectifying this statement (because I am not a Perl fan, I expect that
this will be possible).

I *am* a Perl fan, but after having looked at scripts someone else
wrote (who is no longer with us) with a view toward updating them, I
have concluded that a quick and dirty scripting language in someone
else's idiom isn't a very good choice institutionally. Which is why I'm
looking at OO Perl.

Moreover, you do not tell who will do the maintenance on these systems.

The database people will maintain the programs, and as you can imagine
these skills are quite varied, which is one reason we want to settle on
one technology we can all use.

If your 'deciding to' does not imply commitment, you have larger
problems then choosing a technology.

Our 'deciding to' was like this: 'Java seems to be hot, so let's all
use it.' Yes, we may have bigger problems, but we still want to commit
to one technology that will do the job.

Never trust an advocate who knows nothing about the thing (s)he
advocates.

I mispoke ... the advocate know a little about Ruby, but none of the
others do, and we don't want to take his word without satisfying
ourselves that what he says is true.

Why would you? programming languages all have their strengths and
weaknesses. Good programmers will be able to choose a midway path
between standardisation on a single language and using the best language
for every task.

We really have a hodgepodge. We have snippets written in ColdFusion,
Perl, VB6, VB7, a little C, a couple of Java apps, and some other
miscellanous stuff. We don't have any 'programmers' on staff. People
have tended to focus on the problem at hand and have used whatever
language they were familier with. We want to move beyond this, and do
some real SW engineering.

From what I have gathered, our first impulse to use Java was probably

the right one, even though it wasn't really based on any kind of
investigation. I just hate to commit to something that I have doubts
about.

CC

I have been programming Java for about 8 years (6 or 7 of that
professionally) and Ruby for about 5 years (mostly as a hobbyist.)
I've dabbled in Python but not much in Perl.

With that said, I would not recommend Java for the kind of tasks you
seem to be doing. You need something flexible and lightweight, and
I don't think your university and its associated applications is one
of those places.

I would highly recommend you stay in the scripting language realm,
either maintaining your Perl or switching to Python or Ruby.

Ruby is a great language and one that I have found fits my style and
mind better than Python or Perl. It has the flexible TIMTOWDI (There
Is More Than One Way to Do It) nature of Perl with less of a tendency
to get obfuscated. I personally never liked the significant whitespace
of Python, but in general it is a great language and would be a good
choice if that style works with you and your colleagues.

Either way, before you make a complete "switch", do a few prototype
applications in the serious contenders for your new language choice.
You should be able to learn the small amount required of each language
to code up some fairly small apps in a week or two, and the learning
experience of coding a real application will be completely worth it.
Believe me there is no better way to learn a language (both its
strengths and weaknesses) than to code up an application in it.

If you could make the *same* application in all your language choices
(let's say the email creator in Ruby, Python and Java) that would
provide the best comparison. I would also recommend posting the
resulting code to Ruby, Python and Java mailing lists or newsgroups to
see what kind of improvements the experts can recommend.

Then show the resulting tweaked code to your colleagues and let them
decide what looks best.

Ryan

···

On 1/3/06, ccc <cartercc@gmail.com> wrote:

From what I have gathered, our first impulse to use Java was probably
the right one, even though it wasn't really based on any kind of
investigation. I just hate to commit to something that I have doubts
about.

from my experience Java is not that. Java certainly has its place, but

"ccc" <cartercc@gmail.com> said:

I *am* a Perl fan, but after having looked at scripts someone else
wrote (who is no longer with us) with a view toward updating them, I
have concluded that a quick and dirty scripting language in someone
else's idiom isn't a very good choice institutionally. Which is why I'm
looking at OO Perl.

This tells a lot more about the original author of the scripts than the
language used. I'm seeing unmaintainable code written in pretty much any
language. Java (and in some ways, especially JSP in the web side) is no
cure for that.

Having said that, it may be easier to write unmaintainable Perl than
unmaintainable Java. The key is to educate (and to a certain limit
restrict) the programmers on what kind of code is acceptable to write.
And this work I think is not that dissimilar between different
languages.

Also, OO is not a magic bullet in making code readable. At worst it
gives the programmer a couple of extra levels of indirection to use
just to complicate the otherwise streamlined program. OO is good
where the data used naturally forms nice object relationships, but
there are a good number of cases where this does not happen (or at
least the relationships do not help that much in solving the actual
problem).

If you really, as you mentioned somewhere, want an all-around-language,
then Perl might be your best bet. Java is nice for web applications,
however I wouldn't use it for sysadmin stuff (or, it could be used
for part, but part is that you need an one-off tool; something you
cook up fast and use once or twice -- or a quick modification for
the existing tools). Also, much of sysadmin (esp. on Unix side) is
processing various text formats, which is one of the great strengths
of Perl. It's not just regexes (which finally are available in Java
as well), but overall facilities of the language.

Then, regarding the performance/efficiency; yes; there are cases where
use of C is justified for performance reasons. This performance
comes at a cost of programmer productivity (and possible higher
rate of certain kinds of errors). Also, in higher-level languages
the libraries are getting pretty-well tuned at least for the general
case, so it may well be that much of the general routines you find
in the library of a given language are of better performance than
something you yourself cook in C.

Another area where C would be useful is for making the necessary
glue to access some backend system (for which only C interface
library is provided) in the higher-level language of your choice.
A good example of this are the various database connectivity modules
in Perl (part Perl, part C; linking to the database client library
code).

So, overall:
- you're a Perl shop - however have lost some of your assets
  (knowledgeable personnel)
- one problem may have been too great independence of the developers,
  and lacking maintainability guidelines for the created code
- making the hop to another language would be a major hurdle
  (possibly giving major gains, though)
- could the same potential gains be realised without doing the
  language hurdle? Potentially yes; but would require more-or-less
  redesign/rewrite of the whole current environment, so a major
  hurdle anyway
- does the current language limit what you can do - doesn't seem so
- what would be gained by another language? For some other languages
  it could be easier to find developers -- however, finding competent
  developers appears to be hard for any language (competent defined
  as "able to produce code that is maintainable in the long run")

.... so, all in all, I wouldn't be that eager in shifting from the
current. Java/JSP (and higher-level frameworks built on top of these)
could be good for web side - but these require quite a lot of knowledge
to do properly (just plugging things from a full Java/J2EE toolbox to
solve your problem could well give you nothing else but horrible
performance problems -- whereas proper use of J2EE technologies could
give you a somewhat elegant solution).

Apologies for omitting completely Python, Ruby, and MS technologies;
I don't know enough of them to do any comparision.

···

--
Wolf a.k.a. Juha Laiho Espoo, Finland
(GC 3.0) GIT d- s+: a C++ ULSH++++$ P++@ L+++ E- W+$@ N++ !K w !O !M V
         PS(+) PE Y+ PGP(+) t- 5 !X R !tv b+ !DI D G e+ h---- r+++ y++++
"...cancel my subscription to the resurrection!" (Jim Morrison)