aspose file tools*
The moose likes JBoss/WildFly and the fly likes setup context under Tomcat Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JBoss/WildFly
Bookmark "setup context under Tomcat " Watch "setup context under Tomcat " New topic
Author

setup context under Tomcat

riaz rahman
Greenhorn

Joined: Nov 28, 2005
Posts: 17
hi,
In tomcat 5.x i want to setup context inside my war directory (not in server.xml).
because my application will be deployed after server started.
so any change in server.xml is not reflected till server is restarted.


For example, I want to map D:\files\set1 to http://localhost/docs.
(not through server.xml)

Best regards...
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17259
    
    6

In your web app war file just include a jboss-web.xml which sets the context url.

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
riaz rahman
Greenhorn

Joined: Nov 28, 2005
Posts: 17
Hi mark,

i have specified in jboss-web.xml like this



but this is not properly working.i think i an doing some mistake.please help me.

with regards
Riazur Rahman
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17259
    
    6

Good question, but I don't see anything, but it could be a simple spelling or path problem. But at this point it goes beyond my knowledge. I can just set the URL.

Mark
riaz rahman
Greenhorn

Joined: Nov 28, 2005
Posts: 17
Hi mark,

I think mapping static content as above is not possible inside web application folder (is possible only in server.xml). so i have changed my servlet coding to handle the request.

thanks for your kindly replay.
 
wood burning stoves
 
subject: setup context under Tomcat