Classpath in web.xml

how do i define my classpath in the web.xml? i inserted the tag <classpath id='/directory/file.jar'/> w/in the <web-app> tags and my servlet still cannot find the file. is this the correct method?

Okay, I see what you mean.
Which webserver are you using? In normal circumstances, as long as a jar resides in the classpath of the server (for example your CLASSPATH environment setting) then it should be picked up by the web application.
In tomcat you can declare a class path in the <tomcat-home>/bin/setclasspath.bat
In whatever web server you are using will need to add the jars to the classpath of the web server's JVM. Check out the docs for the web server for more info.
This will entail the need to stop and restart the server once you add your application though.
Are you able to separate which classes are required by the webapp only and those required for anything else? Mainly because you may be adding extra unused classes which are just taking up space.
Cheers,
Anthony

Similar Messages

  • How to give relative path in web.xml?

    Hi All,
    Im creating a servlet which has to load the properties file.
    I don't want to give the location of the properties file as ABSOLUTE PATH. But I'm unable to provide the same as RELATIVE PATH.
    When I give the path is given as ABSOLUTE PATH (drive:/dir/) it is working. But if I give the RELATIVE PATH(../), the same is not working.
    Kindly help me in this.
    Regards,
    Kumar Madhavan.
    My web.xml file is:
    <?xml version="1.0"?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
    <web-app>
         <display-name>NGT - ASCII</display-name>
         <description>Application for Safety Critical Information vIew.</description>
         <welcome-file-list>
              <welcome-file>ASCII.html</welcome-file>
         </welcome-file-list>
         <context-param>
              <param-name>asciifiledir</param-name>
    <!-- This is the tag in which I would like to
              <param-value>../</param-value>
         </context-param>
    </web-app

    Hi.
    Exclude the directory path from the <param-value/> in
    the web.xml and just keep the property file name.
    Place the property file in the classpath and load it
    like this from the servlet:
    Properties props = new Properties();
    String propFileName = "" // Read param-value from web.xml
    try {
    InputStream is = TheServlet.class.getResourceAsStream(propFileName);
    props.load(is);
    } catch (Exception ex) {
    System.out.println("Prop file not in classpath!");
    /Jesper

  • Weblogic.servlet.reloadCheckSecs in web.xml not working

    Given the following web.xml file:
              <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
              1.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
              <web-app>
              <context-param>
              <param-name>weblogic.servlet.reloadCheckSecs</param-name>
              <param-value>100</param-value>
              </context-param>
              <servlet>
              <servlet-name>CookieCounter</servlet-name>
              <servlet-class>servlets.CookieCounter</servlet-class>
              </servlet>
              <servlet-mapping>
              <servlet-name>CookieCounter</servlet-name>
              <url-pattern>monster</url-pattern>
              </servlet-mapping>
              <welcome-file-list>
              <welcome-file>hello.html</welcome-file>
              </welcome-file-list>
              <error-page>
              <error-code>404</error-code>
              <location>/error.jsp</location>
              </error-page>
              </web-app>
              It seems the weblogic.servlet.reloadCheckSecs property is not taking effect.
              The
              default value of -1 is always used. I did stop and restart weblogic.
              I also trid to set the servlet classpath in the web.xml file with
              weblogic.servlet.classpath
              property and it did not change the classpath for the servlet. It seems that
              other
              items are working such as adding new servletrs to the web application. Note
              that
              this is the cookie sample application that installes with the beta 2
              download.
              Thanks,
              Dan.
              

    Hi All:
    Thanks for all your help regarding the adfAuthentication success_url. Now I am able to configure to make this work. But now I am facing another issue i.e. I am getting 401 Not authorized message when the success_url is pointed to the jspx page.
    Note: I am using custom login module similar to DBProcOraDataSourceLoginModule so my roles are stored in the custom Role class. So I am not sure how to pass this role info to the security in ADF in order to authorize the page to be viewed.
    Could you please help and can you point me to any specific link.
    Thanks & Regards
    Sridhar Doki

  • Classpath for web-application.

    I am working on a web application with a bunch of jsp files using some
    java classes. I am using tomcat 5.5. I have a special class file, say
    a.class, sit in the web-inf/classes. This class import another two
    jars, say b.jar and c.jar. The jsp file will import a and does not
    use b and c. How should I organize them for a war file in server?
    I actually write a.java with the jsp file in a web project in netbean
    5.5. And the created war file put b.jar and c.jar in web-inf/lib. But
    when I deploy the war file, I keep get the
    "java.lang.NoClassDefFoundError: org/kowari/itql/ItqlInterpreterBean"
    (this is a class in b.jar). I test compiling all the jsp in compile
    and it works. I suppose you can specify these classpath related
    information somewhere in web-application directory. How to put
    everything? Thank you.

    This is the result of "jar tf display.war". The one I am talking about is KowariStore.class. It use WEB-INF/lib/tupelo2.jar, which use WEB-INF/lib/kowari-1.2.0.jar. The problem is
    java.lang.NoClassDefFoundError: org/kowari/itql/ItqlInterpreterBean, this is a package in "kowari-1.2.0.jar".
    META-INF/
    META-INF/MANIFEST.MF
    WEB-INF/
    WEB-INF/classes/
    WEB-INF/classes/edu/
    WEB-INF/classes/edu/uiuc/
    WEB-INF/classes/edu/uiuc/lis/
    WEB-INF/classes/edu/uiuc/lis/brain/
    WEB-INF/lib/
    images/
    META-INF/context.xml
    WEB-INF/bottom.jspf
    WEB-INF/classes/edu/uiuc/lis/brain/BrainDB$Database.class
    WEB-INF/classes/edu/uiuc/lis/brain/BrainDB.class
    WEB-INF/classes/edu/uiuc/lis/brain/KowariStore.class
    WEB-INF/classes/edu/uiuc/lis/brain/uiucdoc$Columns.class
    WEB-INF/classes/edu/uiuc/lis/brain/uiucdoc$Database.class
    WEB-INF/classes/edu/uiuc/lis/brain/uiucdoc.class
    WEB-INF/lib/kowari-1.2.0.jar
    WEB-INF/lib/mysql-connector-java-3.1.13-bin.jar
    WEB-INF/lib/tupelo2.jar
    WEB-INF/sun-web.xml
    WEB-INF/top.jspf
    WEB-INF/web.xml
    images/Thumbs.db
    images/bg.jpg
    images/brain.gif
    images/brain_banner.gif
    images/ui.gif
    index.jsp
    relevance.jsp
    result.jsp

  • Web.xml setup for web application problem

    WLS v5.1 on Windows 2000---standard installation.
    I am setting up a web app call Kermit with its own web.xml with the
    following:
    <context-param>
    <param-name>weblogic.httpd.servlet.classpath</param-name>
    <param-value>c:/weblogic/Kermit/WEB-INF/classes</param-value>
    </context-param>
    <context-param>
    <param-name>weblogic.httpd.servlet.reloadCheckSecs</param-name>
    <param-value>1</param-value>
    </context-param>
    <context-param>
    <param-name>weblogic.httpd.indexDirectories</param-name>
    <param-value>false</param-value>
    </context-param>
    <context-param>
    <param-name>weblogic.httpd.register.*.jsp</param-name>
    <param-value>weblogic.servlet.JSPServlet</param-value>
    </context-param>
    <context-param>
    <param-name>weblogic.httpd.initArgs.*.jsp</param-name>
    <param-value>compileCommand=c:/jdk1.2.2/bin/javac.exe;workingDir=C:/weblogic
    /Kermit/Compiled</param-value>
    </context-param>
    <context-param>
    <param-name>weblogic.httpd.documentRoot</param-name>
    <param-value>web/</param-value>
    </context-param>
    <welcome-file-list>
    <welcome-file>index.htm</welcome-file>
    </welcome-file-list>
    First off, the servlets do not redeployed properly after compilation. Any
    changes I made to a servlet, I had to down the weblogic server and bring it
    back up. What am I doing wrong with this??
    Second, weblogic.httpd.indexDirectories should not allow directory browse ..
    but it still does for this app. Am I missing something else?
    Third, JSP configuration that specifies where a directory is supposed to be
    compiled is useless cuz' it's always compiled in tmpwar dir, which is
    dynamically created if not already there. Should I add something else to
    this???
    Fourth, weblogic.httpd.documentRoot should allow me to just type in a URL,
    such as http://relyon1:7001/Kermit, and it should redirect to a
    file(specified by welcome-file-list tag) under the directory
    web(/weblogic/Kermit/web). However, it's not doing it.
    From the documentation that I've read, this should have been very siimple
    but it's not working the way the docs have it made it out be.... am I
    missing anything else??
    Please help.

    Currently we only officially support ADF 11g deployment to WebLogic.
    There is at least one report of someone running this on Tomcat here:
    JDev 11.1.1.1.0 + ADF+ BC4J application on Tomcat6
    Note that this will require you to have an ADF runtime license though.

  • Init parameter in web.xml throwing an error..?

    OK.. this is probably going to sound strange, but here goes:
    Here is my entry in the web.xml:
    <servlet>
              <servlet-name>ServletTestRunner</servlet-name>
              <servlet-class>
                   org.apache.cactus.server.runner.ServletTestRunner
              </servlet-class>
         </servlet>
         <servlet-mapping>
              <servlet-name>ServletTestRunner</servlet-name>
              <url-pattern>/ServletTestRunner</url-pattern>
         </servlet-mapping>Everything works fine - I pull up the servlet with the following URL (http://localhost:7001/CDCAppWeb/ServletTestRunner?suite=com.testcases.decision.service.SendCreditRequestBeanTest)
    , and receive the results in XML format. However, if I change the web.xml to have the following:
         <servlet>
              <servlet-name>ServletTestRunner</servlet-name>
              <servlet-class>
                   org.apache.cactus.server.runner.ServletTestRunner
              </servlet-class>
              <init-param>
                   <param-name>xsl-stylesheet</param-name>
                   <param-value>cactus-report.xsl</param-value>
              </init-param>
         </servlet>(notice the cactus-report.xsl init-param entry) - the servlet does not work. Actually, NONE of the other servlets in my application work when I put in this init-param for the ServletTestRunner. I have verified that the xsl is in the classpath (WEB-INF/classes).
    What I am missing... any ideas?

    I know what the problem is. If you call servlet with the default URL (http://host/app/servlet/package.Servlet) than Servlet DOES NOT read init parameters. I don't know why it was designed this way.
    To make servlet read init parameters, you have to assign it a name and then call it with that name, like this:
    <servlet>
    <servlet-name>ServletName</servlet-name>
    <servlet-class>package.ServletClass</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>ServletName</servlet-name>
    <url-pattern>/app/path/ServletName</url-pattern>
    </servlet-mapping>
    You can then call servlet using path specified in url-pattern and read init parameters in the normal way.

  • Web.xml  configured correctly(I think),  but still getting '404...resource

    not found error' from tomcat. Here is my web.xml:
    <servlet>
    <servlet-name>HelloServlet</servlet-name>
    <servlet-class>HelloServlet</servlet-class>
    </servlet>
    <servlet>
    <servlet-name>HelloServlet2</servlet-name>
    <servlet-class>coreservlets.HelloServlet2</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>HelloServlet</servlet-name>
    <url-pattern>/classes/HelloServlet</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>HelloServlet2</servlet-name>
    <url-pattern>/classes/coreservlets.HelloServlet2</url-pattern>
    </servlet-mapping>
    </web-app>
    when I went to the following urls after I had edited web.xml to the above,
    http://localhost:8080/cucoweb/classes/coreservlets.HelloServlet2
    http://localhost:8080/cucoweb/classes/HelloServlet
    I go the expected results, ie, 'Hello(2)' and 'Hello'. Then I shutdown tomcat and restarted it.
    And when i tried to access those 2 urls again, I got the above error.
    (Actually I had the same web.xml before except that it didnt have the /classes in front in the
    url-pattern. I was able to access it by the same url - without the /classes - and then the next day
    when started tomcat and tried to access it, it didnt work, same error.)
    In this example, cucoweb is the context root, correct ? Shouldn't the url-pattern be relative to the
    context root ? Thats how I have it now, I think.
    Would adding my webapp directory, ie cucoweb/classes, to my CLASSPATH help ?
    I'm in ubuntu, when I do echo $CLASSPATH, I get :
    .:/usr/lib/jvm/java-6-sun-1.6.0.00/lib:/usr/lib/jvm/java-6-sun-1.6.0.00/imq/lib/:/usr/lib/jvm/java-6-sun-1.6.0.00/jre/lib
    I havent tried this yet because doing this is kind of tricky in ubuntu. (You have etc/environment and
    bash.bashrc, for ex.) But if I try that and it works I will post about it. I suspect its something else,
    though, because it worked once, before restarting tomcat, thats why I'm posting here first.
    Any info, even educated guesses, would be greatly appreciated. Thanks in advance.

    Thanks for the reply. Here is my web structure :
    /usr/local/tomcat/apache-tomcat-6.0.14/webapps/cucoweb/WEB-INF/classes
    From my understanding you are supposed to have your own webapp deployment directory
    under webapps, ie, cucoweb, and not use webapps/ROOT. (I'm not sure what /ROOT is even for)
    My web.xml is in WEB-INF. My /classes directory contains HelloServlet.class and a directory
    called coreservlets which contains HelloServlet2.class.
    I'm not sure what you mean by 'better you to delete under tomcat/work/catalina/localhost folder'.
    Can you please clarify ?
    FYI, my work/catalina/localhost contains the following :
    cucoweb docs examples host-manager manager
    Here cucoweb just contains a SESSIONS.ser file. Are you saying i should delete that ?

  • Javac: invalid flag: C:\XML\web.xml

    Hi,
    I created a file web.xml in JCreator. When I tried to compile the file, it showed:
    javac: invalid flag: C:\XML\web.xml.
    Does any know how to solve the problem?
    Thanks in advance.
    Dan

    The following is the full message showed after the compiling. It also happened to *.jsp files.
    --------------------Configuration: <Default>--------------------
    javac: invalid flag: C:\XML\web.xml
    Usage: javac <options> <source files>
    where possible options include:
    -g Generate all debugging info
    -g:none Generate no debugging info
    -g:{lines,vars,source} Generate only some debugging info
    -nowarn Generate no warnings
    -verbose Output messages about what the compiler is doing
    -deprecation Output source locations where deprecated APIs are used
    -classpath <path> Specify where to find user class files
    -cp <path> Specify where to find user class files
    -sourcepath <path> Specify where to find input source files
    -bootclasspath <path> Override location of bootstrap class files
    -extdirs <dirs> Override location of installed extensions
    -endorseddirs <dirs> Override location of endorsed standards path
    -d <directory> Specify where to place generated class files
    -encoding <encoding> Specify character encoding used by source files
    -source <release> Provide source compatibility with specified release
    -target <release> Generate class files for specific VM version
    -version Version information
    -help Print a synopsis of standard options
    -X Print a synopsis of nonstandard options
    -J<flag> Pass <flag> directly to the runtime system
    Process completed.

  • Error in faces-config.xml, sun-web.xml, web.xml

    Hi
    I am new bea in jsf. I tried the tutorials for JSF and found that faces-config.xml, sun-web.xml and web.xml gives me following errors:
    faces-config.xml
    <faces-config xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd"
    version="1.2">
    CANNOT FIND THE DECLARATION OF FACES_CONFIG
    sun-web.xml
    <!DOCTYPE sun-web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 8.0 Servlet 2.4//EN" "http://www.sun.com/software/appserver/dtds/sun-web-app_2_4-0.dtd">
    NO ROUTE TO CONNECT TO HOST.
    I am not able to get the required dtds from sun's website, and it will not work anyways if I am not connected to internet.
    I thought I need to copy the desired dtds, and xsds in the classpath. I tried that and copied the requird path in xmls, but it still does not work. Please help....

    Hi
    I am new bea in jsf. I tried the tutorials for JSF and found that faces-config.xml, sun-web.xml and web.xml gives me following errors:
    faces-config.xml
    <faces-config xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_1_2.xsd"
    version="1.2">
    CANNOT FIND THE DECLARATION OF FACES_CONFIG
    sun-web.xml
    <!DOCTYPE sun-web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 8.0 Servlet 2.4//EN" "http://www.sun.com/software/appserver/dtds/sun-web-app_2_4-0.dtd">
    NO ROUTE TO CONNECT TO HOST.
    I am not able to get the required dtds from sun's website, and it will not work anyways if I am not connected to internet.
    I thought I need to copy the desired dtds, and xsds in the classpath. I tried that and copied the requird path in xmls, but it still does not work. Please help....

  • JSP, JavaBean, web.xml - how to fit together?

    Servlets should be placed into the web.xml file to be recognized correctly by a application server.
    Is this also true for JavaBeans (NOT Enterprise JavaBeans!)? Since I don't call a JavaBean directly but only over tags within a JSP I'm not sure about this. If I have to put it in there, do I use the same syntax?
    e.g.:
    <servlet>
    <servlet-name>exampleBean</servlet-name>
    <servlet-class>example.exampleBean</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>exampleBean</servlet-name>
    <url-pattern>/exampleBean</url-pattern>
    </servlet-mapping>
    By using this, the will server know that this Bean has to be deployed?
    Since I'm pretty new to this topic I'm grateful about any comment.
    Thanks in advance!

    Hi,
    JavaBean are java classes and they must be on the classpath in order to be loaded.
    only servlet,jsp,filters,listeners must be declared in the web.xml file. all the java classes can be put under /WEB-INF/lib in order to be loaded by the appserver
    hope it helps,
    Giovanni

  • Console WAR deployment editor tool damage my web.xml file

    I put many servlet and servlet-mapping items in web.xml file. When I deployed my
    web app into weblogic 7.0 SP1 server, I use the console to open the deployment
    description, and change some parameters for the servlet. After I clicked the persist
    button, the web.xml file was changed, but some servlet and servlet-mapping items
    was removed unexpected.
    Why?
    When I start the server in Development mode, this error occured rather often.
    In the product mode, this error occured a few times.
    My operation steps:
    1. undeploy the original app from console
    2. copy the new war file to the applications directory, overwrite the old one
    3. use the console to open the deployment description, make the changes
    4. persist the changes
    5. re-deploy the web app
    Please give the solution as soon as possible

    The tag
    <target name="deploy" depends="clover-yes, clover-no">...is never closed.
    close that tag:
    <target name="deploy" depends="clover-yes, clover-no">
         <javac srcdir="${src.dir}" destdir="${classes.dir}" classpath="${libs}" debug="off" optimize="on" deprecation="on" compiler="${compiler}">
              <include name="org/apache/commons/fileupload/**/*.java" />
              <include name="com/portalbook/portlets/**/*.java" />
              <include name="com/portalbook/portlets/content/**/*.java" />
         </javac>
    </target>Second error is that the depends in there (clover-yes, clover-no) are not existing as targets in your xml.

  • Orion-web.xml

    What is the siginificanc of orion-web.xml file with respect to 9iAS? It seems to be like a configuration file. But I would like to know where it comes into picture and what role it plays with forms9i/9ias.
    Thanks in advance
    Sheba

    Sheba,
    you use this file to define classpath settings and virtual mappings for a Web deployment context, like /forms90.
    For example: defining
         <virtual-directory virtual-path="/img" real-path="D:\appImages/myImages" />
    in the forms deployment context to access images on the Web will make them accessible through
    http:// server :Port/forms90/img/<image name>
    The virtual directory is created under the context root of the deployment owning the orion-web.xml file
    Frank

  • WEB.XML gives me an error while deploying a Web Application in Weblogic 5.1

    I have a Web.xml which I copied the one from their documentation and edited for my servlet specific data. When I try to deploy it I am getting the following error.
              Wed Nov 15 17:10:37 EST 2000:<E> <HTTP> Error reading Web application 'C:/tomcat
              /webapps/La/'
              java.net.UnknownHostException: java.sun.com
              Can you throw some light on this? I have included the first three lines from the WEB,XML file where weblogic is choking.
              <?xml version="1.0" encoding="UTF-8"?>
              <!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN'
              'http://java.sun.com/j2ee/dtds/webapp_2_2.dtd'>
              Thank You
              Trisula P. Siripurapu
              

              Hi Jacek,
              Thank you for your suggestion. I changed the Web App version to 1.2 instead of 2.2. It worked. Thanks once again for the timely response. I really do appreciate it.
              Trisula Pani Siripurapu.
              Jacek Laskowski <[email protected]> wrote:
              >"Trisula P. Siripurapu" wrote:
              >>
              >> I have a Web.xml which I copied the one from their documentation and edited for my servlet specific data. When I try to deploy it I am getting the following error.
              >> Wed Nov 15 17:10:37 EST 2000:<E> <HTTP> Error reading Web application 'C:/tomcat
              >> /webapps/La/'
              >> java.net.UnknownHostException: java.sun.com
              >
              >I remember having the same problem before I added the latest service
              >pack (SP 6). If you don't want to download it, just change DOCTYPE to
              >
              ><!DOCTYPE web-app PUBLIC '-//Sun Microsystems, Inc.//DTD Web Application
              >1.2//EN' 'http://java.sun.com/j2ee/dtds/webapp_2_2.dtd'>
              >
              >and it should work. Notice the change of Web Application version - 1.2
              >rather then 2.2. I'm (almost) sure, I saw one example - examples/webapp
              >(?) - with this header. Take a look at the accompanying examples.
              >
              >When you apply SP6, things should work as they suppose to.
              >
              >> Trisula P. Siripurapu
              >
              >Jacek Laskowski
              

  • Web application and web.xml

    i have a web application consisting of 1 servlet and 5 jsps.
    the start point would be index.jsp
    i use firmwide login page. after login, i want the browser to display index.jsp page.
    In web.xml, i have defined -
    <welcome-file-list>          <welcome-file>/jsp/index.jsp</welcome-file>     </welcome-file-list>       <servlet>        <servlet-name>UtilitiesServlet</servlet-name>        <servlet-class>com.gs.fw.sox404.utilities.UtilitiesServlet</servlet-class>             <init-param>             <param-name>util-log4j-init-file</param-name>             <param-value>/WEB-INF/classes/util_log4j.properties</param-value>          </init-param>        <load-on-startup>1</load-on-startup>    </servlet>     <servlet-mapping>        <servlet-name>UtilitiesServlet</servlet-name>        <url-pattern>/UtilitiesServlet</url-pattern>    </servlet-mapping>if i define it as just index.jsp in the welcome file list, after successful login, it displays the dir structure of the web app.
    if i define it as jsp/index.jsp, then in some of the pages, it tries to find the servlet inside jsp folder.
    What would be the best way to get around this?

    Well, yes, it's not able to find it because you've not understood the mechanism of how it works clearly. You have to put your welcome file under every directory you want it to be used from. Like I said, it's not a path, it's a filename. So if the container sees that your request URL is for a directory, it'll look for the welcome files from the welcome file list, one by one, in the order of declaration. Whichever one it finds first, it'll serve that. If it doesn't find any, then it'll either give a 404 or a directory listing depending on the server and it's settings.
    So your problem is that you've put your index.jsp in your JSP folder but expect it to be served for all URLs. That won't happen, you'll have to put one file named index.jsp into every directory. The reasoning is pretty simple, what if you want different behaviour for each folder?
    This should fix your problem :)
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://faq.javaranch.com/java/HowToAskQuestionsOnJavaRanch
    ----------------------------------------------------------------

  • How do you modify the web.xml to lock down the pages from a user role

    how do you modify the web.xml to lock down the pages from a user role

    I'll make a stab at your question:
    The following is an example of where a URL is protected within a web.xml deployment descriptor. In this example, the URL /protectedA within the application is protected:
    <!-- security constraints -->
    <security-constraint>
    <web-resource-collection>
    <web-resource-name>protectedA</web-resource-name>
    <url-pattern>/protectedA</url-pattern>
    </web-resource-collection>
    <!-- authorization -->
    <auth-constraint>
    <role-name>sr_developer</role-name>
    </auth-constraint>
    </security-constraint>
    Sun's explaination here:
    http://java.sun.com/j2ee/1.4/docs/tutorial/doc/Security4.html

Maybe you are looking for

  • Changing Field Description in  T.Code FBCJ

    Hi SAP Gurus, I am facing a problem with the T.Code FBCJ.  In our organisation we have several branches where they use to save the Cash Payment transactions, they do not post it.While posting the transaction at HO, if the authorised person finds that

  • Question re templates and workflow

    I have an elementary question, as I've recently taken charge of a Captivate project in progress. (I will not be doing the Captivate programming). Is the following workflow possible: 1. Create a template for an on-line course which is composed of 4 mo

  • Select Checked Out Files

    In the Files panel, if I use the option "Select Checked Out Files", Dreamweaver will always crash (I just tried out and am waiting for DW to fall apart). Does anyone know how to overcome this (yes, without ditching DW)?

  • Portal error while using BI template created by Web appliaction designer

    Hello Guys, I am getting error Portal Runtime Error An exception occurred while processing your request Exception id: 03:58_20/08/08_0031_7258650 See the details for the exception ID in the log file. while checking template from BI menu . And if i am

  • When i click acrobat a pd on my desktop, i get "illegal instruction" message?

    ? when i click a pdf on my desktop, i get "illegal instruction" message?