Ron created DAEMON-467:
--------------------------
Summary: prunsrv stop service not able to find springboot package
class
Key: DAEMON-467
URL: https://issues.apache.org/jira/browse/DAEMON-467
Project: Commons Daemon
Issue Type: Bug
Components: Procrun
Affects Versions: 1.4.0
Environment: @echo off
call set_environment.bat
set PRUNSRV=%BASE_PATH%\commons-daemon\amd64\prunsrv.exe
@echo on
%PRUNSRV% //IS//%Service_name% ^
--DisplayName="%Service_display_name%" ^
--Description="%Service_description%" ^
--StartPath=%BASE_PATH% ^
--LogPath=%LOG_PATH%^
--Jvm=%JVM% ^
--JavaHome=%JAVA_HOME_% ^
--Classpath="%JVM_CLS_PATH%" ^
--StartMode=jvm ^
--StopMode=jvm ^
--Startup=auto ^
++JvmOptions=%JVM_OPTION% ^
--StartClass=org.springframework.boot.loader.JarLauncher ^
--StopClass=com.dhl.link.mftagent.daemon.AgentDaemon ^
--StopMethod=stop ^
--StopTimeout=30 ^
--ServiceUser=LocalSystem ^
--LogLevel=debug
Reporter: Ron
Fix For: 1.4.0
Hi,
I have a apache camel in java springboot application and need to manage windows
service stop/start using prunsrv. For start is okay as I configured to use the
JarLauncher class. However during service stop, it's not working and it failed
to find the stop class. I tried already to use a classifier so the class will
not be under BOOT-INF package but still not working.
[2024-12-05 07:48:47] [debug] ( javajni.c:419 ) [10720] Loaded JVM DLL
'D:\LINKRELAYPST\jre\bin\server\jvm.dll', home 'D:\LINKRELAYPST\jre'.
[2024-12-05 07:48:47] [debug] ( javajni.c:424 ) [10720] JNI_GetCreatedJavaVMs...
[2024-12-05 07:48:47] [error] ( javajni.c:983 ) [10656] FindClass
com/dhl/link/mftagent/daemon/AgentDaemon failed
[2024-12-05 07:48:47] [debug] ( javajni.c:1092) [10656] Java worker thread
finished com/dhl/link/mftagent/daemon/AgentDaemon:stop with status = 3
Just wondering how to properly configure it.
Thank you!
--
This message was sent by Atlassian Jira
(v8.20.10#820010)