Hello,
JDK 17
YAJSW 13.10
We have a problem with System Tray. We are sure that service is running, but the System Tray Icon stays black for the whole time, current status is not updated (it shows as if the service was not working but it is not true). However at the same time we are able to open the Tray icon and Start/Stop the service via the Tray. So only the current status is not up to date.
When I tried doing the following manually:
1. run stopService.bat
2. run startService.bat
3. run systemTrayIcon.bat
... I see in the command prompt of the SystemTrayIcon process:
io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: connect: /127.0.0.1:15002
But the interesting part is that when I do the following:
1. run stopService.bat
2. close the Tray manually via the Icon
3. run runConsole.bat
4. run systemTrayIcon.bat
....the System Tray is working correctly (status is updated and the icon is green when it should be green). No error about "AnnotatedConnectException"
Previously we used JDK 8 and YAJSW 12.08 and System Tray worked correctly out of the box.
Here is the conf file:
wrapper.tmp.path = ${jna_tmpdir}
wrapper.java.app.jar = lib\\***.jar
wrapper.java.additional.1 = -Dlogging.config=lib\\logback.xml
wrapper.java.additional.2 = -Xmx3g
wrapper.java.additional.3 = -Djava.io.tmpdir=${wrapper_home}\\..\\..\\tmp
wrapper.java.command.minVersion = 17
wrapper.console.loglevel=INFO
wrapper.logfile=${wrapper_home}/log/wrapper.log
wrapper.logfile.maxsize=10m
wrapper.logfile.maxfiles=10
wrapper.console.title=***
wrapper.ntservice.name=***
wrapper.ntservice.displayname=***
wrapper.ntservice.description=***
wrapper.ntservice.failure_actions.actions=RESTART
wrapper.ntservice.failure_actions.actions_delay=1000
wrapper.ntservice.interactive=true
wrapper.ntservice.console=true
wrapper.ntservice.starttype=AUTO_START
wrapper.debug=true
wrapper.tray=true
wrapper.tray.port=15002
wrapper.console.visible=true
wrapper.console.minimized=false
wrapper.console.loglevel=DEBUG
wrapper.logfile.loglevel=DEBUG
wrapper.tray.icon = ${wrapper_home}/../***_logo.png
wrapper.on_exit.0=SHUTDOWN
wrapper.on_exit.default=RESTART
wrapper.tray.commands = console
wrapper.tray.commands = startService
wrapper.tray.commands = stopService
wrapper.tray.commands = exitTray
[DEFAULT]
wrapper.working.dir=C:\Program Files (x86)\***
wrapper.java.command=C:\\Program Files\\Amazon Corretto\\jdk17.0.9_8\\bin\\java.exe
Please could you help with this issue?
in the case that the tray is not working corretly:
pls provide the output of the tray console and of the wrapper log file.
thanks.
-- Ron
When we do:
1. run startService.bat
2. run systemTrayIconW.bat
What we see in the console of "startService.bat":
What we see in the console of "systemTrayIcon.bat" :
(our app is running correctly, we are able to log in etc.)
And here the wrapper.log:
BTW, further investigations showed that probably in the scenario when we:
1. run stopService.bat
2. close the Tray manually via the Icon
3. run runConsole.bat
4. run systemTrayIcon.bat
... the tray is connected to the Console rather than to the Service. So the Tray Icon is green but the reason is that the Console is working.
Last edit: Kamil 2023-12-04
Please forgive me, above I pasted logs when I was playing around with JDK8. There should be everywhere Java 17, the behaviour is the same
I just corrected my previous error. Correct logs have been pasted in the post above