|
From: Christophe L. <ler...@ho...> - 2004-11-24 12:55:47
|
Dear all, First of all, I would like to say that sourceforge is a very huge knowledge source for me. I like your work and hope your success will continue growing. Ohterwise, I'm really disapointed about the way to execute my app as a service with the wrapper. Here is the content of my wrapper.conf : Starting the SendLogByMail service... --> Wrapper Started as Service Using system timer. server listening on port 32000. Launching a JVM... command: "C:\J2EE\SDK1.4\jdk\bin\java.exe" -Djava.library.path="classes/lib" -classpath "classes/" -Dwrapper.key="Rfv8sZ_PcoRLht4W" -Dwrapper.port=32000 -Dwrapper.debug="TRUE" -Dwrapper.use_system_time="TRUE" -Dwrapper.version="3.1.2" -Dwrapper.native_library="wrapper" -Dwrapper.service="TRUE" -Dwrapper.cpu.timeout="10" -Dwrapper.jvmid=1 com.cleroux.Main JVM started (PID=3392) WrapperManager class initialized by thread: main Using classloader: sun.misc.Launcher$AppClassLoader@e80a59 Wrapper Manager: JVM #1 Wrapper Manager: Registering shutdown hook Wrapper Manager: Using wrapper Loaded native library: wrapper.dll Calling native initialization method. Initializing WrapperManager native library. Java Executable: C:\J2EE\SDK1.4\jdk\bin\java.exe Windows version: 5.1.2600 Java Version : 1.4.2_04-b04 Java HotSpot(TM) Client VM Java VM Vendor : Sun Microsystems Inc. Wrapper (Version 3.1.2) http://wrapper.tanukisoftware.org WrapperManager.start(com.cleroux.Main@14b7453, args[]) called by thread: main Open socket to wrapper... Opened Socket Send a packet KEY : Rfv8sZ_PcoRLht4W handleSocket(Socket[addr=/127.0.0.1,port=32000,localport=2313]) accepted a socket from 127.0.0.1 on port 2313 read a packet KEY : Rfv8sZ_PcoRLht4W Got key from JVM: Rfv8sZ_PcoRLht4W send a packet LOW_LOG_LEVEL : 1 send a packet PING_TIMEOUT : 30 Start Application. send a packet START : start Received a packet LOW_LOG_LEVEL : 1 Wrapper Manager: LowLogLevel from Wrapper is 1 Received a packet PING_TIMEOUT : 30 Wrapper Manager: PingTimeout from Wrapper is 30000 Received a packet START : start calling listener.start() Waiting to start... Waiting to start... Waiting to start... Waiting to start... Waiting to start... Startup failed: Timed out waiting for signal from JVM. As you can see, the wrapper try 5 times to launch the service unsuccessfully. I really ask my self why it does not ! If any one had an idea, I would be really happy ! Here is an extract of my main class : public class Main implements WrapperListener{ public Integer start(String[] arg0) { boolean flag=true; try{ Mailing mailing = new Mailing(); mailing.setDaemon(true); mailing.start(); while (mailing.isAlive()){ System.out.println("Thread encore vivant !"); Thread.sleep(6000); } } catch(Exception e){ System.exit(1); } return null; } public static void main(String[] args) { WrapperManager.start(new Main(), args); } } Thanks for your help ! Bye, Christophe (please excuse me for the quality of my english !) |