cancel
Showing results for 
Search instead for 
Did you mean: 

URL pattern in web.xml

Former Member
0 Kudos

Hi all,

I have a Servlet named "ContentServer" and content index HttpCs which is defined in application.xml

Can any 1 tell me what url pattern should i specify in web.xml Mapping tab

i have specified it as

http://localhost:8100/HttpCs/servlet/ContentServer

http://<server>:port/<content-index>/servlet/<servlet-name>;

The deployment runs fine but i m not able u get a result on the web browser when i specify "http://localhost:8100/HttpCs/servlet/ContentServer."

Should the <server> be localhost?

Can any 1 tell me wht can be the alternative.

Thanks

Yogi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Yogi,

I am not sure why, but please check the port number. It may something other than 8100. Try 454.

Cheers,

Bhanu

Former Member
0 Kudos

Hi Bhanu,

Can u tell how can I find the port number and server name in order to specify in the url.

Thankz

Yogi

Former Member
0 Kudos

Yogi,

When you specify in web.xml Mapping tab, use:

http://<localhost>:454/HttpCs/servlet/ContentServer

Bhanu

Former Member
0 Kudos

Hi Bhanu,

I found the solution. Thanks for your help.

I used the dispatcher http port(5000) and it works.

(But I have few other errors to solve)

You can view the http port in NWDS under

Window->Show View->J2EE Engine->dispatcher->http port

Thanks

Yogi.

Former Member
0 Kudos

Hi Yogi,

Thanks for the update!

Answers (1)

Answers (1)

Former Member
0 Kudos

Yogi,

Just ommit part till /servlet/<servlet-name> when specifying URL pattern, i.e. use <i>/servlet/ContentServer</i>.

VS