• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

BAsic Query

 
Rajpal Kandhari
Ranch Hand
Posts: 126
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Everyone,
I am new to servlets, pls explain me the following differences with suitable example.
1. What is the difference between Applets and Servlets.
2. Difference between CGI and Servlets.
3. Difference between 3-tier and n-tier architecture.
4. Can a servlet be used on all the tier (3 tier).
5. What is JSDK - Java Space Development Kit.
6. What is "java -g" option. When, how to use it.
7. What is a personal web server (PWS).
I would be very thankful if someone explain me above thing with suitable examples.
Regards,
Raj.
------------------
 
Tony Alicea
Desperado
Sheriff
Posts: 3226
5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my opinion, if you have to ask those questions, you are in need of a good servlet book. But before that, I would suggest that you learn the Java programming language if you have not done so yet.
The "S" in JSDK does not stand for SPACE but for SOFTWARE.
 
Frank Carver
Sheriff
Posts: 6920
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry to contradict you Tony, but JSDK does stand for Java Spaces Development Kit. It also used to stand for Java Servlet Development Kit. Both names defined by Sun. This is why they changed the name of the servlet one to JSWDK, before handing it over to Apache.
Java Spaces is part of or very closely associated with Jini, while Servlets are part of Java 2 Enterprise Edition (J2EE), and I guess the two teams never bothered to talk to each other.
 
Amandeep Waraich
Ranch Hand
Posts: 56
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey, I didn't know that !!! It's quite a surprise. I thought JSDK stands for Java Server Development Kit !!
-Aman
 
Frank Carver
Sheriff
Posts: 6920
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And just for fun there's an article all about "space-based programming" at http://www.sys-con.com/java/archives/0510/Modi
 
prakash muthu
Ranch Hand
Posts: 75
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. What is the difference between Applets and Servlets.
Apllet will run on a browser or in an applet viewer while servlet will be running on webserver?
2. Difference between CGI and Servlets.
in CGI, for each request one instance will be loaded and that will execute the request
in Servlets for each request a seperate thread will be created and that will execute the request
3. Difference between 3-tier and n-tier architecture.
3 tier eg means client -> webserver -> database
n tier eg client -> webserver -> Application Server -> Database (like any layer can be come)
4. Can a servlet be used on all the tier (3 tier).
No
5. What is JSDK - Java Server Development Kit.
To develop a servlet program, we should have JSDK like JDK for Java

6. What is "java -g" option. When, how to use it.
7. What is a personal web server (PWS).
To run a ASP program, we should have a PWS.
let e know, if i'm unclear
with regards
Prakash
 
anoop kumar
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, well most of teh questions seem answerred..
javac -g
is an option where u may block debugging info to get into ur class (byte) code..like when u say javac -g:none then the resulting class file will be smaller than just javac...this is useful in memory/resource intensive operations like PDA's or mobile phones etc..where j2me (micro-edition) is used.
hope this answers one of ur questions satisfactorily.
anoop
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic