A friend, who was recently exposed to Web development, was wondering why Java hosting was not as popular as it was for other Web technologies. It was a lot easier to find hosting, right from cheap shared space to dedicated machines, for other languages like PHP and Python. Why not for Java?
Frerk Meyer gives us one of the reasons.
$ java -version
Error occurred during initialization of VM
Could not reserve enough space for object heap
Could not create the Java virtual machine.
Java complains about insufficient memory even on a dedicated virtual server with 256MB memory. You have to start Java with the right command line arguments make it work in such environments.
The other reasons I believe are:
- Java is so popular and considered suitable for big applications, that most of the Java community and its tools seem to be geared only for that, and make it unsuitable for small and medium-sized applications. This has resulted in lower demand from the common user, which in turn has resulted in lower supply of cheap hosting.
- Secondly, I am not sure if the various Java application servers and containers are easy to setup for shared hosting.
Java has to get out of this lock, and perhaps Sun has to take an initiative in this. Lack of easy hosting for Java is not because of Java, the language, but because of Java, the industry.