The Design of Software (CLOSED)

A public forum for discussing the design of software, from the user interface to the code architecture. Now closed.

The "Design of Software" discussion group has been merged with the main Joel on Software discussion group.

The archives will remain online indefinitely.

JSP and Java Servlets

I like what I see with JSP, Beans, and Servlets.

But, let me explain a situation and see if it makes sense: 

1. If I want to develop a java solution for a small to medium size web application - would JSP and Servlets be a good choice?

2. Does Apache support JSP and Servlets 'out of the box' or would an ISP have to install something for java to work?

In other words, can you deploy and run jsp and servlets to a remote server hosted by a ISP? 

3. I would only need a J2EE environment if I went to EJB's - correct?
Java Newbie
Friday, March 11, 2005
 
 
Hi,


It's been a while since I done anything with JSP and servlets.

I don't see why you can't or shouldn't use JSP or servlets instead of .net.  Really depends on your requirements I guess.

To run a JSP/servlet website you will need a web server such as tomcat which is open source and can run along side apache.  JRUN is another server but I think that will cost.

see link below for more info:
http://jakarta.apache.org/tomcat/index.html

Hope that helps a bit.
Andy
Friday, March 11, 2005
 
 
2. The Apache HTTP server doesn't, but as Andy said, the equally free Jakarta Tomcat server does. Note that you don't need to run the Apache HTTP server alongside Tomcat, as Tomcat is perfectly happy to serve static HTML content as well.

3. No, JSPs and Servlets are just as much a part of the J2EE specification as EJBs are.
John Topley Send private email
Friday, March 11, 2005
 
 
It is fairly easy to find a hosting company that supports Java.  However, you will need to look in the enterprise end of the market rather than the free/low-cost type.  As an example of what you can get for your money take a look at this (http://www.positive-internet.com/zhosting.html).

Struts is worth considering (http://struts.apache.org/), it is an MVC (Model-View-Controller) add-on for any Java environment although aimed at Tomcat (http://jakarta.apache.org/tomcat/index.html).

In case you've not heard of MVC, it is simply the separation of the program logic (Model) and the presentation layer (JSP), with the controller being the part that links the two.

I would personally avoid using EJB's.  There is alot of overhead and it is probably not worth it most of the time.  You can use Hibernate to do object-relational mapping and persistence (http://www.hibernate.org/).
Andrew Langrick Send private email
Friday, March 11, 2005
 
 
I second not using EJBs.  Servlets/Filters/JSPs are a good way to develop web applications, but be warned, they are NOT RAD tools.  Don't expect to be hyper-productive right away as if you were doing Perl or PHP.  But, as you gain more experience and develop class libraries, you'll end up getting a lot of code reuse, so you'll end up saving time in the end.
Vince Send private email
Friday, March 11, 2005
 
 
If PHP has a component/java bean approach, I'd try it - I like classes, inheritance, etc...
Java Newbie
Friday, March 11, 2005
 
 
You can emulate most of JSP/Servlets features in PHP without too much effort, and language-wise PHP5 has almost everything Java has. This doesn't mean, however, it's anywhere near Java as a development platform.
Egor
Friday, March 11, 2005
 
 
Just a quick additional note: As previously stated JSP/servlets are part of the J2EE spec just as well as EJBs. But servers like Tomcat are 'servlet containers' rather than full fledged J2EE application servers, which means that they support JSP/servlets but not EJBs. Good enough for most people and offered by many hosting companies.

As far as frameworks go I would second Hibernate if you want object/rdbms mapping, but I would caution about Struts. I feel it's a cumbersome framework with little value added. If you feel the need for a presentation framework Tapestry is a good alternative.
jz Send private email
Saturday, March 12, 2005
 
 
"but I would caution about Struts. I feel it's a cumbersome framework with little value added."

I second that emotion. Struts is about the most over engineered web development framework I've come across. The few times I've been forced to use it, it's given me nothing but a intense shooting pain behind my left eye. You can do MVC quite nicely with simple' JSP, Servlets Tablibs and POJOs.
Captain Stinky
Monday, March 14, 2005
 
 
There is a pretty good rad tool from Sun:

http://developers.sun.com/prodtech/javatools/jscreator/index.jsp

I wouln't use it for very large apps but for smaller jobs it works very well. It's only 99 bucks.
Dan Howard Send private email
Tuesday, March 15, 2005
 
 
"You can emulate most of JSP/Servlets features in PHP without too much effort, and language-wise PHP5 has almost everything Java has. This doesn't mean, however, it's anywhere near Java as a development platform"

Could you show an example?

ie. does PHP have classes and inheritance?
Java Newbie
Wednesday, March 16, 2005
 
 
Quick google search and I found my answer.

I will research more.

Thanks everyone
Java Newbie
Wednesday, March 16, 2005
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz