Andrew Thompson said:
You can 'have your cake and eat it too' with JWS, since you can
specify either a *minimum* version of Java, or a *specific* version.
Whoops, I'll have to ask you to excuse my ignorance on this one. It's
wonderful that the people who designed JWS had the foresight to allow
you specify a specific version of the JRE is required. I've learned
my lesson and will avoid talking about JWS in the future until I've
taken time to research it better.
Would you care to list them for the purposes of progressing
this thread, or are they secret?
Here are a few reasons, some of them perhaps good reasons, some
perhaps not such good reasons.
1. Asking or requiring the end user to take any more installation
steps than absolutely necessary. As an example, I'm a PuTTY user
(it's an SSH client for Windows) because I can download and run a
single executable and be up and running immediately. I used to use
TeraTerm with the SSH plug-in, and switched to PuTTY only because
of the ease of deployment factor. (I may find myself using several
different computer systems every day, possibly having never used
any of them previously.)
Even though the WWW is a big step back in user interfaces in many
ways, I think its success shows how important the simplest
installation possible can be. It's unfortunate to have to ask
users to step through a JRE installation before they can begin
using your software.
2. The size of the JRE may be a burden for many end users who may find
themselves on dial up or metered access to the Internet. I often
wish I could deploy my Java applications statically bound with only
those parts of the JRE and libraries that my application absolutely
requires.
For example, if my application runs in the background only, with no
user interface, it seems like an unnecessary burden that end users
would have to download a full JRE with AWT and Swing support (I'm
assuming for the moment that AWT and Swing take up a non-trivial
amount of space in the JRE - I could be mistaken, but this is just
an example - you could probably apply it to other things).
Of course this doesn't apply to programs delivered on CD-ROM...
3. Native executables are harder to reverse engineer, thus protecting
proprietary applications better. (Been debated to death, but I
thought it was worth mentioning).
Some of these items are based on experiences I had writing small
applications and deploying them via the Internet. One such
application was written in C++ (shudder
and used the wxWidgets
(previously wxWindows) and I was very pleased that the resulting
application was just over a megabyte.
Another was a small Python (shudder again
program and again the
application was just over a megabyte.
Java is currently my preferred programming language but I have to
admit I have more trouble with Internet-based deployment because a lot
of users (whether rightly or wrongly) complain about having to
download and install the JRE first, many of them won't do it at all.
I'll admit I'm probably asking for the impossible, but I do find
myself wishing I could "compile to .exe" (when deploying on Windows)
and also wish the resulting program would be as small as possible
(that is, only link in those parts of the JRE/Java libraries I'm
actually using).
To be fair, I should add that these thoughts won't stop me from using
Java. I don't like languages such as C++ or Python at all!
One more thought to add: I'm concerned about Microsoft's .net.
Microsoft can and will leverage their Windows monopoly to make sure
every Windows user has the CLR installed when Windows is installed
(starting with Longhorn, I assume, unless they've started doing this
already) which gives Microsoft a huge advantage in terms of points #1
and #2 listed above.
I have no intention of using .net or languages like C#, but I can't
ignore the fact that when I compete against .net programs with my Java
programs, the end users will have the choice of either downloading a
small .exe (since CLR will presumably already be installed on their
Windows machine), or downloading my program which might first require
them to download and install the JRE. It doesn't seem like much to
ask, but I suspect most end users will take the path of least
resistance, much like flowing water does. This translates into lost
market share for me.
Whew! I didn't expect this to end up so long. I'm very interested in
your comments and suggestions.