简体   繁体   中英

How do I configure a static context path in jboss7?

I am trying to find a way to configure a static context path i jboss7. We are upgrading from jboss4.2 and in that version we had a config element in server.xml that looked like this:

   <Host name="localhost"
       autoDeploy="false" deployOnStartup="false" deployXML="false"
       configClass="org.jboss.web.tomcat.security.config.JBossContextConfig"
       >

        <Context path="/directory/pdf"
                docBase="/tmp/pdfdok"
                reloadable="true">
        </Context>

It was in the directory deploy\\jboss-web.deployer.

The intention of this is to be able to reach the directory /tmp/pdfdok with a url like this: http://server:port/directory/pdf or more exactly to reach a generated pdf document on this directory with the url: http://server:port/directory/pdf/pdfdoc.pdf from a client popup window.

Is there someone here who can help me?

Thanks

Rune

It seems like this is impossible to do in jboss7. I solved my problem by using a fileservlet instead. This is a good page to look at for an example: http://balusc.blogspot.com/2007/07/fileservlet.html

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM