You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(5) |
Oct
(13) |
Nov
(16) |
Dec
(29) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(38) |
Feb
(51) |
Mar
(51) |
Apr
(115) |
May
(82) |
Jun
(30) |
Jul
(50) |
Aug
(68) |
Sep
(57) |
Oct
(160) |
Nov
(80) |
Dec
(78) |
| 2004 |
Jan
(71) |
Feb
(75) |
Mar
(108) |
Apr
(87) |
May
(79) |
Jun
(70) |
Jul
(69) |
Aug
(39) |
Sep
(52) |
Oct
(47) |
Nov
(50) |
Dec
(32) |
| 2005 |
Jan
(22) |
Feb
(122) |
Mar
(46) |
Apr
(76) |
May
(31) |
Jun
(51) |
Jul
(61) |
Aug
(70) |
Sep
(37) |
Oct
(46) |
Nov
(57) |
Dec
(83) |
| 2006 |
Jan
(55) |
Feb
(81) |
Mar
(51) |
Apr
(67) |
May
(77) |
Jun
(43) |
Jul
(106) |
Aug
(64) |
Sep
(47) |
Oct
(64) |
Nov
(60) |
Dec
(12) |
| 2007 |
Jan
(50) |
Feb
(93) |
Mar
(49) |
Apr
(56) |
May
(40) |
Jun
(63) |
Jul
(40) |
Aug
(47) |
Sep
(54) |
Oct
(37) |
Nov
(54) |
Dec
(37) |
| 2008 |
Jan
(35) |
Feb
(39) |
Mar
(26) |
Apr
(14) |
May
(23) |
Jun
(51) |
Jul
(43) |
Aug
(26) |
Sep
(29) |
Oct
(31) |
Nov
(24) |
Dec
(16) |
| 2009 |
Jan
(21) |
Feb
(30) |
Mar
(74) |
Apr
(26) |
May
(26) |
Jun
(43) |
Jul
(23) |
Aug
(23) |
Sep
(15) |
Oct
(27) |
Nov
(37) |
Dec
(10) |
| 2010 |
Jan
(16) |
Feb
(28) |
Mar
(16) |
Apr
(45) |
May
(8) |
Jun
(68) |
Jul
(45) |
Aug
(44) |
Sep
(51) |
Oct
(7) |
Nov
(20) |
Dec
(21) |
| 2011 |
Jan
(14) |
Feb
(17) |
Mar
(7) |
Apr
(7) |
May
(48) |
Jun
(23) |
Jul
(5) |
Aug
(33) |
Sep
(22) |
Oct
(14) |
Nov
(14) |
Dec
(5) |
| 2012 |
Jan
|
Feb
(10) |
Mar
(12) |
Apr
(51) |
May
(10) |
Jun
(8) |
Jul
(14) |
Aug
(22) |
Sep
(9) |
Oct
(24) |
Nov
(14) |
Dec
(13) |
| 2013 |
Jan
(12) |
Feb
(4) |
Mar
(14) |
Apr
(19) |
May
(2) |
Jun
(5) |
Jul
(13) |
Aug
(10) |
Sep
(4) |
Oct
(11) |
Nov
(13) |
Dec
(2) |
| 2014 |
Jan
(3) |
Feb
(14) |
Mar
(5) |
Apr
(10) |
May
(10) |
Jun
(11) |
Jul
(10) |
Aug
(3) |
Sep
(13) |
Oct
(22) |
Nov
(14) |
Dec
(32) |
| 2015 |
Jan
(8) |
Feb
(2) |
Mar
(17) |
Apr
(1) |
May
(24) |
Jun
|
Jul
(4) |
Aug
|
Sep
(9) |
Oct
(9) |
Nov
(5) |
Dec
(2) |
| 2016 |
Jan
(8) |
Feb
(6) |
Mar
(6) |
Apr
(9) |
May
(3) |
Jun
(2) |
Jul
(7) |
Aug
(6) |
Sep
|
Oct
|
Nov
(1) |
Dec
(6) |
| 2017 |
Jan
(9) |
Feb
(8) |
Mar
(6) |
Apr
|
May
|
Jun
(3) |
Jul
(13) |
Aug
(10) |
Sep
(8) |
Oct
|
Nov
(6) |
Dec
|
| 2018 |
Jan
|
Feb
(5) |
Mar
(7) |
Apr
(2) |
May
|
Jun
|
Jul
(3) |
Aug
(2) |
Sep
(9) |
Oct
(1) |
Nov
(1) |
Dec
(1) |
| 2019 |
Jan
(9) |
Feb
|
Mar
|
Apr
(10) |
May
(3) |
Jun
|
Jul
(7) |
Aug
(1) |
Sep
|
Oct
(2) |
Nov
|
Dec
|
| 2020 |
Jan
(1) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2021 |
Jan
(1) |
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
(3) |
| 2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2023 |
Jan
(3) |
Feb
|
Mar
(1) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2024 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
(1) |
Jun
(1) |
Jul
(1) |
Aug
|
Sep
(1) |
Oct
|
Nov
(1) |
Dec
|
| 2025 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2026 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Aiman Y. <wr...@co...> - 2004-01-26 18:21:53
|
One way, not sure if its the best, is to recompile your source including =
the wrappermanager source.
Looking through some test code I had, I just added:
-------------------------------------------------------------------------=
-
import org.tanukisoftware.wrapper.WrapperManager;
...
public class bla {
public static void main(String[] s) {
...
catch (SomeException se) {
System.out.println("Caught some exception, restarting");
WrapperManager.restart();
}
...
}
}
-------------------------------------------------------------------------=
-
And then I copied (from the source you can get from the site)
WrapperInfo.java
WrapperListener.java
WrapperManager.java
into directory org/tanukisoftware/wrapper/ and compiled.
This was just for testing. Most likely there is a better way (like using =
method 3 maybe? I never really looked into that method yet).
----- Original Message -----=20
From: St=E9phane Merle=20
To: wra...@li...=20
Sent: Monday, January 26, 2004 12:23 PM
Subject: [Wrapper-user] restart
Hi,
I managed to have my app to start as a service using the method 1 with =
the WrapperSimpleApp helper class=20
But now, I'd like to have the ability to stop/start the service from =
within my app.
How can I make the call to wrappermanager.restart() ??
St=E9phane
|
|
From: Paul B. (DL/LMI) <pau...@er...> - 2004-01-26 18:09:36
|
Hi All, I am new to the Wrapper (which is a great program by the way) and HP-UX which I am testing an application on. I have used it successfully on Solaris, but when I use it on a HP-UX, the following warning message appears in the logfile for any application that I run. WARNING - Unable to load native library 'libwrapper.so'. The file is located on the path at the following location but could not be loaded: /home/lmipbay/dev/wrapper/wrapper_hpux_3.0.5/bin/../lib/libwrapper.so Please verify that the file is readable by the current user and that the file has not been corrupted in any way. System signals will not be handled correctly. But then it continues to work correctly. Is this error message valid? Regards Paul |
|
From: <ste...@di...> - 2004-01-26 17:24:28
|
Hi, I managed to have my app to start as a service using the method 1 with = the WrapperSimpleApp helper class=20 But now, I'd like to have the ability to stop/start the service from = within my app. How can I make the call to wrappermanager.restart() ?? St=E9phane |
|
From: Jacoby, P. <ja...@li...> - 2004-01-26 14:51:11
|
Hi, I have encountered a problem with the Java Service Wrapper on a Windows 2000 machine with SP4. I have successfully installed a service, but when I try to remove it (to update my java classes) I am not able to, until a reboot is done. Is this a common problem ? Does anybody know a solution without rebooting the machine ? Thanks Patrik Jacoby |
|
From: <ste...@di...> - 2004-01-22 10:47:59
|
Hi,
I looked around the doc and the sample and tried to have my own creation =
to word as a windows services. I started from the sample and change it =
for my app. The problem is that the sample is using a jar file as a app, =
but mine are straight .class files, should I create a .jar file ?
here is the log dump :
STATUS | wrapper | 2004/01/22 10:04:45 | --> Wrapper Started as Service
STATUS | wrapper | 2004/01/22 10:04:46 | Launching a JVM...
INFO | jvm 1 | 2004/01/22 10:04:46 | WrapperSimpleApp: Unable to =
locate the class MYXMLServer: java.lang.ClassNotFoundException: =
MYXMLServer
INFO | jvm 1 | 2004/01/22 10:04:46 |=20
INFO | jvm 1 | 2004/01/22 10:04:46 | WrapperSimpleApp Usage:
INFO | jvm 1 | 2004/01/22 10:04:46 | java =
org.tanukisoftware.wrapper.WrapperSimpleApp {app_class} [app_parameters]
INFO | jvm 1 | 2004/01/22 10:04:46 |=20
INFO | jvm 1 | 2004/01/22 10:04:46 | Where:
INFO | jvm 1 | 2004/01/22 10:04:46 | app_class: The fully =
qualified class name of the application to run.
INFO | jvm 1 | 2004/01/22 10:04:46 | app_parameters: The =
parameters that would normally be passed to the
INFO | jvm 1 | 2004/01/22 10:04:47 | application.
STATUS | wrapper | 2004/01/22 10:04:49 | <-- Wrapper Stopped
I setup the folder like this :
D:\http\XMLserveur_java -- main folder with the .class =
files of my app (my main class is MYXMLServer.class)
D:\http\XMLserveur_java\bin -- the 3 bach files, the wrapper.exe =
and the wrapper.log file =20
D:\http\XMLserveur_java\conf -- the wrapper.conf file see under =
this
D:\http\XMLserveur_java\lib -- wrapper.jar, =
wrappertest.jar(should'nt be used), Wrapper.dll and 2 jar files for me : =
activation.jar and mail.jar
here is my conf file :
#********************************************************************
# Wrapper Properties
#********************************************************************
# Java Application
wrapper.java.command=3DC:\Program Files\j2sdk_nb\j2sdk1.4.2\jre\bin\java =
# Java Main class. This class must implement the WrapperListener =
interface
# or guarantee that the WrapperManager class is initialized. Helper
# classes are provided to do this for you. See the Integration section
# of the documentation for details.
wrapper.java.mainclass=3Dorg.tanukisoftware.wrapper.WrapperSimpleApp
# Java Classpath (include wrapper.jar) Add class path elements as
# needed starting from 1
wrapper.java.classpath.1=3D../lib/wrapper.jar
# wrapper.java.classpath.2=3D../lib/wrappertest.jar
wrapper.java.classpath.2=3D../lib/activation.jar
wrapper.java.classpath.3=3D../lib/mail.jar
# Java Library Path (location of Wrapper.DLL or libwrapper.so)
wrapper.java.library.path.1=3D../lib
# Java Additional Parameters
#wrapper.java.additional.1=3D
# Initial Java Heap Size (in MB)
wrapper.java.initmemory=3D3
# Maximum Java Heap Size (in MB)
wrapper.java.maxmemory=3D64
# Application parameters. Add parameters as needed starting from 1
wrapper.app.parameter.1=3DMYXMLServer
#********************************************************************
# Wrapper Logging Properties
#********************************************************************
# Format of output for the console. (See docs for formats)
wrapper.console.format=3DPM
# Log Level for console output. (See docs for log levels)
wrapper.console.loglevel=3DINFO
# Log file to use for wrapper output logging.
wrapper.logfile=3D../logs/wrapper.log
# Format of output for the log file. (See docs for formats)
wrapper.logfile.format=3DLPTM
# Log Level for log file output. (See docs for log levels)
wrapper.logfile.loglevel=3DINFO
# Maximum size that the log file will be allowed to grow to before
# the log is rolled. Size is specified in bytes. The default value
# of 0, disables log rolling. May abbreviate with the 'k' (kb) or
# 'm' (mb) suffix. For example: 10m =3D 10 megabytes.
wrapper.logfile.maxsize=3D0
# Maximum number of rolled log files which will be allowed before old
# files are deleted. The default value of 0 implies no limit.
wrapper.logfile.maxfiles=3D0
# Log Level for sys/event log output. (See docs for log levels)
wrapper.syslog.loglevel=3DNONE
#********************************************************************
# Wrapper NT Service Properties
#********************************************************************
# WARNING - Do not modify any of these properties when an application
# using this configuration file has been installed as a service.
# Please uninstall the service before modifying this section. The
# service can then be reinstalled.
# Name of the service
wrapper.ntservice.name=3DBINGOXMLServer
# Display name of the service
wrapper.ntservice.displayname=3DServeur Socket XML pour le BINGO
# Description of the service
wrapper.ntservice.description=3DServeur Socket XML pour le BINGO
# Service dependencies. Add dependencies as needed starting from 1
wrapper.ntservice.dependency.1=3D
# Mode in which the service is installed. AUTO_START or DEMAND_START
wrapper.ntservice.starttype=3DAUTO_START
# Allow the service to interact with the desktop.
wrapper.ntservice.interactive=3Dfalse
Thanks for any help you can provide.
St=E9phane Merle |
|
From: Leif M. <le...@ta...> - 2004-01-22 00:30:43
|
Willy,
Whenever you encounter problems like this, the first thing you
should try is to
set the wrapper.debug=true property in the configuration file. When
you relaunch
the wrapper you will get a host of useful information, including the
full command
line used to launch the JVM. Take a close look at the library path
that the
Wrapper is generating and make sure that it is what you are expecting.
UNIX platforms show the command as an array. For debugging it is
possible
to copy the command into an empty shell script and launch the JVM manually.
(If you try this, the wrapper.key system property must be removed from the
generated command line.) This has proved useful mainly as a confidence
builder
to prove that the Wrapper is or is not the cause of a given problem.
Cheers,
Leif
Marc Wilson wrote:
>I noticed you have /opt/mqm//lib as the second path (note the //).
>
>Could that // instead of / be causing the prob?
>
>-M
>
>
>
>>-----Original Message-----
>>From: wra...@li... [mailto:wrapper-user-
>>ad...@li...] On Behalf Of Brandsdorfer, William
>>Sent: Thursday, 22 January 2004 4:54 AM
>>To: wra...@li...
>>Subject: [Wrapper-user] multiple wrapper.java.liibrary.path statements
>>
>>Greetings,
>>
>>I'm having trouble wrapping a Java program that uses multiple native
>>libraries. The application is a JMS (IBM) MQSeries program that
>>
>>
>normally
>
>
>>requires
>>LD_LIBRARY_PATH = /opt/mqm/lib:/opt/mqm/java/lib (I'm running on
>>
>>
>Solaris -
>
>
>>wrapper 3.0.5)
>>
>>My config has the following
>>
>>
>>
>>
>wrapper.java.library.path.1=/etrade/home/wbrandsd/tools/wrapper_solaris_
>3.
>
>
>>0.5/lib
>>wrapper.java.library.path.2=/opt/mqm//lib
>>wrapper.java.library.path.3=/opt/mqm/java/lib
>>
>>But when I run it I get:
>>
>>Exception in thread "main" java.lang.UnsatisfiedLinkError: no mqjbnd04
>>
>>
>in
>
>
>>java.library.path
>>
>>I know that the path exists because the program runs fine when I set
>>LD_LIBRARY_PATH and run it without the wrapper.
>>I've also used the wrapper successfully on another (non-MQSeries)
>>
>>
>program
>
>
>>Is there a known problem with multiple wrapper.java.library.paths?
>>
>>Thanks,
>>Willy
>>
>>
|
|
From: Marc W. <ma...@da...> - 2004-01-22 00:14:05
|
I noticed you have /opt/mqm//lib as the second path (note the //). Could that // instead of / be causing the prob? -M > -----Original Message----- > From: wra...@li... [mailto:wrapper-user- > ad...@li...] On Behalf Of Brandsdorfer, William > Sent: Thursday, 22 January 2004 4:54 AM > To: wra...@li... > Subject: [Wrapper-user] multiple wrapper.java.liibrary.path statements > > Greetings, > > I'm having trouble wrapping a Java program that uses multiple native > libraries. The application is a JMS (IBM) MQSeries program that normally > requires > LD_LIBRARY_PATH = /opt/mqm/lib:/opt/mqm/java/lib (I'm running on Solaris - > wrapper 3.0.5) > > My config has the following > > wrapper.java.library.path.1=/etrade/home/wbrandsd/tools/wrapper_solaris_ 3. > 0.5/lib > wrapper.java.library.path.2=/opt/mqm//lib > wrapper.java.library.path.3=/opt/mqm/java/lib > > But when I run it I get: > > Exception in thread "main" java.lang.UnsatisfiedLinkError: no mqjbnd04 in > java.library.path > > I know that the path exists because the program runs fine when I set > LD_LIBRARY_PATH and run it without the wrapper. > I've also used the wrapper successfully on another (non-MQSeries) program > > Is there a known problem with multiple wrapper.java.library.paths? > > Thanks, > Willy > > > > ------------------------------------------------------- > The SF.Net email is sponsored by EclipseCon 2004 > Premiere Conference on Open Tools Development and Integration > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. > http://www.eclipsecon.org/osdn > _______________________________________________ > Wrapper-user mailing list > Wra...@li... > https://lists.sourceforge.net/lists/listinfo/wrapper-user |
|
From: Brandsdorfer, W. <wil...@et...> - 2004-01-21 17:53:56
|
Greetings,=20 I'm having trouble wrapping a Java program that uses multiple native = libraries. The application is a JMS (IBM) MQSeries program that normally = requires=20 LD_LIBRARY_PATH =3D /opt/mqm/lib:/opt/mqm/java/lib (I'm running on = Solaris - wrapper 3.0.5)=20 My config has the following=20 wrapper.java.library.path.1=3D/etrade/home/wbrandsd/tools/wrapper_solaris= _3.0.5/lib wrapper.java.library.path.2=3D/opt/mqm//lib wrapper.java.library.path.3=3D/opt/mqm/java/lib But when I run it I get:=20 Exception in thread "main" java.lang.UnsatisfiedLinkError: no mqjbnd04 = in java.library.path I know that the path exists because the program runs fine when I set = LD_LIBRARY_PATH and run it without the wrapper.=20 I've also used the wrapper successfully on another (non-MQSeries) = program=20 Is there a known problem with multiple wrapper.java.library.paths?=20 Thanks,=20 Willy=20 |
|
From: Leif M. <le...@ta...> - 2004-01-21 02:59:35
|
Almar, There are a couple ways that you can get the latest source. One is to use CVS. Instructions can be found on the following page: http://sourceforge.net/cvs/?group_id=39428 Once you have CVS set up you can always do an update to get the newest code. Also, I never use it, but you can also download a snapshot of CVS from the following URL: http://cvs.sourceforge.net/cvstarballs/wrapper-cvsroot.tar.bz2 Both of the above are snapshots of the development CVS servers and will be between 24 and 48 hours out of date. That is something that SourceForge does to be able to handle the huge loads. It is not something I control. I usually try to only check in working code. But I do not guarantee that the CVS code will always work or even compile. Cheers, Leif Almar Ahad wrote: > Leif, > > I would like to check the code out for the next version of the Java > Service Wrapper from sourceforge, but I was unable to see how I can do > so on the site. Can you please send me a link to the code or let me > know how I can download the newest version. > |
|
From: Leif M. <le...@ta...> - 2004-01-21 02:47:48
|
Ewan,
How are you installing the service?
I am guessing that you specified the wrapper.ntservice.password
property on the
command line when you installed the Wrapper as a service:
Wrapper.exe -i ../conf/wrapper.conf wrapper.ntservice.password=xxxx
Any properties that you specify on the command line will be included
in the path to
executable field. This is because the Wrapper needs to be able to
reconstruct all
properties again when the service is run. In the case of the account
password, the
property is not actually needed when the service is run. But the
Wrapper treats all
command line properties equally.
If you specify the property in the wrapper.conf file rather than
from the command line
then it will not show up on the command line. I am not sure how you are
obtaining the
password. There may be a reason why it needs to be placed onto the
command line.
If you only want the password property to be set when the service is
installed, a
possible workaround would be to create a simple one line text file
called password.conf
that contains the wrapper.ntservice.password property. Place that file
into the same
directory as the wrapper.conf file. Then add the following line to the
end of the
wrapper.conf file: (the path is relative to the location of the
Wrapper.exe file)
#include ../conf/password.conf
The password.conf file will be loaded when you install the service.
Once it is installed
the file can be deleted. When the Wrapper is run later as a service,
it will ignore any
include statements which attempt to include files that no longer exist.
Cheers,
Leif
Ewan Carr wrote:
>Hi,
>
>Version 3.0.0 introduces
>"Add the ability to specify an account name and
>password when installing an NT service."
>
>Ive noticed that when you then look at the proerties
>of the service once you have installed it the password
>appears on the "path to executable" field in the
>clear.
>This seems a bit of a security problem. Is there a
>switch available so that the passowrd is removed once
>the service is installed
>
>Thanks for any info
>Ewan
>
>ps please reply to me as well as the list - Ta !
>
>
|
|
From: Almar A. <aa...@er...> - 2004-01-20 18:24:14
|
Leif, I would like to check the code out for the next version of the Java Service Wrapper from sourceforge, but I was unable to see how I can do so on the site. Can you please send me a link to the code or let me know how I can download the newest version. Thank You Almar Ahad Information Technology ERIN Engineering and Research, Inc. 2175 N. California Blvd. Suite 810 Walnut Creek, CA 94596 Tel: 925-943-7077 Fax: 925-943-7087 E-mail: aa...@er... |
|
From: <ewa...@ya...> - 2004-01-20 13:35:26
|
Hi, Version 3.0.0 introduces "Add the ability to specify an account name and password when installing an NT service." Ive noticed that when you then look at the proerties of the service once you have installed it the password appears on the "path to executable" field in the clear. This seems a bit of a security problem. Is there a switch available so that the passowrd is removed once the service is installed Thanks for any info Ewan ps please reply to me as well as the list - Ta ! ________________________________________________________________________ Yahoo! Messenger - Communicate instantly..."Ping" your friends today! Download Messenger Now http://uk.messenger.yahoo.com/download/index.html |
|
From: Leif M. <le...@ta...> - 2004-01-20 01:14:01
|
Almar, Please post questions to the wrapper-user list rather than the wrapper-cvs list. > I have the Java Service Wrapper configured to run JBoss as a Windows > NT Service. The problem I have is that I would like to have the JBoss > command console displayed on the desktop so I can see an errors that > come up while JBoss is running. I have looked at the wrapper.conf > file, but there seems to be no configuration to set this up. I would > like to set it up so that whenever the computer is started the and the > NT service is started Command console also comes up and stays up as > long as JBoss is running. > Bad news is that this is not possible with the 3.0.5 release of the Java Service Wrapper. Good news is that it has already been implemented and will be in the next release. Version 3.1.0 is still under active development so it is going to be a few more weeks before I am able to release it. If you want to try it out before an official release, feel free to check the code out from CVS. Cheers, Leif |
|
From: Leif M. <le...@ta...> - 2004-01-14 09:17:51
|
Sandeep,
After spending some time looking through the code, I managed to get
this fixed. I have
not personally made use of the ServiceManager's restart functionality in
the past and so
was not aware that I was not handling it correctly.
In 3.0.5, it looks like the Wrapper would exit with the correct exit
code if
WrapperManager.stop was used to stop the JVM. It was not working
correctly when
System.exit was used. That is when run as a Console app.
Running as an NT service was a different issue. A service has two
exit codes, a
win32 exit code and a service specific exit code.
SERVICE_STATUS.dwWin32ExitCode
SERVICE_STATUS.dwServiceSpecificExitCode
I had been setting the dwWin32ExitCode to the exit code of the JVM
correctly but
then I was proceeding to tell the service manager that the service had
stopped.
Apparently the failure recovery features of the service manager are only
invoked if the
service terminates abnormally. If it exits without sending a stopped
message then the
service manager assumes that the service failed even if it exited with a
code of 0.
I have implemented this so that the Wrapper will exit with an exit
code of 0 after
notifying the service manager that it has stopped if there was no
error. In the event
of a non-zero exit code, I exit the service before sending the stopped
message.
This all appears to be working.
Does anyone know what the intended differences between the win32
exit code
and service specific exit codes above are? The MSVC API docs do not really
explain how they are supposed to be used, and I want to make sure that I am
setting them to values that will be useful to users.
Also, the service recovery features allow you to specify a period
after which
any restart of the service will be reset. Setting this to 0 seems to
reset the count
immediately after launching a service. If you have specified a single
restart then the
service will restart infinitely.
If you set it to 1 day, then it will not restart if the service has
been restarted at all
within the last 24 hours. This is true even if the service was manually
stopped
sometime during that time period. Does that sound correct? I don't
think I have
any control over it so I hope so.
If anyone knows any sites that explain how services should be
behaving here
please forward them to me for my reference.
Cheers,
Leif
Sandeep Khanna wrote:
>Hi,
>
>Thanks for the prompt response. After visiting
>http://sourceforge.net/tracker/index.php?func=detail&aid=852491&group_id=39428&atid=425190
>
>I tried using WrapperManager.stop(-1) directly. On the console it showed
>that the JVM and eventually the wrapper exited with -1. But, when I run
>the same as a Windows service, the service just starts and stops
>normally without compaining about anything!
>
>Is there a specific exit code/codes for the Windows service manager to
>identify a service failure? A quick search on google did not reveal
>anything also.
>
>I appreciate your other suggestion about a seperated class and sending
>recovery mail using Java mail. Unfortunately, we wouldn't be going that way.
>
>Thanks in advance,
>Sandeep Khanna
>
>----- Original Message -----
>From: Leif Mortenson <le...@ta...>
>Date: Thursday, January 8, 2004 7:53 pm
>Subject: Re: [Wrapper-user] Java service - windows service recovery?
>
>
>
>>Sandeep,
>> Sorry, but the Wrapper does not currently exit with the correct
>>exit
>>code. I added
>>a feature request for this last month and try to get it into the
>>Wrapper
>>for a near future
>>version. You might want to monitor the feature request so you will
>>get
>>notifications
>>on its progress.
>>
>>
>>
>http://sourceforge.net/tracker/index.php?func=detail&aid=852491&group_id=39428&atid=425190
>
>
>> One alternative for you would be to write a simple utility
>>class
>>which you specify
>>as the main class (Ie the first parameter to WrapperSimpleApp) It
>>would start by
>>calling the WrapperManager.getJVMId() method to find out which
>>invocation number
>>the JVM was. If it is < 4 then call you real application's main
>>method. Otherwise
>>call a method that executes SendMail and then calls System.exit().
>>
>>Alternatively you
>>could make use of the Java Mail API rather than using SendMail. It
>>is
>>quite easy to
>>use.
>>
>> I am also working on another feature that will allow you to run
>>arbitrary external
>>programs in response to various events in the Wrapper life cycles.
>>Some
>>users have
>>needed this functionality so they could, for example, run an
>>application
>>after a JVM
>>crashes, but before a new one is launched. I was planning to have
>>events for the
>>startup and shutdown of the Wrapper as well. This feature is
>>still in
>>the design phase
>>so if you have any requirements you would like me to consider, go
>>ahead
>>and post them.
>>
>>
>>
>http://sourceforge.net/tracker/index.php?func=detail&aid=837037&group_id=39428&atid=425190
>
>
>>Cheers,
>>Leif
>>
>>Sandeep Khanna wrote:
>>
>>
>>
>>>Hi All,
>>>
>>>We have been using Java Service Wrapper for the past several
>>>
>>>
>>months to
>>
>>
>>>run a couple of Java programs as Windows services.
>>>
>>>Our current requirement needs us to use the Windows "service recovery
>>>options". In the Properties page of a service one can set 3 different
>>>actions to take when a service fails to start for 3 consecutive
>>>
>>>
>>times.>We needed this to be able to execute a restart the first 2
>>failures and
>>
>>
>>>execute a command-line SendMail.exe to send mail to support on the
>>>
>>>
>>3rd>failure.
>>
>>
>>>Unfortunately, my investigation has revealed that the Java Service
>>>Wrapper does not return an exit code to the Windows Service
>>>
>>>
>>manager to
>>
>>
>>>trigger the service recovery settings. I even tried using the 3
>>>integration technique as mentioned on the website, but to no success!
>>>
>>>Can somebody comment if this is possible using Java Service
>>>
>>>
>>Wrapper and
>>
>>
>>>it's current feature set and/or I am missing something here?
>>>
>>>If YES, please explain how?
>>>If NO, please suggest alternatives?
>>>
>>>Thanks in advance,
>>>Sandeep Khanna
>>>
>>>
>>>
>>>
>>
>>
>>
>
>
>
>
>-------------------------------------------------------
>This SF.net email is sponsored by: Perforce Software.
>Perforce is the Fast Software Configuration Management System offering
>advanced branching capabilities and atomic changes on 50+ platforms.
>Free Eval! http://www.perforce.com/perforce/loadprog.html
>_______________________________________________
>Wrapper-user mailing list
>Wra...@li...
>https://lists.sourceforge.net/lists/listinfo/wrapper-user
>
>
>
|
|
From: Leif M. <le...@ta...> - 2004-01-14 08:38:03
|
Minseok, In the future rather than sending me a mail directly, please post to the user list. It makes the mail available for other to learn from in the future :-) You do not need to be a member to post, although non-member posts will be delayed until I have Oked them. When any NT service runs, it does so by default using the SYSTEM account. This account has lots of privileges within your machine but does not have the ability to access the network, or perform a few other operations. In order to access network drives, you will need to specify an account to run the service as which has been configured with the requested network access. If you have mapped any network drives then those drives are usually user specific. To specify the account that the wrapper will run under, you will need to take a look at the following two properties. Once you have changed them you must uninstall and then reinstall the Wrapper as a service in order for the changes to take affect. wrapper.ntservice.account wrapper.ntservice.password http://wrapper.tanukisoftware.org/doc/english/props-nt.html Let me know, on-list, whether or not you get this working. Cheers, Leif Minseok Park wrote: >Hi, > > > >I'm using your java wrapper under my NT environment to run > >jboss and my other java applications as NT services. When > >they run in as a standalone mode(i mean running it from > >command window by typing run.bat under ./bin), they can > >access any remote mapped drives. However, when they run > >as NT service, they just can't access the remote drives. > > > >It doesn't seem to be java related issue, though? It woulb be > >great if you knew what the isssue is or could send me some > >advice... > > > >Thanks in advance, > > > >Minseok > > > > > |
|
From: Patrick W. <wo...@em...> - 2004-01-13 21:58:04
|
--- Patrick Woodworth <wo...@em...> wrote: > > I using the wrapper to control an app that uses an ill-behaved > library. > I set a filter to detect the string "Out of Memory" which the > library > will spit out before it calls System.exit(). However in testing it > looks like after the filter is triggered the wrapper is being told to > shutdown and this overrides the restart behaviour. Is there any way > to > make the restart take precedence regardless of what comes later? > Okay, I've found using wrapper.disable_shutdown_hook=TRUE to be an acceptable workaround. However it would be nice if the shutdown hook could be configured to ask for a restart rather than a shutdown from the wrapper so I could still get the benefits of an orderly shutdown before restarting. |
|
From: Marc W. <ma...@da...> - 2004-01-13 01:25:40
|
John, The problem is the java application you are trying to run with the wrapper (org.tanukisoftware.wrapper.test.Main) uses an awt Frame as it is designed to allow you to simulate different events that might happen to an application - http://wrapper.tanukisoftware.org/doc/english/example.html#testwrapper-c onsole - which will not work in a headless environment I couldn't find a good console app example but you should be able to whip up a simple looping Hello World app to test the wrapper on your box. Cheers -M -----Original Message----- From: wra...@li... [mailto:wra...@li...] On Behalf Of John Fraser Sent: Tuesday, 13 January 2004 11:13 AM To: wra...@li... Subject: [Wrapper-user] Headless RedHat 9.0 not liking wrapper Hello; While trying to get wrapper working on RedHat 9.0, I can't get it to work on my headless boxes. After searching the archives, I added the following line to my wrapper.conf: wrapper.java.additional.1=-Djava.awt.headless=true However, I still get the error below. Any help would be appreciated! INFO | jvm 5 | 2004/01/12 18:00:41 | start() INFO | jvm 5 | 2004/01/12 18:00:41 | Error in WrapperListener.start callback. java.awt.HeadlessException INFO | jvm 5 | 2004/01/12 18:00:41 | java.awt.HeadlessException INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.Window.<init>(Window.java:274) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.Frame.<init>(Frame.java:401) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.test.Main$MainFrame.<init>(Main.java:78) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.test.Main.start(Main.java:172) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.startInner(WrapperManager.java :1152) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.handleSocket(WrapperManager.ja va:1711) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.run(WrapperManager.java:2004) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.lang.Thread.run(Thread.java:534) |
|
From: John F. <Joh...@vi...> - 2004-01-13 00:12:39
|
Hello; While trying to get wrapper working on RedHat 9.0, I can't get it to work on my headless boxes. After searching the archives, I added the following line to my wrapper.conf: wrapper.java.additional.1=-Djava.awt.headless=true However, I still get the error below. Any help would be appreciated! INFO | jvm 5 | 2004/01/12 18:00:41 | start() INFO | jvm 5 | 2004/01/12 18:00:41 | Error in WrapperListener.start callback. java.awt.HeadlessException INFO | jvm 5 | 2004/01/12 18:00:41 | java.awt.HeadlessException INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:121) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.Window.<init>(Window.java:274) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.awt.Frame.<init>(Frame.java:401) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.test.Main$MainFrame.<init>(Main.java:78) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.test.Main.start(Main.java:172) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.startInner(WrapperManager.java :1152) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.handleSocket(WrapperManager.ja va:1711) INFO | jvm 5 | 2004/01/12 18:00:41 | at org.tanukisoftware.wrapper.WrapperManager.run(WrapperManager.java:2004) INFO | jvm 5 | 2004/01/12 18:00:41 | at java.lang.Thread.run(Thread.java:534) |
|
From: Patrick W. <wo...@em...> - 2004-01-12 22:26:25
|
I using the wrapper to control an app that uses an ill-behaved library. I set a filter to detect the string "Out of Memory" which the library will spit out before it calls System.exit(). However in testing it looks like after the filter is triggered the wrapper is being told to shutdown and this overrides the restart behaviour. Is there any way to make the restart take precedence regardless of what comes later? My filters are configured as: wrapper.filter.trigger.1=java.lang.OutOfMemoryError wrapper.filter.action.1=RESTART wrapper.filter.trigger.2=Out of Memory wrapper.filter.action.2=RESTART And here is the output of my log file: DEBUG | wrapperp | 2004/01/12 14:05:10 | send a packet PING : ping INFO | jvm 1 | 2004/01/12 14:05:11 | Received a packet PING : ping INFO | jvm 1 | 2004/01/12 14:05:11 | Send a packet PING : ok INFO | jvm 1 | 2004/01/12 14:05:11 | Out of Memory STATUS | wrapper | 2004/01/12 14:05:11 | Filter trigger matched. Restarting JVM. DEBUG | wrapper | 2004/01/12 14:05:11 | wrapperRestartProcess() called. INFO | jvm 1 | 2004/01/12 14:05:11 | You might want to try the -mx flag to increase heap size INFO | jvm 1 | 2004/01/12 14:05:11 | Stopping service Tomcat-Standalone INFO | jvm 1 | 2004/01/12 14:05:11 | Wrapper Manager: ShutdownHook started INFO | jvm 1 | 2004/01/12 14:05:11 | Send a packet STOP : 0 DEBUG | wrapperp | 2004/01/12 14:05:11 | read a packet PING : ok DEBUG | wrapper | 2004/01/12 14:05:11 | Got ping response from JVM DEBUG | wrapperp | 2004/01/12 14:05:11 | read a packet STOP : 0 DEBUG | wrapper | 2004/01/12 14:05:11 | JVM requested a shutdown. (0) DEBUG | wrapper | 2004/01/12 14:05:11 | wrapperStopProcess(0) called. DEBUG | wrapper | 2004/01/12 14:05:11 | Sending stop signal to JVM DEBUG | wrapperp | 2004/01/12 14:05:11 | send a packet STOP : NULL INFO | jvm 1 | 2004/01/12 14:05:11 | Received a packet STOP : INFO | jvm 1 | 2004/01/12 14:05:12 | Thread, Wrapper-Shutdown-Hook, handling the shutdown process. INFO | jvm 1 | 2004/01/12 14:05:12 | calling listener.stop() INFO | jvm 1 | 2004/01/12 14:05:12 | Catalina.stop: LifecycleException: This server has not yet been started INFO | jvm 1 | 2004/01/12 14:05:12 | LifecycleException: This server has not yet been started INFO | jvm 1 | 2004/01/12 14:05:12 | at org.apache.catalina.core.StandardServer.stop(StandardServer.java:2213) INFO | jvm 1 | 2004/01/12 14:05:12 | at org.apache.catalina.startup.Catalina.start(Catalina.java:543) INFO | jvm 1 | 2004/01/12 14:05:12 | at org.apache.catalina.startup.Catalina.execute(Catalina.java:400) INFO | jvm 1 | 2004/01/12 14:05:12 | at org.apache.catalina.startup.Catalina.process(Catalina.java:180) INFO | jvm 1 | 2004/01/12 14:05:12 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) INFO | jvm 1 | 2004/01/12 14:05:12 | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) INFO | jvm 1 | 2004/01/12 14:05:12 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) INFO | jvm 1 | 2004/01/12 14:05:12 | at java.lang.reflect.Method.invoke(Method.java:324) INFO | jvm 1 | 2004/01/12 14:05:12 | at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203) INFO | jvm 1 | 2004/01/12 14:05:12 | at BootstrapLauncher$1.run(BootstrapLauncher.java:146) INFO | jvm 1 | 2004/01/12 14:05:12 | returned from listener.stop() INFO | jvm 1 | 2004/01/12 14:05:12 | Send a packet STOPPED : 0 DEBUG | wrapperp | 2004/01/12 14:05:12 | read a packet STOPPED : 0 DEBUG | wrapper | 2004/01/12 14:05:12 | JVM signalled that it was stopped. INFO | jvm 1 | 2004/01/12 14:05:12 | Closing socket. INFO | jvm 1 | 2004/01/12 14:05:12 | Closed socket: java.net.SocketException: socket closed DEBUG | wrapperp | 2004/01/12 14:05:12 | socket read no code (closed?). INFO | jvm 1 | 2004/01/12 14:05:13 | Server daemon shut down INFO | jvm 1 | 2004/01/12 14:05:13 | Wrapper Manager: ShutdownHook complete DEBUG | wrapper | 2004/01/12 14:05:13 | JVM exited normally. STATUS | wrapper | 2004/01/12 14:05:14 | <-- Wrapper Stopped |
|
From: Michael K. <M.K...@gm...> - 2004-01-12 13:19:01
|
Hello, I've a problem with the java service wrapper. After running for some time (some hours), the following happens: ERROR | wrapper | 2004/01/08 14:29:28 | JVM appears hung: Timed out waiting for signal from JVM. ERROR | wrapper | 2004/01/08 14:29:28 | Java Virtual Machine did not exit on request, terminated STATUS | wrapper | 2004/01/08 14:29:35 | Launching a JVM... INFO | jvm 2 | 2004/01/08 14:29:52 | Wrapper (Version 3.0.5) The ping.interval is set to 30 and the ping.timeout to 120 seconds. The CPU isn't at 100% usage. Can anybody please give me a hint, why the wrapper thinks the JVM hangs ? (The JVM is definitly still running!) Many thanks for your help! Greetings Michael -- +++ GMX - die erste Adresse für Mail, Message, More +++ Neu: Preissenkung für MMS und FreeMMS! http://www.gmx.net |
|
From: Sandeep K. <san...@vi...> - 2004-01-09 22:03:25
|
Hi, In regards to the Windows service failure recovery discussion, I tried another product called FireDaemon (http://www.firedaemon.com) This product exits appropriately and triggers the Windows service failure recovery hooks like running external programs. The following are some useful findings using sc.exe in windows command prompt. -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< C:\Sandeep\java_service\bin>sc qfailure testwrapper [SC] GetServiceConfig SUCCESS SERVICE_NAME: testwrapper RESET_PERIOD : 60 seconds REBOOT_MESSAGE : COMMAND_LINE : c:\sandeep\sendmail.exe /SFILE:c:\sandeep\wrapper-sendmail.xml FAILURE_ACTIONS : RUN PROCESS -- Delay = 20000 milliseconds RUN PROCESS -- Delay = 20000 milliseconds RUN PROCESS -- Delay = 20000 milliseconds C:\Sandeep\java_service\bin>sc qfailure testfiredaemon [SC] GetServiceConfig SUCCESS SERVICE_NAME: testfiredaemon RESET_PERIOD : 60 seconds REBOOT_MESSAGE : COMMAND_LINE : c:\sandeep\sendmail.exe /SFILE:c:\sandeep\firedaemon-sendmail.xml FAILURE_ACTIONS : RUN PROCESS -- Delay = 20000 milliseconds RUN PROCESS -- Delay = 20000 milliseconds RUN PROCESS -- Delay = 20000 milliseconds -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< C:\Sandeep\java_service\bin>sc query testwrapper SERVICE_NAME: testwrapper TYPE : 10 WIN32_OWN_PROCESS STATE : 1 STOPPED (NOT_STOPPABLE,NOT_PAUSABLE,IGNORES_SHUTDOWN) WIN32_EXIT_CODE : 1067 (0x42b) SERVICE_EXIT_CODE : 0 (0x0) CHECKPOINT : 0x0 WAIT_HINT : 0x0 C:\Sandeep\java_service\bin>sc query testfiredaemon SERVICE_NAME: testfiredaemon TYPE : 10 WIN32_OWN_PROCESS STATE : 1 STOPPED (NOT_STOPPABLE,NOT_PAUSABLE,IGNORES_SHUTDOWN) WIN32_EXIT_CODE : 1067 (0x42b) SERVICE_EXIT_CODE : 0 (0x0) CHECKPOINT : 0x0 WAIT_HINT : 0x0 C:\Sandeep\java_service\bin> -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< MyWrapperListener.java ====================== import org.tanukisoftware.wrapper.WrapperManager; import org.tanukisoftware.wrapper.WrapperListener; /** * <p>Title: </p> * <p>Description: </p> * <p>Copyright: Copyright (c) 2002</p> * <p>Company: XXXXXXXX </p> * @author Sandeep Khanna * @version 1.0 */ public class MyWrapperListener implements WrapperListener { /*--------------------------------------------------------------- * Constructors *-------------------------------------------------------------*/ private MyWrapperListener() { } /*--------------------------------------------------------------- * WrapperListener Methods *-------------------------------------------------------------*/ /** * The start method is called when the WrapperManager is signaled by the * native wrapper code that it can start its application. This * method call is expected to return, so a new thread should be launched * if necessary. * * @param args List of arguments used to initialize the application. * * @return Any error code if the application should exit on completion * of the start method. If there were no problems then this * method should return null. */ public Integer start(String[] args) { System.out.println("SANDEEP: MyWrapperListener.start()"); try { new java.util.Timer().schedule( new MyTimerTask(args) ,5000); //new Thread(new TCPListener(args),"TCPListener").start(); System.out.println("SANDEEP: Timer to start MyTimerTask scheduled."); } catch(Exception e) { System.out.println("SANDEEP: Exception caught while running MyTimerTask: " + e); return new Integer(-1); } return null; } /** * Called when the application is shutting down. The Wrapper assumes that * this method will return fairly quickly. If the shutdown code code * could potentially take a long time, then WrapperManager.stopping() * should be called to extend the timeout period. If for some reason, * the stop method can not return, then it must call * WrapperManager.stopped() to avoid warning messages from the Wrapper. * * @param exitCode The suggested exit code that will be returned to the OS * when the JVM exits. * * @return The exit code to actually return to the OS. In most cases, this * should just be the value of exitCode, however the user code has * the option of changing the exit code if there are any problems * during shutdown. */ public int stop(int exitCode) { System.out.println("SANDEEP: MyWrapperListener.stop() called with exit code = " + exitCode); // m_app.stop(); return exitCode; } /** * Called whenever the native wrapper code traps a system control signal * against the Java process. It is up to the callback to take any actions * necessary. Possible values are: WrapperManager.WRAPPER_CTRL_C_EVENT, * WRAPPER_CTRL_CLOSE_EVENT, WRAPPER_CTRL_LOGOFF_EVENT, or * WRAPPER_CTRL_SHUTDOWN_EVENT * * @param event The system control signal. */ public void controlEvent(int event) { System.out.println("SANDEEP: MyWrapperListener caught control event: " + event); if (WrapperManager.isControlledByNativeWrapper()) { // The Wrapper will take care of this event } else { // We are not being controlled by the Wrapper, so // handle the event ourselves. if ( (event == WrapperManager.WRAPPER_CTRL_C_EVENT) || (event == WrapperManager.WRAPPER_CTRL_CLOSE_EVENT) || (event == WrapperManager.WRAPPER_CTRL_SHUTDOWN_EVENT)) { WrapperManager.stop(0); } } } /*--------------------------------------------------------------- * Main Method *-------------------------------------------------------------*/ public static void main(String[] args) { // Start the application. If the JVM was launched from the native // Wrapper then the application will wait for the native Wrapper to // call the application's start method. Otherwise the start method // will be called immediately. System.out.println("SANDEEP: WrapperListener starting the application..."); WrapperManager.start(new MyWrapperListener(), args); } class MyTimerTask extends java.util.TimerTask { String[] args; MyTimerTask(String[] args){ this.args = args; } public void run() { new MyApp(args); } } } -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< MyApp.java ========== import java.util.*; import org.tanukisoftware.wrapper.WrapperManager; public class MyApp { MyApp(String[] args) { new Timer().schedule(new TimerTask(){ public void run() { System.out.println ("SANDEEP: MyApp started."); System.out.println ("SANDEEP: Exiting with code 1067"); WrapperManager.stop (1067); //System.exit(1067); } } , 10000); } public static void main(String[] args) { new MyApp(args); } } -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< -- 0>< ----- Original Message ----- From: Leif Mortenson <le...@ta...> Date: Thursday, January 8, 2004 7:53 pm Subject: Re: [Wrapper-user] Java service - windows service recovery? > Sandeep, > Sorry, but the Wrapper does not currently exit with the > correct exit > code. I added > a feature request for this last month and try to get it into the > Wrapper > for a near future > version. You might want to monitor the feature request so you > will get > notifications > on its progress. > http://sourceforge.net/tracker/index.php? func=detail&aid=852491&group_id=39428&atid=425190 > > One alternative for you would be to write a simple utility > class > which you specify > as the main class (Ie the first parameter to WrapperSimpleApp) > It > would start by > calling the WrapperManager.getJVMId() method to find out which > invocation number > the JVM was. If it is < 4 then call you real application's main > method. Otherwise > call a method that executes SendMail and then calls System.exit(). > > Alternatively you > could make use of the Java Mail API rather than using SendMail. > It is > quite easy to > use. > > I am also working on another feature that will allow you to > run > arbitrary external > programs in response to various events in the Wrapper life cycles. > Some > users have > needed this functionality so they could, for example, run an > application > after a JVM > crashes, but before a new one is launched. I was planning to have > events for the > startup and shutdown of the Wrapper as well. This feature is > still in > the design phase > so if you have any requirements you would like me to consider, go > ahead > and post them. > http://sourceforge.net/tracker/index.php? func=detail&aid=837037&group_id=39428&atid=425190 > > Cheers, > Leif > > Sandeep Khanna wrote: > > >Hi All, > > > >We have been using Java Service Wrapper for the past several > months to > >run a couple of Java programs as Windows services. > > > >Our current requirement needs us to use the Windows "service recovery > >options". In the Properties page of a service one can set 3 different > >actions to take when a service fails to start for 3 consecutive > times.>We needed this to be able to execute a restart the first 2 > failures and > >execute a command-line SendMail.exe to send mail to support on > the 3rd > >failure. > > > >Unfortunately, my investigation has revealed that the Java Service > >Wrapper does not return an exit code to the Windows Service > manager to > >trigger the service recovery settings. I even tried using the 3 > >integration technique as mentioned on the website, but to no success! > > > >Can somebody comment if this is possible using Java Service > Wrapper and > >it's current feature set and/or I am missing something here? > > > >If YES, please explain how? > >If NO, please suggest alternatives? > > > >Thanks in advance, > >Sandeep Khanna > > > > > > > > |
|
From: Sandeep K. <san...@vi...> - 2004-01-09 19:21:44
|
Hi, Thanks for the prompt response. After visiting http://sourceforge.net/tracker/index.php?func=detail&aid=852491&group_id=39428&atid=425190 I tried using WrapperManager.stop(-1) directly. On the console it showed that the JVM and eventually the wrapper exited with -1. But, when I run the same as a Windows service, the service just starts and stops normally without compaining about anything! Is there a specific exit code/codes for the Windows service manager to identify a service failure? A quick search on google did not reveal anything also. I appreciate your other suggestion about a seperated class and sending recovery mail using Java mail. Unfortunately, we wouldn't be going that way. Thanks in advance, Sandeep Khanna ----- Original Message ----- From: Leif Mortenson <le...@ta...> Date: Thursday, January 8, 2004 7:53 pm Subject: Re: [Wrapper-user] Java service - windows service recovery? > Sandeep, > Sorry, but the Wrapper does not currently exit with the correct > exit > code. I added > a feature request for this last month and try to get it into the > Wrapper > for a near future > version. You might want to monitor the feature request so you will > get > notifications > on its progress. > http://sourceforge.net/tracker/index.php?func=detail&aid=852491&group_id=39428&atid=425190 > > One alternative for you would be to write a simple utility > class > which you specify > as the main class (Ie the first parameter to WrapperSimpleApp) It > would start by > calling the WrapperManager.getJVMId() method to find out which > invocation number > the JVM was. If it is < 4 then call you real application's main > method. Otherwise > call a method that executes SendMail and then calls System.exit(). > > Alternatively you > could make use of the Java Mail API rather than using SendMail. It > is > quite easy to > use. > > I am also working on another feature that will allow you to run > arbitrary external > programs in response to various events in the Wrapper life cycles. > Some > users have > needed this functionality so they could, for example, run an > application > after a JVM > crashes, but before a new one is launched. I was planning to have > events for the > startup and shutdown of the Wrapper as well. This feature is > still in > the design phase > so if you have any requirements you would like me to consider, go > ahead > and post them. > http://sourceforge.net/tracker/index.php?func=detail&aid=837037&group_id=39428&atid=425190 > > Cheers, > Leif > > Sandeep Khanna wrote: > > >Hi All, > > > >We have been using Java Service Wrapper for the past several > months to > >run a couple of Java programs as Windows services. > > > >Our current requirement needs us to use the Windows "service recovery > >options". In the Properties page of a service one can set 3 different > >actions to take when a service fails to start for 3 consecutive > times.>We needed this to be able to execute a restart the first 2 > failures and > >execute a command-line SendMail.exe to send mail to support on the > 3rd>failure. > > > >Unfortunately, my investigation has revealed that the Java Service > >Wrapper does not return an exit code to the Windows Service > manager to > >trigger the service recovery settings. I even tried using the 3 > >integration technique as mentioned on the website, but to no success! > > > >Can somebody comment if this is possible using Java Service > Wrapper and > >it's current feature set and/or I am missing something here? > > > >If YES, please explain how? > >If NO, please suggest alternatives? > > > >Thanks in advance, > >Sandeep Khanna > > > > > > > > |
|
From: Nate G. <gel...@tr...> - 2004-01-09 03:03:08
|
Hello, We are using Wrapper 3.0.5 on Solaris. The tomcat process that Wrapper starts is creating world readable/writable files. I found a closed bug in the bug database stating that there was a call to umask(0) which was making wrapper started processes write=20 world readable/writable files. I looked in the 3.0.5 code base and see that this patch has been applied and the umask(0) removed. But the wrapper is still starting tomcat and writing world readable/writable files no matter what I set the umask to in the startup scripts. Can anyone help? thanks. http://sourceforge.net/tracker/?group_id=3D39428&atid=3D425187&func=3Ddet= ail&a id=3D788849 --( Nate Gelbard, QA Engineer =20 --( Tripwire, Inc., The Integrity Assurance Company |
|
From: Leif M. <le...@ta...> - 2004-01-09 01:22:25
|
Mark Lassau wrote: >The wrapper is smart enough to use a different port if 1777 is already >being used by the first service, >but you may prefer to set the second service to use (eg) 1778. >This will stop unintersting log messages. > > Actually as of version 3.0.4, you can remove the wrapper.port property all together. If it is not specified, then the Wrapper will quietly allocate a port of its own choosing. The property is still there so that users can force the Wrapper to use a specific port. I wanted to get rid of it because it was not a feature that most users cared about and it is always a good idea to make things simpler where possible. Newer versions of the Wrapper do not include that property in the sample conf file any more. Cheers, Leif |
|
From: Mark L. <ml...@bi...> - 2004-01-09 01:14:03
|
We do this all the time on Windows servers. You just need to ensure that each service has a unique name. In the wrapper.conf file : # Name of the service wrapper.ntservice.name=foobar Also it is a good idea if you use distinct and meaningful display names (obviously). The wrapper is smart enough to use a different port if 1777 is already being used by the first service, but you may prefer to set the second service to use (eg) 1778. This will stop unintersting log messages. Leif Mortenson wrote: >Guofeng, >You should have no problems running two different instances of >the Wrapper of the same machine. Just install the two copies into >different directories and make sure that they do not have conflicting >NT service names or log files. >Everything else should be automatic. > >Guofeng Zhang wrote: > > > >>I need to install two services by wrapper on the same machine, do I need further configuration in the conf file? >> >>I find that the wrapper assign a jvm id to a service instance. >> >> >> >> >The jvm id is simply a way for an individual JVM to tell >whether it is the first invocation or whether the Wrapper has >restarted the JVM x number of times. > >Give it a try and post back if you have any questions. Be >sure to read over the integration section of the documentation. > >Cheers, >Leif > > > > >------------------------------------------------------- >This SF.net email is sponsored by: IBM Linux Tutorials. >Become an expert in LINUX or just sharpen your skills. Sign up for IBM's >Free Linux Tutorials. Learn everything from the bash shell to sys admin. >Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click >_______________________________________________ >Wrapper-user mailing list >Wra...@li... >https://lists.sourceforge.net/lists/listinfo/wrapper-user > > > > |