473,657 Members | 2,445 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Auto loading/instantiating of servlet in web server

Hi,

Is there any way to auto load/instantiate a new class of a servlet
into the JVM (with shutting the web server) after replacing the old
class with new one?

For e.g., after a servlet is deployed and loaded in the web server, a
change needs to made to this server. Without shutting down the web
server, can this new class with changes be loaded/instantiated. Is
there any specific code that needs to be written in the servlet for
this to happen.

Nischal
Jul 17 '05 #1
2 3907
Hi,
From what i have seen 'no'.
From what I have seen none of the available allow hot deployment of a
servlet ... however the JSP pages are hot deployable.

tn******@yahoo. com (Nischal Topno) wrote in message news:<5a******* *************** ****@posting.go ogle.com>...
Hi,

Is there any way to auto load/instantiate a new class of a servlet
into the JVM (with shutting the web server) after replacing the old
class with new one?

For e.g., after a servlet is deployed and loaded in the web server, a
change needs to made to this server. Without shutting down the web
server, can this new class with changes be loaded/instantiated. Is
there any specific code that needs to be written in the servlet for
this to happen.

Nischal

Jul 17 '05 #2
That is exactly what i ment .... what the manager does is .. it
restarts the servlet engine after the new servlet is deployed ...
Chris <ch*******@hotm ail.com> wrote in message news:<1W******* **************@ news0.telusplan et.net>...
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Nischal Topno wrote:
Hi,

Is there any way to auto load/instantiate a new class of a servlet
into the JVM (with shutting the web server) after replacing the old
class with new one?

For e.g., after a servlet is deployed and loaded in the web server,
a change needs to made to this server. Without shutting down the web
server, can this new class with changes be loaded/instantiated. Is
there any specific code that needs to be written in the servlet for
this to happen.

Nischal


I think I did this a while ago, and I'm not sure if it worked. I think
it does though. The Tomcat server seems to allow this to happen via
the manager application. The following is for version 4.1 from the
documentation on the Apache site:
http://jakarta.apache.org/tomcat/tom...ger-howto.html
Go there, then click on Reload An Existing Application.
Specifically, read this:
"Signal an existing application to shut itself down and reload. This
can be useful when the web application context is not reloadable and
you have updated classes or property files in the /WEB-INF/classes
directory or when you have added or updated jar files in the
/WEB-INF/lib directory."

- --
Chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE/GysdwxczzJRavJY RArWsAKD08KTTm5 XZh3o3HxW0iea6I 8911gCgr/DC
afLXcnU2z9JJl3B sKRV0T0s=
=MrBX
-----END PGP SIGNATURE-----

Jul 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3468
by: Chris Morgan | last post by:
I'm trying to get php to run on my webserver as a Java Servlet, it works the first time but fails the second time and crashes the JVM with the following error: I have tried the latest versions of PHP 4. (release and dev) I would appreciate any help with this issue. -- Chris
3
22128
by: dinesh prasad | last post by:
I'm trying to use a servlet to process a form, then send that data to an SQL server stored procedure. I'm using the WebLogic 8 App. server. I am able to retrieve database information, so I know my application server can talk to the database. I've determined the failure occurs when the the following statement is executed: cstmt.execute(); (due to the failure of println statements placed afterwards). I get the following error after trying to...
0
2496
by: Leigh | last post by:
I am building a data entry application using Java servlets. I had hoped to use drop down boxes to provide the user with data entry selections pulled from a database, but am now questioning, given the latency with which the data loads to the browser, whether drop down boxes are viable for providing a large number of select options. I've put nearly-identical examples of the problem on two different web/database hosts for review (I wanted...
12
2198
by: Joe | last post by:
Hello All: Do I have to use the LoadControl method of the Page to load a UserControl? I have a class which contains three methods (one public and two private). The class acts as a control server. It "serves" back the required control (either WebControl or UserControl) based on the contents of an xml file. The code in the webform places each control in a TableCell. My problem is that the control server works as far as returning the...
1
6995
by: Farce Milverk | last post by:
Hi, Is it possible to have a Servlet on Server A call a Servlet on Server B (both running single instances of an identical webapplication) without using a Proxy setup? For example, if a request comes into Servlet (on server A) I want the servlet on server B to handle the request at address http://serverB/servlet/servletB... The goal is to have Servlet B handle the request fielded by Server A, and
11
7379
by: eureka | last post by:
Hi All, I'm training in Servlets, JSP and JavaScript, I have a web page in which there's a "StudentName" textbox and below it is a "Names" Dropdown list. Initially the Textbox is empty and the Dropdown doesnt have any items.. The requirement is that as soon as one goes on typing the letters in the StudentName-textbox the corresponding matching names have to appear
14
2036
by: DavidNorep | last post by:
I do not know PHP, consider to write a CGI with this technology and have the following question. Is it possible to invoke a PHP script and let it endlessly wait for requests from a website (a Java applet in my case) and serve the requests when they arrive? I want to avoid loading the script for each request. In other words, can it function, in this sense, like a Java servlet?
1
2418
by: davidr69 | last post by:
I am completely new to servlets. I have an extensive programming background (C, C++, assembler, PHP, python, javascript, others) and I am trying to get into servlet programming. I have done several jsp's and small java apps, and I have code that works both as a java app and as a jsp: class foobar { int x = 0; public void foobar() { } } public class mytest { public static void main(String args) { ...
2
3448
by: ksrashmi | last post by:
Hi , does jar file loaidng will consume the jvm memory ? I have to run the cronjobs for some of the java files . so i have writen the .sh file ( linux server) This is the Script file temp_path=/bin:/usr/sbin:/usr/bin export temp_path
0
8395
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8310
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8826
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7330
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4306
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1955
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1615
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.