Legacy servlets

greetings,
I am used to working with apache servers with the tomcat servlet engine, which is compliant with the servlet 2.3 specs -- entails the concept of web applications that are self contained . I am now working with an s1ws , specifically on a virtual server, and two directories have been created for me: 'public_html' and 'classes'. The public_html directory contains jsp/html and static content. The classes directory contains the servlet packages and classes.
I am told that the servlet path is http:/domain_name:8000/servlet/ and I am also told that I must register the servlets with the server.
How does one go about registering the servlets with the web server. Is is as simple as creating a deployment descriptor and placing it in the classes directory? According to servlet 2.3 specs the classes directory is supposed to be inside of the WEB-INF directory which contains the file web.xml. I have no WEB-INF directory. Any one know what the deal is?
much obliged
-Mani

First, note that Web Server 6.1 supports Servlet 2.3 web applications and Web Server 6.0 supports Servlet 2.2 web applications.
"Legacy Servlets" refers to a Servlet deployment methodology that predates both Servlet 2.2 and Servlet 2.3 (and hence predates the concept of web applications). Legacy Servlet support was deprecated in Web Server 6.0 and removed in Web Server 6.1. For information on using Legact Servlets, refer to the Programmer's Guide to Servlets at http://docs.sun.com/db/prod/s1websrv#hic

Similar Messages

  • Legacy Servlet to JSF

    Hi,
    I am writing an application in JSF that will replace another Java Servlet but perform the same functions. The first step is to establish the front page in JSF with all the options, but link to the legacy servlet for all those options, and replace them one by one until the legacy servlet is gone.
    I would like to run both applications in seperate containers, and use HTTP to redirect back and forth. Problem is, I don't know how to tell the legacy servlet to use the sessionid it has already established.
    The first time I call to the legacy servlet, it will create a session, and I can acquire the sessionid from HttpSession.getSessionId(), then pass that back (somehow, haven't figured out yet how to call into the JSF servlet either). But once that has been done, I can provide that sessionid in any legacy servlet invocation.
    Is this simple to do? How would I go about it?
    The next problem I have is securing this transmission, which would probably entail encryption. Perhaps I should just be running these two servlets in the same context and avoid all this confusion.
    Ideas?
    Thanks for any suggestions.

    Hi,
    Before starting the very first JSF page (and before
    the JSF front controller is invoked) I must use a
    servlet to read some parameters, init some objects
    and then jump to the first JSF page. Some objects
    that the bean generates must be saved in a JSF
    managed bean.
    The question is, how can I set those parameters in
    the managed bean if it wasn�t still initialised ?
    Code like this:
    ApplicationFactory factory = (ApplicationFactory)
    FactoryFinder.getFactory(FactoryFinder.APPLICATION_FAC
    TORY);
    Application app = factory.getApplication();
    ValueBinding vb =
    app.createValueBinding("#{AManagedBean}");
    AManagedBean mb=  (AManagedBean)
    vb.getValue(FacesContext.getCurrentInstance());     Fails with a null pointer exception (it seems to not
    t be finding �AmanagedBean�).
    you didn't even set the value, thats why you are getting a "null pointer exception". Try
    vb.setValue(FacesContext.getCurrentInstance(), AManagedBean)
    >
    Do you know how to set the properties in the
    s in the managed bean ? Any comment or help would be
    really welcome.
    First set any properties of the "AmanagedBean" and then create the value binding in any of the scopes(request, seesion, application)
    >
    Thanks in advance,
         - Juan

  • How migrate legacy servlets iPanet 4.1 to iPlanet 6.1

    Hi all.
    I have installed Java webserver 6.1on solaris.
    I cant migate my legacy servlets running on iPlanet 4.1 to Iplanet 6.1
    How do I do that?
    Please help me!!!
    PS: Is that possible?
    Thanks

    Hi Manish
    Thanks for your answer .
    We have verified what IPlanet 6.1 can deploy one sigle Legacy Servlet as "/".
    We need to deploy more than one servlet.
    Can You please explain me how can I deploy that on Single Virtual server 6.1 ?
    Thanks
    dany74

  • Deploy legacy servlet in S1AS

    Hi,
    Does S1AS support legacy servlet? As I know, Web Server 6.x support legacy servlet.
    Thanks

    Hi,
    I am getting this error....
    HTTP Status 404 - /servlets-examples/servlet/SendData
    type Status report
    message /servlets-examples/servlet/SendData
    description The requested resource (/servlets-examples/servlet/SendData) is not available.
    Thx,
    Babloo

  • With iPlanet6.0 how can I include servlets in the cgi directory?

    I have created a cgi directory ex. http://hostname/cgi-bin to refer to the cgi.exe's. However.. I have developed a new servlet that replaces one of the cgi programs. The servlet context must fit in with our existing architecture so the servlets context must map to the cgi URL we have in place. This works fine with every web app server under the sun .. even Sun One7... but not on iPlanet 6.0. This is because it seems that every resource mapped by a CGI directory must be a CGI program - the web server doesn't have the intelligence to know that a servlet with the same context is available and so when the CGI directory is enabled... the servlet is not found, yet when it is removed the servlet is referenced just fine.
    Has anyone any ideas? Unfortunately I can't change the context of the servlet as our existing systems depend on the original cgi structure.
    Many thanks,
    Mark

    Right /cgi must reference a cgi and /servlet is for legacy servlets that arent deployed as applications.
    I dont think you are going to make it work like that, maybe do a redirect from /cgi/cginame to /servlet/servletname . That's the only thing that may work.

  • Exposing business objects in an existing Servlet WebApp as Webservices

    Hi,
    I am extending a legacy Servlet application (running under Tomcat 5.5).
    I want to expose a class as a web service. What is the best way to do this ?
    I have tried these so far without much success
    1. Dropped Axis2.war in WebApp with my web service as a .aar file in services.
    This introduces additional issues like intra-webapp communication.
    The Webservice implementation uses objects in the legacy servlet.
    I am yet to find a simple standard mechanism to achieve this.
    2. Embed Axis2 inside the servlet.
    I followed the following example to do this.
    http://hacimbengali.blogspot.com/2007/05/adding-axis2-webservice.html
    Basically, wrote another servlet, extended from AxisServlet and
    added my POJO as a service. The code seems to execute without generating exceptions, but I am unable to invoke
    my webservice or generate the WSDL from the browser by issuing http://localhost:8080/axis2/services/myservice?wsdl
    The same class works if I make calls from a java console app and start SimpleHTTPServer.
    So I am puzzled why this does not work in Tomcat
    My code
    //----------------------------------begin code--------------------------------------------------------
    public class AxisXServlet extends org.apache.axis2.transport.http.AxisServlet {
    static final long serialVersionUID = 1L;
    /* (non-Java-doc)
         * @see javax.servlet.http.HttpServlet#HttpServlet()
         public AxisXServlet() {
              super();
         /* (non-Javadoc)
         * @see javax.servlet.GenericServlet#init()
         public void init(ServletConfig config) throws ServletException
         super.init(config);
         AxisService service;
         try {
         service = AxisService.createService(
                   FPWSImpl.class.getName(),
                   axisConfiguration);
         //RPCMessageReceiver.class);
         //service.setName();
         axisConfiguration.addService(service);
         axisConfiguration.startService(service.getName());
         } catch (AxisFault e) {
         e.printStackTrace();
    //----------------------------------------end code-----------------------------------------------------------

    Hi ialexei,
    Have got the solution for your problem?. If yes, please post it here. I have same situation like this.
    I have developed a java web application and the purpose of the application is to fetch the data which are updated or new from another site using their remote services. This operation is being performed in a fixed interval using a timer in my application. After getting the result from remote site, presently, I am keeping it in memory (Need at least 512 MB RAM). I have created a servlet and created some methods. These methods are accessible by passing the methodname as query parameter while calling the servlet. I have also created a web service for the methods which are available in servlet (in a separate class).
    I have deployed the web service on Tomcat 5.0/Axis and web application on Tomcat ( same instance of Tomcat). Since one is web service and other is web application, I am duplicating the business logic/components and both are running separately also. I would like to use my business logic/components on either in web service or web application and divert the call from one to other.
    I mean,
    (1) if I use the business logic/components on web service, then from my servlet, I would like to call the web service and return the result
    (2) if I use the business logic/components on web application, then from my web service, I would like to call the servlet and return the result
    Pl. advice me which one from the above methods is good and how to implement that.
    --Sabeer                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Servlets on IPlanet 6.0

    Hi,
    In the near future, I am going to be upgrading IPlanet Web Server 6.0 to Sun One Web Server 6.1. One concern that I have is migrating a servlet from 6.0 to 6.1. How, if this is possible can I do this?
    Any help is greatly appreciated.
    Thanks

    Take a look at the following docs, it has a section on migrating legacy servlets if that's your concern.
    http://docs.sun.com/source/817-1833-10/pwasrvlt.html
    Thanks
    Manish

  • Running Servlets

    I have installed Sun Java Web Server on my XP computer. It can handle JSP pages without a problem. But it doesn't handle servlet classes. Any ideas. I comile a srevlet class and place the bytecode class in a directory on my wev server folder. When I try to access the servlet, the browser returns with error 404.
    Many thanks in advance
    Akz

    You must put your servlet into a "Web Application". This Web Application can be a "root" web app, which closely matches the old "legacy servlet" idea.
    So.... let's say your HTML documents directory is located at c:/docs (or wherever, may not be on a Windoze box, but that's okay).
    Go into your server.xml and inside the <VSCLASS> element add a line line this:
    <WEBAPP uri="/" path="c:/docs" enabled="true" />
    I put mine right after the </SEARCH> line.
    Then create c:/docs/WEB-INF/classes, and put your servlet class file there (such as c:/docs/WEB-INF/classes/helloworld.class).
    Restart the web server.
    Access http://yourmachine/servlet/helloworld
    This works for version 6.1. Things are slightly different with older versions.
    David

  • WS7 - alternative to ServletByExt?

    Hello,
    I was able to migrate an old server instance from WS6.0 to WS7, but I saw one message in the migration log that is problematic:
    INFO   : Servlet by extension is not supported. The following line will be removed
    from obj.conf: "NameTrans fn="pfx2dir" from="/servlet" dir="/opt/iDA/nda/classes"
    name="ServletByExt""Indeed, that line was removed, and the application that it refers to (the old iPlanet Delegated Administator from MS5.2) does not work as a result.
    Since my MS installation is still using directory schema 1, I have to use iDA 5.2 to delegate user provisioning. Is there a way that I can convert this webapp to a form that will work on WS7, or will I continue to have to run a WS6.0 instance indefinitely?
    Thanks,
    Bill

    Hi
    It is very unfortunate that we didn't put this issue in the docs so that you can easily find a way to overcome this issue.
    here is a corresponding url that shows as how to migrate the 'legacy servlets and servlet by extension' to 6.1 . the same document also holds true for 7.0 as well.
    http://docs.sun.com/source/817-1833-10/pwax-mig.html
    in simple terms, what u will need to do is
    - back up your iDA application
    - create a web application directory structure like
    WEB-INF , WEB-INF/classes WEB-INF/lib under iDA web application
    - now move your class files under WEB-INF/classes directory
    - now, you will need to create a web.xml under WEB-INF to reflect the appropriate configuration.
    af course, if u need any professional guidance, you should contact Sun
    considering that , WS6.0 is way past EOL, you might wanna consider moving to newer releases like 6.1 or 7.0 at your earliest convenience

  • JSC 2.1 ignores path properties in nbproject/project.properties ?

    Hi,
    I have to import a Netbeans 5.0 project into JSC 2.1 in order to use the JSF UI designer. The project has the Java BluePrints source structure with all folders external to the Netbeans project folder (because it was created with other tools in the past). It is a mix of legacy servlets, plain JSP and JSF pages.
    In Netbeans it was no problem to import the source tree by using the option "Web Application with Existing sources" from the project wizard and tweaking the pathes in nbproject/project.properties. In JSC this option does not exist. Also I cannot just move all the sources into a standard JSC project folder since it is a large project in a CVS repository. Also I cannot use softlinks since some people work on the project using Windows and some use Linux.
    So I tried to edit the path settings in nbproject/project.properties manually. Here are the relevant lines I changed from a default JSF project created by the JSC wizard I used to manually import the project into JSC:
    conf.dir=${file.reference.jsctest-src}/conf
    file.reference.jsctest-test=../../test
    file.reference.jsctest-web=../../web
    file.reference.jsctest-src=../../src
    jsf.pagebean.package=jsctest
    jsf.project.libraries.dir=lib   # <-- not sure what goes in here
    source.root=${file.reference.jsctest-src}
    src.dir=${file.reference.jsctest-src}/java
    test.src.dir=${file.reference.jsctest-test}
    web.docbase.dir=${file.reference.jsctest-web}The web.xml, faces-config.xml, ... etc. are all prepared for JSC. JSC seems to understand it and opens it correctly and list the external folders like Netbeans would. But when I try to add a new JSF UI based page I get a NullPointerException. From the message log:
    java.lang.reflect.UndeclaredThrowableException
         at $Proxy14.actionPerformed(Unknown Source)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
         at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
         at java.awt.Component.processMouseEvent(Component.java:5488)
    Caused by: java.lang.NullPointerException
         at com.sun.rave.api.jsf.project.ui.WebFormIterator.instantiate(WebFormIterator.java:131)
         at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:557)
         at org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:396)
         at org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:218)
         at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1425)
         at org.openide.WizardDescriptor.access$900(WizardDescriptor.java:63)
         at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1327)
    [catch] ... 67 moreWhen I look into the files view of the project I see that JSC recognizes the classes in the external source packages folder like Netbeans would. But it creates at the same time a non-existing folder named src below the JSC project folder which contaings an empty folder named "jsctest" (the default package name I selected for page beans).
    So it seems some part of JSC (the web designer?) ignores the path settings in nbproject/project.properties while others (the code from NB4.1?) does not. When I move all project sources into the JSC project folder in their standard location it works but as I wrote above doing that is not an option because CVS etc..
    Or do I have to set some additonal properties in the project for the designer? Or is there any other way to import such a legacy project to create new JSF pages with the designer (we cannot change all servlets / pages at once).
    Or is it just a bug in JSC 2.1 I should report? Or is it a unsupported feature JSC will never support?
    Thanks in advance,
    regards,
    Thomas

    Thanks for your answer.
    Unfortunately, as I described in my inital posting, it is not possible for me to do a refactoring of the source structure in Netbeans because the project is based on a CVS repository and I cannot change the pathes there for several reasons. The web folder and sources folder are outside of the Netbeans project folder anyway. I just thouhgt that JSC would read the pathes from the project.properties file like Netbeans but that doesn't seem to be the case.
    I guess we have to wait for the next JSC version or check out other options.
    Thanks anyway,
    Thomas

  • CGI directory conflicts with DOC root directory

    Hello.
    I have the following problem with Sun ONE Application Server 7 Update 3:
    I have to execute some CGI exe files on SOLARIS server. Exe files uses js and other files, and searches them in the predefined directory "/SOMEDIR/".
    So, in the App Server web admin console (http://...:4848) I set the DOCUMENT ROOT to the directory on the server the level upper than "/SOMEDIR/". And I add "/SOMEDIR/" as the CGI directory.
    After that the following happening:
    Then I enter the docroot: http://myserver/
    I can enter into all subdirectories of it BUT "/SOMEDIR/"!
    Then I execute CGI exe: http://myserver/SOMEDIR/my.exe
    than that my.exe doesn't have the access to the files in http://myserver/SOMEDIR/.
    Then I disallow CGI in admin console, than I gain access to the subdirectory SOMEDIR from the docrrot!
    Can anybody tell me what the problem could be?

    Right /cgi must reference a cgi and /servlet is for legacy servlets that arent deployed as applications.
    I dont think you are going to make it work like that, maybe do a redirect from /cgi/cginame to /servlet/servletname . That's the only thing that may work.

  • Iws 6.0 problems server web-app

    It seems that the "send-file" function is attempting to handle the
    servlet request, looking
    in the application's root and not finding the resource - It returns a
    404.
    The servlet classes live under the directory {application
    root}/WEB-INF/classes...
    and they are not "legacy" servlets.
         Any tips appreciated.

    I've not seen this crash before but I am interested to know more about it..
    Does it always crash in ldap_x_free function? Do you have a stack trace for this crash? Is this instance configured to use any 3rd party plugins? Which ldap server are you using?
    Thanks
    Manish

  • Configuring SunOne Web Server6.1 for JSTL ...?

    I understand there was discussion already on this topic but I seem to not understand that the only solution is war file as mentioned by writer: hari.developer.
    Mr. Hari was answering to the topic: "JSTL and SUNOne Web Server 6.1 SP2" on: Oct 28, 2004 11:20 PM. His comments are in the end.
    Basically, I was even unable to run examples from JavaServer Pages 3rd Edition by Hans Bergsten on my Sun ONE web server 6.1 where I kept getting JSTL errors... errors were complaing about the uri issue. The book examples are download-able but they don't come in war file. I tried creating a war file but received further errors.
    THere has to be a solution to this on SunOne. I would request someone from Sun to please answer this b/c many developer are lost and doing funny things to get the work done. I have seen one post where putting jstl.jar is put in WEB-INF directory and given URI is pointing to it. I don't like this idea so ask anyone who has a solution please help
    here are the errors on my machine:
    GET /myapp/login.jsp, service-j2ee reports: StandardWrapperValve[jsp]: WEB2792: Servlet.service() for servlet jsp threw exception
    org.apache.jasper.JasperException: WEB4117: This absolute uri (http://java.sun.com/jstl/core) cannot be resolved in either web.xml or the jar files deployed with this application
    Here is my simple jsp file from above mentioned book:
    <%@ page contentType="text/html" %>
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
    <%@ taglib prefix="fn" uri="http://java.sun.com/jstl/functions" %>
    <html><body bgcolor="white">
    <h1>Welcome to the Project Billboard</h1>
    <p>
    <font color="red">${fn:escapeXml(param.errorMsg)}</font>
    <form action="authenticate.jsp" method="post">
    <input type="hidden" name="origURL" value="${fn:escapeXml(param.origURL)}">
    Please enter your User Name and Password, and click Enter.<p>
    Name:
    <input name="userName" value="${fn:escapeXml(cookie.userName.value)}" size="10">
    Password:
    <input type="password" name="password" value="${fn:escapeXml(cookie.password.value)}" size="10">
    <input type="submit" value="Enter">
    <p>
    Remember my name and password:
    <input type="checkbox" name="remember" ${!empty cookie.userName ? 'checked' : ''}>
    <br>
    (This feature requires cookies to be enabled in your browser)
    </form>
    </body>
    </html>
    Hari wrote the following:
    In Web Server 6.1 and Service Packs, legacy servlets is not supported and do not work.
    While JSPs do work it is not supported and it will not be able to lookup "Webapp" resources like WEB-INF\lib even if you create it in the doc root. You will need to package your JSPa and TLDs as a webapp (WAR) and deploy it on the webserver for this to work.

    I realize that it is nearly 4 years later, but did anyone figure out a way to use jstl with SunOne 6.1?

  • GetRealPath isn't working in iWS 6.0

    Hi,
    I'm using iWS 6.0 sp2 on solaris 8. I have a problem with the method getRealPath, because it always returns null, even if it is not deployed in a war file. I'm using it in a legacy servlet, and all the same it returns null. I have tried this with version 4.1, and it works all right.
    This looks like a bug, doesn't it?
    Juan

    Try this:
    1) Settings
    2) General
    3) Reset
    4) Reset Network Settings
    This will reestablish the link for the cellular connection and the cellular data as well as the saved WiFi connections will be reset.
    Also Check this:
    1) Settings
    2) Messaging
    3) Ensure iMessage is turned on (sometimes it will turn itself off for some reason)
    4) Press on Send & Receive
    5) Ensure that all emails you want to be reached at as well as your phone number are listed there
    Remember that iMessage requires a data connection so with out either cellular data or WiFi it will not work.

  • Deploying a WAR file containing .jsp and servlets (also uses JNI)

    Deploying a WAR file containing .jsp and servlets (also uses JNI) on Windows 2000
    We had problems making it initially work on Sun ONE Web Server 6.0 Service Pack 1 because of lack of good iPlanet Web
    Server documentation on deploying such files.
    This is how we went about it:
    1) Make one of the servlet and JSP (must call another Java Class) web application (.war) examples work with iPlanet Web
    Server.
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\HelloWorld\HelloWorld.war
    and
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    a) Go to your Web Server Administration to deploy the application using GUI Web Application Deploy.
    (We usually use command line, we experienced some issues with the GUI version, but maybe it is fixed in the new Web Server
    service packs)
    From browser, open http://yourserver:8888/
    Click on Select a Server:Manage
    Click on Virtual Server Class
    Click on https-yourserver
    Click on the Web Applications Tab
    Then, click on Deploy Web Application
    Enter the following -
    WAR File On: Local
    WAR File Path: C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Application URI: /jakarta
    Installation Directory: c:\iPlanet\examples\jakarta-examples
    By clicking on OK it deployed the application.
    I can verify that it is deployed by selecting "Edit Web Applications" and I see the following entry:
    Edit     /jakarta     c:/iPlanet/examples/jakarta-examples
    Also, c:/iPlanet/examples/jakarta-examples should have the similar following directory structure ..
    - [images]
    - [jsp]
    - index.html
    - [servlets]
    - [META-INF]
    - [WEB-INF]
    - [classes]
    - [tlds]
    - web.xml
    - index.html
    I restarted the server and accessed it using the following URL from my IE browser:
    http://yourserver/jakarta/index.html
    Then I clicked on the JSP Examples and tried some JSP examples.
    b) Alternatively, you can also deploy the same example from the command-line.
    Make sure C:\iPlanet\Servers\bin\https\httpadmin\bin\ is in your path
    wdeploy deploy      -u /jakarta
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\jakarta-examples
              C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Restart the web server (I don't think you have to restart, but .. might as well).
    2)Deploy your web-application
    My Foo.war has the following structure.
    You can use jar tf Foo.war to look at the file contents from command line (assuming you have JDK installed and the bin is
    in your PATH)
    Foo.war
    - [META-INF]
    - [WEB-INF]
    - web.xml
    - [classes]
    - Bar.class
    - MoServlet.class
    - [lib]
    - ThirdParty.jar
    - [natlib]
    - extlib.dll
    - foo.jsp
    Here is our application scenario:
    foo.jsp uses a class call Bar (it is not in any package). The Bar java class uses classes from ThirdParty.jar. The
    ThirdParty.jar in turn uses JNI to load library extlib.dll. foo.jsp also calls /servlet/Mo as well.
    Now to deploy it, do the following:
    (a) Make sure that within foo.jsp, you import the Bar class ( I don't know why you have to do it, but if you don't you get
    JSP compile error).
    <%@page language="java" import="Bar" contentType="text/html"%>
    (b) Check web.xml (for Servlets)
    Within web.xml, make sure you have the following mappings:
    <servlet>
    <servlet-name> MoLink </servlet-name>
    <servlet-class> MoServlet </servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name> MoLink </servlet-name>
    <url-pattern> /servlet/Mo </url-pattern>
    </servlet-mapping>
    (c) Deploy the application
    Using command line:
    wdeploy deploy      -u /foo
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\foo-dir
              Foo.war
    (d) Change web-apps.xml file (for picking up ThirdParty.jar)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    You should see something similar to following after successful deployment.
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true"/>
    Change it to look like following to pick up the ThirdParty.jar
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true">
    <class-loader reload-interval="300"
              classpath="C:/iPlanet/examples/foo-dir/WEB-INF/lib/ThirdParty.jar"
              delegate="false"/>
    </web-app>
    (e) Change jvm12.conf file (for JNI)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    Add or uncomment the following lines:
    #optional - just helps with instrumenting the jsp and servlet code
    jvm.include.CLASSPATH=1
    jvm.enableDebug=1
    nes.jsp.enabledebug=1
    jvm.trace=7
    jvm.verboseMode=1
    #required for JNI
    java.compiler=NONE
    jvm.classpath=.;C:\JDK1.3.1\lib\tools.jar;C:/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;
    jvm.option=-Xrs
    jvm.option=-Xnoagent
    # not sure if this is needed for iPlanet web server
    jvm.option=-Djava.library.path=C:/iPlanet/examples/foo-dir/natlib/ -Djava.compiler=NONE
    (f) Change magnus.conf file (for JNI)
    We HAD to change this file in order for ThirdParty.jar file to pick up the native C++ code using JNI. Apparently, the
    iPlanet Web Server doesn't pick the Environment Variable Path. Because when we had the directory containing the DLL just
    in Path, it didn't work.
    Change Extrapath directive:
    ExtraPath C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    to
    ExtraPath c:/iPlanet/examples/foo-dir/natlib;C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    (g) Apply changes from the Web Server Administration Console and Restart the web server.
    You should be able to see the behaviour that you want from your application.
    http://yourserver/foo/foo.jsp
    Hope this was helpful!!!
    Sonu

    Deploying a WAR file containing .jsp and servlets (also uses JNI) on Windows 2000
    We had problems making it initially work on Sun ONE Web Server 6.0 Service Pack 1 because of lack of good iPlanet Web
    Server documentation on deploying such files.
    This is how we went about it:
    1) Make one of the servlet and JSP (must call another Java Class) web application (.war) examples work with iPlanet Web
    Server.
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\HelloWorld\HelloWorld.war
    and
    C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    a) Go to your Web Server Administration to deploy the application using GUI Web Application Deploy.
    (We usually use command line, we experienced some issues with the GUI version, but maybe it is fixed in the new Web Server
    service packs)
    From browser, open http://yourserver:8888/
    Click on Select a Server:Manage
    Click on Virtual Server Class
    Click on https-yourserver
    Click on the Web Applications Tab
    Then, click on Deploy Web Application
    Enter the following -
    WAR File On: Local
    WAR File Path: C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Application URI: /jakarta
    Installation Directory: c:\iPlanet\examples\jakarta-examples
    By clicking on OK it deployed the application.
    I can verify that it is deployed by selecting "Edit Web Applications" and I see the following entry:
    Edit     /jakarta     c:/iPlanet/examples/jakarta-examples
    Also, c:/iPlanet/examples/jakarta-examples should have the similar following directory structure ..
    - [images]
    - [jsp]
    - index.html
    - [servlets]
    - [META-INF]
    - [WEB-INF]
    - [classes]
    - [tlds]
    - web.xml
    - index.html
    I restarted the server and accessed it using the following URL from my IE browser:
    http://yourserver/jakarta/index.html
    Then I clicked on the JSP Examples and tried some JSP examples.
    b) Alternatively, you can also deploy the same example from the command-line.
    Make sure C:\iPlanet\Servers\bin\https\httpadmin\bin\ is in your path
    wdeploy deploy      -u /jakarta
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\jakarta-examples
              C:\iPlanet\Servers\plugins\servlets\examples\web-apps\jakarta-examples\jarkarta-examples.war
    Restart the web server (I don't think you have to restart, but .. might as well).
    2)Deploy your web-application
    My Foo.war has the following structure.
    You can use jar tf Foo.war to look at the file contents from command line (assuming you have JDK installed and the bin is
    in your PATH)
    Foo.war
    - [META-INF]
    - [WEB-INF]
    - web.xml
    - [classes]
    - Bar.class
    - MoServlet.class
    - [lib]
    - ThirdParty.jar
    - [natlib]
    - extlib.dll
    - foo.jsp
    Here is our application scenario:
    foo.jsp uses a class call Bar (it is not in any package). The Bar java class uses classes from ThirdParty.jar. The
    ThirdParty.jar in turn uses JNI to load library extlib.dll. foo.jsp also calls /servlet/Mo as well.
    Now to deploy it, do the following:
    (a) Make sure that within foo.jsp, you import the Bar class ( I don't know why you have to do it, but if you don't you get
    JSP compile error).
    <%@page language="java" import="Bar" contentType="text/html"%>
    (b) Check web.xml (for Servlets)
    Within web.xml, make sure you have the following mappings:
    <servlet>
    <servlet-name> MoLink </servlet-name>
    <servlet-class> MoServlet </servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name> MoLink </servlet-name>
    <url-pattern> /servlet/Mo </url-pattern>
    </servlet-mapping>
    (c) Deploy the application
    Using command line:
    wdeploy deploy      -u /foo
              -i yourserver
              -v https-yourserver
              -d c:\iplanet\examples\foo-dir
              Foo.war
    (d) Change web-apps.xml file (for picking up ThirdParty.jar)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    You should see something similar to following after successful deployment.
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true"/>
    Change it to look like following to pick up the ThirdParty.jar
    <web-app uri="/foo" dir="C:\iPlanet\examples\foo-dir" enable="true">
    <class-loader reload-interval="300"
              classpath="C:/iPlanet/examples/foo-dir/WEB-INF/lib/ThirdParty.jar"
              delegate="false"/>
    </web-app>
    (e) Change jvm12.conf file (for JNI)
    It is located in
    C:\iPlanet\Servers\https-yourserver\config
    Add or uncomment the following lines:
    #optional - just helps with instrumenting the jsp and servlet code
    jvm.include.CLASSPATH=1
    jvm.enableDebug=1
    nes.jsp.enabledebug=1
    jvm.trace=7
    jvm.verboseMode=1
    #required for JNI
    java.compiler=NONE
    jvm.classpath=.;C:\JDK1.3.1\lib\tools.jar;C:/iPlanet/Servers/plugins/servlets/examples/legacy/beans.10/SDKBeans10.jar;
    jvm.option=-Xrs
    jvm.option=-Xnoagent
    # not sure if this is needed for iPlanet web server
    jvm.option=-Djava.library.path=C:/iPlanet/examples/foo-dir/natlib/ -Djava.compiler=NONE
    (f) Change magnus.conf file (for JNI)
    We HAD to change this file in order for ThirdParty.jar file to pick up the native C++ code using JNI. Apparently, the
    iPlanet Web Server doesn't pick the Environment Variable Path. Because when we had the directory containing the DLL just
    in Path, it didn't work.
    Change Extrapath directive:
    ExtraPath C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    to
    ExtraPath c:/iPlanet/examples/foo-dir/natlib;C:/iPlanet/Servers/bin/https/bin;${NSES_JRE_RUNTIME_LIBPATH}
    (g) Apply changes from the Web Server Administration Console and Restart the web server.
    You should be able to see the behaviour that you want from your application.
    http://yourserver/foo/foo.jsp
    Hope this was helpful!!!
    Sonu

Maybe you are looking for

  • How do I delete an e.mail on my 5s that has a mime attachment,the e.mail can be read but not deleted.

    How do I delete an e.mail  on my 5s iphone that has a mime attachement? the e.mail can be read but not deleted. A message comes up saying that it cannot be moved! The e.mail was sent to me and I forwarded it. The e.mail is not in any other folder in

  • WHAT? Adobe FLash Player Security

    I am building a photography web site with flash and I found a really cool slide show extension plug in (www.slideshowpro.com) were can easily upload and update my portfolio slide shows. when I publish out to HTML, I test it in a browser and I get thi

  • XSD structure

    Hi, I want to create form designer using XSD document. The idea is like load XSD file, retrieve the structure, display structure in some ui and allow user to select elements and place in designer window. Hence I want to retrieve tree structure from X

  • How can i check apple id use in diffrent iphones

    how i can i check my apple id use in diffrent iphones

  • Finder "Open with" not working on 10.6 any more

    Hi, I am experiencing some issues with finders "open with" > Change all function. It does not work for .doc files any more since Snow Leopard. The "Change all" button is disabled. I can change to pages via the drop down menu but that's it. The button