Configuring Servlets in JavaWebServer2.0
I have installed JavaWebServer2.0 on Windows2000 Professional. I am putting my servlet class files in servlets dir. of JWS.
But I am not able to access my servlets from browser. It is giving 404 error.file not found.
Initially I have done the same thing on Windows98/NT without any problem.
Can anyone tell me the solution.
Thanx.
Ajay.
Hi maruthuams ,
Thanx for immediate reply.
I have set the classpath for JWS bin,lib,servlets directories.
Lib dir.is also having servlet.jar file & other jar files also.
I was able to configure JWS2.0 on Windows98/NT before some months.
I worked a lot in that environment.
Actually there is nothing to configure in it. You just have to put the servlet class files in servlets dir. & access from browser.
Now I have installed JWS2.0 on Windows2000 Professional.I have written simple HelloWorld Servlet & put class file in servlets dir.
Same way I am trying to access the servlets. But now I am getting the error
Not Found (404)
The file that you requested could not be found on this server. If you provided the URL, please check to ensure that it is correct. If you followed a hypermedia link, please notify the administrator of that server of this error.
I am not able to find out whats wrong happening exactly.
Can you let me know what may be the problem ? Do we need to modify any properties files for our servlet class names etc.?
Waiting for your reply.
Thanx in advance.
Ajay
Similar Messages
-
Configuring Servlet API 2.2
Hi,
Is it possible to configure Servlet API 2.2 on portal, or is it not recommended ? I need to install a forum on the oracle http server that use Servlet API 2.2.
Bye byeHi,
Is it possible to configure Servlet API 2.2 on portal, or is it not recommended ? I need to install a forum on the oracle http server that use Servlet API 2.2.
Bye bye -
Configuring Servlet Result Cache
Greetings.
I am trying to configure the iAS servlet result cache feature under iAS 6.0 SP2. I have the following entry for a servlet in my ias-web.xml file:
<servlet>
<servlet-name>MessageRouter</servlet-name>
<guid>{CAC10848-06B4-1C5F-848B-08002085745B}</guid>
<validation-required>false</validation-required>
<servlet-info>
<sticky>false</sticky>
<encrypt>false</encrypt>
<number-of-singles>10</number-of-singles>
<disable-reload>false</disable-reload>
</servlet-info>
<caching>
<cache-timeout>300</cache-timeout>
<cache-size>10</cache-size>
<cache-criteria>Xml</cache-criteria>
<cache-option>TIMEOUT_LASTACCESS</cache-option>
</caching>
</servlet>
However, it does not appear to be caching the results of this servlet because my request takes about 10 seconds to run (it's a database query). I would expect that subsequent requests would return results much faster than 10 seconds if the servlet results are in fact cached.
So, I am hoping that someone can help me with the following questions:
1. An example ias-web.xml with a cached servlet.
2. Any instructions on how to monitor from iASTAT or logs or something so I can see that the servlet result is read from iAS cache.
Thanks
Jeffery CannCheck out the samples included with the appserver. There is a servlet caching sample that includes four different examples of deployment descriptors.
Here is the servlet tag from the default:
<servlet>
<servlet-name>ServCache</servlet-name>
<guid>{DD6402C6-CC11-1AA1-CF6F-080020CFEAC8}</guid>
<validation-required>false</validation-required>
<error-handler></error-handler>
<servlet-info>
<sticky>true</sticky>
<encrypt>false</encrypt>
<number-of-singles>10</number-of-singles>
<disable-reload>false</disable-reload>
<caching>
<cache-timeout>900</cache-timeout>
<cache-size>64</cache-size>
<cache-criteria>inputtext</cache-criteria>
<cache-option>TIMEOUT_CREATE</cache-option>
</caching>
</servlet-info>
</servlet>
The KXS log (assuming that you have info messages) will report servlet cache hits.
David
Shameless plug for my iAS book : http://www.amazon.com/exec/obidos/ASIN/076454909X/
P.S.
I just realized that the caching sample was only added in sp3. Even if you don't upgrade your server (the functionality is unchanged) you may want to download sp3 so that you can check out the sample. The sample goes into a reasonable amount of depth about this feature. -
How to configure servlets in Oracle AS 10g
Hi,
I am Ashish from Mumbai.
I am using Oracle DB and Oracle Application Server on same machine.
I have deployed a Java Web application on the server using the web administration of server.
It contains several servlets.
Whenever I tried to use servlets from the application,
server neither show servlets nor gives any errors.
Can anybody help me?
--- AshishHi,
You can also try the suggestion mentioned at this link to get more information about the error & it's causes :-
http://www.webwizguide.info/asp/faq/friendly_HTTP_error_messages.asp
The article talks about ASP - but, we frequently use it when we develop Servlets.
Regards,
Sandeep -
Configuring Servlet Virtual path translation
Hi,
I was wondering if anybody could help me out with this.
I am running iWS 4.1, and iAS6.0 on top of it.
I created a war file called myApp.war, which contains a servlet called
myServlet.
Then I created an ear file called myApp.ear which contains myApp.war, and
deployed myApp.ear on the application server.
Now: I am trying to set up a virtual path to access myServlet, so that
http://<server_id>/myServlet maps to myServlet.
I modified the following files under the config directory of the webserver:
1. In context.properties, I added a context called myContext with the
following properties:
context.myContext.classpath=<iPlanet App Server
path>/ias/APPS/myApp/myApp/WEB-INF/
2. In servlets.properties,
servlet.myServlet.classpath=<iPlanet App Server
path>/ias/APPS/myApp/myApp/WEB-INF/classes
servlet.myServlet.code=myServlet
servlet.myServlet.initArgs=initial=0
servlet.myServlet.context=myContext
3. In rules.properties,
/myServlet=myServlet
Now when I try to access myServlet through the virtual path
http://<server_id>/myServlet
the webserver error logs say the following:
warning ( 3080): Unable to locate class: myServlet
(java.lang.ClassNotFoundException: myServlet)
warning ( 3080): Internal error: Failed to get GenericServlet.
(uri=/myServlet,SCRIPT_NAME=/myServlet)
What am I doing wrong? Any help will be appreciated.
Thanks!
UzmaHi,
I was wondering if anybody could help me out with this.
I am running iWS 4.1, and iAS6.0 on top of it.
I created a war file called myApp.war, which contains a servlet called
myServlet.
Then I created an ear file called myApp.ear which contains myApp.war, and
deployed myApp.ear on the application server.
Now: I am trying to set up a virtual path to access myServlet, so that
http://<server_id>/myServlet maps to myServlet.
I modified the following files under the config directory of the webserver:
1. In context.properties, I added a context called myContext with the
following properties:
context.myContext.classpath=<iPlanet App Server
path>/ias/APPS/myApp/myApp/WEB-INF/
2. In servlets.properties,
servlet.myServlet.classpath=<iPlanet App Server
path>/ias/APPS/myApp/myApp/WEB-INF/classes
servlet.myServlet.code=myServlet
servlet.myServlet.initArgs=initial=0
servlet.myServlet.context=myContext
3. In rules.properties,
/myServlet=myServlet
Now when I try to access myServlet through the virtual path
http://<server_id>/myServlet
the webserver error logs say the following:
warning ( 3080): Unable to locate class: myServlet
(java.lang.ClassNotFoundException: myServlet)
warning ( 3080): Internal error: Failed to get GenericServlet.
(uri=/myServlet,SCRIPT_NAME=/myServlet)
What am I doing wrong? Any help will be appreciated.
Thanks!
Uzma -
Configuring servlets with JSDK2.0
detailed explaination of the above?
JSDK (Java Servlet Development Kit) and JWSDK (JavaServer Web Development Kit) are much older technologies. and have been consumed/superceded by 'Java EE' technology.
For servlet/jsp development, please take a look at:
http://java.sun.com/javaee/downloads/index.jsp
http://java.sun.com/javaee/technologies/webapps/index.jsp -
hi ...
i have downloaded the j2ee 1.5 from sun web site , but i am unable to compile a servelet programe but there is a error can not find package javax.servelet ..and i already have configured class path for jdk and other tool like javac, javap etc are working and other programes are compiling..
any body can tell me how can i configure servlet for my JDK 1.5..BigDaddyLoveHandles wrote:
amrit_j2ee wrote:
hi ...
i have downloaded the j2ee 1.5 from sun web site , but i am unable to compile a servelet programe but there is a error can not find package javax.servelet That's odd. I though the package name was "javax.servlet"Bloody French. -
Struts servlet failed to load on application startup
I am having problems deploying a struts application on WebLogic 8.1 SP3. I get the following error on startup.
Call com.manu.cro.online.ui.KarmaActionServlet.addMapping(ActionMapping[path=/routingPost, type=com.manu.cro.online.ui.routing.RoutingPostAction])
Pop org.apache.struts.action.ActionMapping
register('-//Apache Software Foundation//DTD Struts Configuration 1.0//EN', 'jar:file:/C:/CVS_Source/NCRO/lib/GUI/struts.jar!/org/apache/struts/resources/struts-config_1_0.dtd'
register('-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN', 'jar:file:/C:/CVS_Source/NCRO/lib/GUI/struts.jar!/org/apache/struts/resources/web-app_2_2.dtd'
register('-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN', 'jar:file:/C:/CVS_Source/NCRO/lib/GUI/struts.jar!/org/apache/struts/resources/web-app_2_3.dtd'
resolveEntity('-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN', 'http://java.sun.com/j2ee/dtds/web-app_2_2.dtd')
Resolving to alternate DTD 'jar:file:/C:/CVS_Source/NCRO/lib/GUI/struts.jar!/org/apache/struts/resources/web-app_2_2.dtd'
Call com.manu.cro.online.ui.KarmaActionServlet.addServletMapping(action/java.lang.String,*.do/java.lang.String)
<Jul 18, 2007 9:13:39 AM EDT> <Error> <HTTP> <BEA-101216> <Servlet: "action" failed to preload on startup in Web application: "cro".
javax.servlet.ServletException
at weblogic.servlet.internal.ServletStubImpl.createServlet(ServletStubImpl.java:909)
at weblogic.servlet.internal.ServletStubImpl.createInstances(ServletStubImpl.java:873)
at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:812)
at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:3281)
at weblogic.servlet.internal.WebAppServletContext.preloadServlets(WebAppServletContext.java:3226)
at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:3207)
at weblogic.servlet.internal.HttpServer.preloadResources(HttpServer.java:694)
at weblogic.servlet.internal.WebService.preloadResources(WebService.java:483)
at weblogic.servlet.internal.ServletInitService.resume(ServletInitService.java:30)
at weblogic.t3.srvr.SubsystemManager.resume(SubsystemManager.java:131)
at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:966)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:361)
at weblogic.Server.main(Server.java:32)
Any reason why my action servlet is not loading? Any help will be appreciated.
My web.xml file looks like the following:
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE web-app
PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/j2ee/dtd/web-app_2_3.dtd">
<web-app>
<!-- Action Servlet Configuration -->
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>com.manu.cro.online.ui.KarmaActionServlet</servlet-class>
<init-param>
<param-name>application</param-name>
<param-value>com.manu.cro.online.ApplicationResources</param-value>
</init-param>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>validate</param-name>
<param-value>true</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<!-- Action Servlet Mapping -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<!-- The Usual Welcome File List -->
<welcome-file-list>
<welcome-file>jsp/online/Logon.jsp</welcome-file>
</welcome-file-list>
<!-- Struts Tag Library Descriptors -->
<taglib>
<taglib-uri>/WEB-INF/struts-bean.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-html.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-html.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-logic.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/struts-template.tld</taglib-uri>
<taglib-location>/WEB-INF/struts-template.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>/WEB-INF/croUtils.tld</taglib-uri>
<taglib-location>/WEB-INF/croUtils.tld</taglib-location>
</taglib>
</web-app>
Thanks.
gtataThis problem has been resolved. It was a classpath issue.
-
Hi!! I'm looking for an answer to my problem, and I'm going to explain what I mean.
I've created a .jar named yuhuuTunnel.jar that has the following structure:
yuhuuTunnel.jar:
--> web (contains the servlets)
--> *.class
--> HelloWorldServlet.class
--> META-INF
--> MANIFEST.MF
--> SimpleClient.classThe code of HelloWorldServlet.java is this:
package web;
import java.io.IOException;
import java.io.PrintWriter;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.ServletException;
import javax.servlet.ServletConfig;
public class HelloWorldServlet extends HttpServlet {
public void init(ServletConfig config) throws ServletException {
super.init(config);
public void doGet( HttpServletRequest request, HttpServletResponse response )
throws ServletException, IOException {
doPost(request, response);
public void doPost( HttpServletRequest request, HttpServletResponse response)
throws ServletException, IOException {
response.setContentType("text/html");
PrintWriter out = response.getWriter();
out.println("<html>");
out.println("<body>");
out.println("<body bgcolor=\"white\">");
out.println("<h1>Yuhuu Servlet!</h1>");
out.println("</body>");
out.println("</html>");
}then, using a .war file (created with ANT), I've created into /../tomcat/webapps/ a directory call yuhuuTunnel that has this structure:
/webapps/
--> yuhuuTunnel
--> WEB-INF
--> web.xml
--> lib
--> yuhuuTunnel.jar
--> META-INF
--> MANIFEST.MF
--> yuhuuTunnel.jar
--> index.htmlThe content of web.xml is the following:
<?xml version="1.0" encoding="ISO-8859-1"?>
<!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>
<!-- Action Servlet Configuration -->
<servlet>
<servlet-name>HelloWorld</servlet-name>
<servlet-class>web.HelloWorldServlet</servlet-class>
<load-on-startup>0</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>HelloWorld</servlet-name>
<url-pattern>HelloWorld</url-pattern>
</servlet-mapping>
</web-app>Tomcat works correctly ( http://localhost:8080 return me the page of tomcat ) but when I try to use the HelloWoldServlet typing http://localhost:8080/yuhuuTunnel/HelloWorld into a browser, this one returns me the HTTP Status 404 - The requested resource () is not available.
What is wrong? The address that I type into the browser or there's an error into web.xml?
Something interesting: If I type
http://localhost:8080/yuhuuTunnel/HelloWorld
the message given back is: "The requested resource () is not available."
but if I type
http://localhost:8080/HelloWorld the message is different:
"The requested resource (/HelloWorld) is not available."<?xml version="1.0" encoding="ISO-8859-1"?>
<!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>
<!-- Action Servlet Configuration -->
<servlet>
<servlet-name>HelloWorld</servlet-name>
<servlet-class>web.HelloWorldServlet</servlet-class>
<load-on-startup>0</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>HelloWorld</servlet-name>
<url-pattern>HelloWorld</url-pattern>
</servlet-mapping>
</web-app>Please change the servlet url pattern from
<url-pattern>HelloWorld</url-pattern>to
<url-pattern>/HelloWorld</url-pattern>in servlet mappings
REGARDS,
RaHuL -
How to convert old Java Servlets to OSGi "Servlet" Bundles
Hello I'm looking for some help/insight on the best way to convert some of our old Java Servlet code into new OSGi Bundles that can be accessed as servlets. I'd like to be able to install the new bundles then access them on one of our CQ instance using something like "/servlet/servlet_name".
So far I've been able to create a new bundle, and install it into CQ but I haven't been able to access the bundle at the servlet mapping URL that I would expect. So far what I've found online has lead me to believe that I need to use the Felix Annotations to describe my servlet.
@Component(immediate = true, metatype = true, label = "Servlet Name")
@Service
@Properties({
@Property(name = Constants.SERVICE_DESCRIPTION, value = "Servlet Name"),
@Property(name = "sling.servlet.methods", value={"GET"}),
@Property(name = "sling.servlet.paths", value = "/servlet/my_servlet_mapping"),
@Property(name = Constants.SERVICE_VENDOR, value = "VendorName")
public class TellAFriend extends HttpServlet {...
public void doGet(HttpServletRequest req, HttpServletResponse res) throws IOException, ServletException
Once I have this installed, and running without an error in the logs for CQ I tried to go on my local instance to http://localhost:4502/servlet/my_servlet_mapping but I only get 404 Resource Not Found errors. I've even gone to the Sling Resource Resolver and it doesn't resolve to anything either.
Is there more than the Servlet Information need into the Annotations to convert "old" code into a new OSGi Servlet Mapped Bundle?I must be missing something else configuration wise since I created a new Servlet basically using the code you provided above. I deployed it as part of the bundle that I'm trying to create.
The bundle installs and stars fine but I still can't access the servlet. Are there CRXDE based configurations that are requried too to configure Servlets.
Here's my test servlet file. I tried going to http://localhost:4502/servlet/TestCQServlet and just get the same 404 error I'm getting for the other 2 Servlets Java classes in my Bundle.
import java.io.IOException;
import javax.servlet.ServletException;
import org.apache.felix.scr.annotations.sling.SlingServlet;
import org.apache.sling.api.SlingHttpServletRequest;
import org.apache.sling.api.SlingHttpServletResponse;
import org.apache.sling.api.servlets.SlingSafeMethodsServlet;
@SlingServlet(paths = "/servlet/TestCQServlet", methods = "GET")
public class TestCQServlet extends SlingSafeMethodsServlet {
// @Reference
// private Repository repository;
private static final long serialVersionUID = 6239754936223276983L;
@Override
protected void doGet(SlingHttpServletRequest request, SlingHttpServletResponse response) throws ServletException, IOException {
response.setHeader("Content-Type", "application/json");
response.getWriter().print("whatever"); -
How to run a servlet in Tomcat 5.0 server
HI Everybody,
I want to know how to run the servlet file on my tomcat 5.0 server. that is where to place a class file and deployment details.
Thanks In ADVANCESourav_cs wrote:
I am a biginner to start servlet i get confusion to configure servlet in tomcat 5 where it should be saved in tomcat directory and how to execute that as first timeHi,
goto
tomcat 5.0\webappsnow create a folder here. this is your webapplication project name. Let's suppose it as "TestApp"
inside this create directories as follows :
TestApp
|
|-----JSP/htmls( if you have any )
|
|-----WEB-INF(File Folder)
|
|-----web.xml
|-----lib ( Directory. place all the .jar files which are required for this project(if any) )
|-----classes ( .class files. )[all of your java code should be placed here.](servlets / beans/ pojo )this is the general Directory structure of a web application. now you've to place the compiled .class file of your servlet in the "TestApp\WEB-INF\classes" directory. make sure that you've configured the servlet in Deploment Desctiptor, i.e, web.xml.
now start the server and type the url like : "http://localhost:8080/TestApp/TestServlet"
the port no. 8080 is the default port no. of tomcat. you have to give your port no. if u've modified it. and TestServlet is the <url-pattern> of your servlet.
go through some tutorials .. then you can easily know that
Diablo -
XCM configuration path in web.xml file
Hi,
Here is a requirement that all the XCM configuration files are stored at local desktop(like QAT, PRD..), and need to use them by modifying web.xml.
Please let me know at
1)which web.xml tag the path of XCM confiuration files to be specified.
2) specify the names of the XCM files for configuration to be put in that folder.
Thanks,
Devender VHi,
1)which web.xml tag the path of XCM confiuration files to be specified.
Try to find below lines in your web.xml
<context-param>
<param-name>path.xcm.config.isa.sap.com</param-name>
<param-value>/WEB-INF/xcm/sap/system/bootstrap-config.xml</param-value>
<description>Turns the Extended Configuration Management on if a
path to the configuration file is specified. It is a
relative path, with context-root of web application as root</description>
</context-param>
bootstrap-config.xml file contains XCM configuration related XML file path. You can modify or extend this file and give your user Define path.
Also you can find below line in web.xml file.
<!-- Action Servlet Configuration -->
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>com.sap.isa.core.ActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/config.xml,/WEB-INF/xcmadmin-config.xml,/WEB-INF/ccmsims-config.xml,/WEB-INF/ipc-config.xml,/ipc/customer/config.xml,/WEB-INF/config_lwc_b2b.xml,/WEB-INF/scheduler-config.xml,/WEB-INF/ipcpricing-config.xml</param-value>
</init-param>
<init-param>
<param-name>config/user</param-name>
<param-value>/WEB-INF/config_user.xml</param-value>
</init-param>
<init-param>
<param-name>config/dealerlocator</param-name>
<param-value>/WEB-INF/config_dealerlocator.xml</param-value>
</init-param>
<init-param>
<param-name>initconfig</param-name>
<param-value>/WEB-INF/xcm/sap/system/init-config.xml</param-value>
</init-param>
I hope this will help you.
eCommerce Developer -
Where to store the servlet class files ?
If, I store the class files for servlets under WEB-INF/classes folder,
i get file not found exception while using WL 6.1 sp2. But, if i store
the class file under DefaultWebApp folder, it works fine.
Any help about where to store the class files for servlets would be
great help.
Thanks.
hiren
Copy Servlet in DefaultWebApp/Web-Inf/classes directory.
Configure Servlet in web.xml deployment descriptor.
<servlet>
<servlet-name></servlet-name>
<servlet-class></servlet-class>
</servlet>
<servlet>
<servlet-name></servlet-name>
<servlet-class></servlet-class>
</servlet>
<servlet-mapping>
<servlet-name></servlet-name>
<url-pattern></url-pattern>
</servlet-mapping>
hiren dossani wrote:
> If, I store the class files for servlets under WEB-INF/classes folder,
> i get file not found exception while using WL 6.1 sp2. But, if i store
> the class file under DefaultWebApp folder, it works fine.
> Any help about where to store the class files for servlets would be
> great help.
>
> Thanks.
>
> --
> hiren
-
Where to store the servlet classes
can anyone tell me where to store the servlet classes(inside a package)in oracle9iAS used with oracle8i database ?
Also how to deploy an ejb in oracle9iAS. should we have to use oracle8i deployment guide or any other procedure??
thanks in advanceCopy Servlet in DefaultWebApp/Web-Inf/classes directory.
Configure Servlet in web.xml deployment descriptor.
<servlet>
<servlet-name></servlet-name>
<servlet-class></servlet-class>
</servlet>
<servlet>
<servlet-name></servlet-name>
<servlet-class></servlet-class>
</servlet>
<servlet-mapping>
<servlet-name></servlet-name>
<url-pattern></url-pattern>
</servlet-mapping>
hiren dossani wrote:
> If, I store the class files for servlets under WEB-INF/classes folder,
> i get file not found exception while using WL 6.1 sp2. But, if i store
> the class file under DefaultWebApp folder, it works fine.
> Any help about where to store the class files for servlets would be
> great help.
>
> Thanks.
>
> --
> hiren
-
Jsp configuration load on start up in web.xml
Is my configuration for jsp correct.i want my JSP to be loaded after servlet initialised.What changes i need to do to make it work on any server..like tomcat or websphere
<!-- JSP CONFIGURATION -->
<jsp-file>/hello.jsp</jsp-file>
<load-on-startup>2</load-on-startup>
<!-- SERVLET CONFIGURATION -->
<servlet>
<servlet-name>MyServlet</servlet-name>
<servlet-class>com.example.HelloServlet</servlet-class>
<!-- or -->
<jsp-file>/hello.jsp</jsp-file>
<!-- optional and one only, greater value than 0 means don't wait for the first request load it beforehand -->
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>MyServlet</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
Message was edited by:
raghuveer_vellankiwhen you give a load on startup value as 1 for a servlet declaration in the web.xml the Server calls your servlet when u start it, and calls means the server loads your servlet anc calls the init method. so u may do whatever you like in init method like starting some other application, setting some parameters , etc
Maybe you are looking for
-
I downloaded a song from itunes and it says my computer is not authorized to play it, to authorized enter your apple id and password so I did, then it said that this computer was already authorized, but it still won"t let me play the song! What do I
-
Error in EEWB when a n Extension is changed
Hello, I need to add some more custom fields in Opportunity tab. There were already some existing fields created using Project Extension(say it is PE1) in EEWB. But I am facing some problems (1) To add the new ones, when I created a new Extension PE2
-
HWF UI work list not loading in BPM worklist page (on clustered env)
hello - Please reply directly as I am not on this alias. My SOA project (BPEL+HWF) is successfully deployed on the clustered env successfully. My BPEL process runs fine. But my HWF_UI taskflow fails to load on the browser (IE and Firefox, same error)
-
SQL Developer SQL History no longer working 3.2.20.09.87
Hi guys, The SQL History (F8) option has started to no longer work within my copy of OSD. it was working at one point but has gone away. I have confirmed that "Enable Local History" is enabled and has been set for 30 days history and 50 max revisions
-
To disable a service for jumpstart/create zone
To disable a service once a system is up a running, "svcadm disable" does the job well. What would the suggested way of disabling a service before the system is up an running, in order to guarantee a service never runs. Clarification of this point wo