File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Diff. Between 8080 and 80 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Diff. Between 8080 and 80" Watch "Diff. Between 8080 and 80" New topic
Author

Diff. Between 8080 and 80

Priyakant Charokar
Ranch Hand

Joined: May 08, 2004
Posts: 58

Please tell me the difference between port addersses
8080 and 80

are these lines are same

http://localhost:80/index.html
&
http://localhost:8080/index.html

Thanks in advance


SCJP, SCWCD, SCMAD, SCEA, OCPJP 7, CSM
Wim van Haaren
Greenhorn

Joined: Nov 04, 2004
Posts: 18
Originally posted by Priyakant Charokar:
Please tell me the difference between port addersses
8080 and 80

are these lines are same

http://localhost:80/index.html
&
http://localhost:8080/index.html

Thanks in advance


Hi,

These are definitely NOT the same. These refer to two different webservers running on localhost: one listening for requests on port 80 and the other on port 8080.

BTW, port 80 is the default port for HTTP and you can leave this out of the URL. 8080 on the other hand is a non-default port number and therefore cannot be left out of the url.
Priyakant Charokar
Ranch Hand

Joined: May 08, 2004
Posts: 58

thanks alot Haaren
Mikalai Zaikin
Ranch Hand

Joined: Jun 04, 2002
Posts: 3212
    
    6
Originally posted by Priyakant Charokar:
Please tell me the difference between port addersses
8080 and 80

are these lines are same

http://localhost:80/index.html
&
http://localhost:8080/index.html

Thanks in advance


The reason that some applications use 8080 (7080, 9080) instead of 80 (traditional) is that on UNIX , port numbers below 1024 are reserved for super-user processes (can only be bound to by 'root'), that's why for OS compatibility some servers which runs on several platforms: Tomcat, WebSphere, WSAD's WebSphere Test Environment propose to use some ports that greater than 1024, but still have "80" inside : 7080, 8080, 9080. Good news is that you can run multiple servlets containers if they listen to different ports, for example: Tomcat on 8080 and WebSphere Express on 7080.

regards,
MZ


Free SCDJWS 5.0 Study Guide - SCDJWS 5.0 Quiz (How to get SCDJWS 5.0 Quiz)
Java Platform, Enterprise Edition 6 Web Services Developer Certified Expert Exam Study Guide and Quiz
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Diff. Between 8080 and 80