javax.jnlp.UnavailableServiceException: javax.jnlp.IntegrationService

The public knowledge pool and discussion forum of the OWS community. Do not post confidential information here!
rosbaldeston
Posts: 1
Joined: 03 Nov 2020, 18:06

javax.jnlp.UnavailableServiceException: javax.jnlp.IntegrationService

Post by rosbaldeston »

I'm trying to evaluate how we can continue to support a java web start application my company developed. Trying OWS as a way forward but I'm hitting an UnavailableServiceException when this application starts up. This error only occurs with OWS (or icedtea) and AdoptOpenJDK (1.8.0_272), runs Ok with JWS & 1.8.0.

Seeing this in the OWS logs:

Code: Select all

[ITW-APP ][2020-11-02 09:16:12.247 GMT][INFO ][sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:221)] 2020-11-02 09:16:12,247 ERROR: Unable to force the auto-creation of a desktop shortcut
javax.jnlp.UnavailableServiceException: javax.jnlp.IntegrationService
	at net.sourceforge.jnlp.services.XServiceManagerStub.lookup(XServiceManagerStub.java:107)
	at javax.jnlp.ServiceManager.lookup(ServiceManager.java:24)
	at com.mango.localwork.service.impl.DesktopJnlpShortcutServiceImpl.forceGenerateShortcut(DesktopJnlpShortcutServiceImpl.java:67)
	at com.mango.localwork.service.impl.DesktopJnlpShortcutServiceImpl.updateJnlpShortcut(DesktopJnlpShortcutServiceImpl.java:84)
	at com.mango.localwork.gui.ApplicationLauncher.initialise(ApplicationLauncher.java:139)
	at com.mango.localwork.gui.ApplicationLauncher.main(ApplicationLauncher.java:175)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:401)
	at net.sourceforge.jnlp.Launcher.access$200(Launcher.java:70)
	at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:654)
[ITW-APP ][2020-11-02 09:16:12.247 GMT][INFO ][sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:221)] 2020-11-02 09:16:12,247 ERROR: com.mango.localwork.LocalWorkingException: javax.jnlp.IntegrationService
[ITW-CORE][2020-11-02 09:17:46.464 GMT][DEBUG][net.sourceforge.jnlp.services.ServiceUtil] call privileged method: addSingleInstanceListener
[ITW-CORE][2020-11-02 09:17:46.464 GMT][DEBUG][net.sourceforge.jnlp.services.ServiceUtil] arg: com.mango.localwork.gui.ApplicationLauncher$2@8ce8895
[ITW-CORE][2020-11-02 09:17:46.504 GMT][DEBUG][net.sourceforge.jnlp.services.ServiceUtil] result: null
or this when launched under iced tea, which seems to be more or less the same kind of issue:

Code: Select all

2020-11-02 17:34:57,497 ERROR: Unable to force the auto-creation of a desktop shortcut
javax.jnlp.UnavailableServiceException: javax.jnlp.IntegrationService
	at net.sourceforge.jnlp.services.XServiceManagerStub.lookup(XServiceManagerStub.java:96)
	at javax.jnlp.ServiceManager.lookup(ServiceManager.java:23)
	at com.mango.localwork.service.impl.DesktopJnlpShortcutServiceImpl.forceGenerateShortcut(DesktopJnlpShortcutServiceImpl.java:67)
	at com.mango.localwork.service.impl.DesktopJnlpShortcutServiceImpl.updateJnlpShortcut(DesktopJnlpShortcutServiceImpl.java:84)
	at com.mango.localwork.gui.ApplicationLauncher.initialise(ApplicationLauncher.java:139)
	at com.mango.localwork.gui.ApplicationLauncher.main(ApplicationLauncher.java:175)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at net.sourceforge.jnlp.Launcher.launchApplication(Launcher.java:576)
	at net.sourceforge.jnlp.Launcher$TgThread.run(Launcher.java:945)
2020-11-02 17:41:45,506 ERROR: com.mango.localwork.LocalWorkingException: javax.jnlp.IntegrationService
Exception in thread "AWT-EventQueue-1" java.lang.NullPointerException
	at com.mango.localwork.gui.MainFrameController.openActionPerformed(MainFrameController.java:356)
	at com.mango.localwork.gui.panels.MainFrameView$6.actionPerformed(MainFrameView.java:173)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2348)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:252)
	at java.awt.Component.processMouseEvent(Component.java:6539)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
	at java.awt.Component.processEvent(Component.java:6304)
	at java.awt.Container.processEvent(Container.java:2239)
	at java.awt.Component.dispatchEventImpl(Component.java:4889)
	at java.awt.Container.dispatchEventImpl(Container.java:2297)
	at java.awt.Component.dispatchEvent(Component.java:4711)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4535)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)
	at java.awt.Container.dispatchEventImpl(Container.java:2283)
	at java.awt.Window.dispatchEventImpl(Window.java:2746)
	at java.awt.Component.dispatchEvent(Component.java:4711)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:760)
	at java.awt.EventQueue.access$500(EventQueue.java:97)
	at java.awt.EventQueue$3.run(EventQueue.java:709)
	at java.awt.EventQueue$3.run(EventQueue.java:703)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)
	at java.awt.EventQueue$4.run(EventQueue.java:733)
	at java.awt.EventQueue$4.run(EventQueue.java:731)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:730)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
	
Are there limits to the support of the jnlp-apis? is there some other jar I need to supply with this application for running under OpenJDK that doesn't bundle javaws.jar?

This app appears to use the following jnlp services: SingleInstanceService, SingleInstanceListener, IntegrationService, ServiceManager

Andreas Ehret
Posts: 48
Joined: 25 Mar 2020, 12:21

Re: javax.jnlp.UnavailableServiceException: javax.jnlp.IntegrationService

Post by Andreas Ehret »

There are limits in the supported jnlp-APIs. As OWS is based on IcedTea-Web you may observe the same behaviour if OWS does not complete or renew a feature.

Implementations (OWS + IcedTea-Web) are provided for SingleInstanceService, SingleInstanceListener, ServiceManager.

A good overview of what is provided and what is not provided yet can be found here: https://openwebstart.com/feature-table/
IntegrationService is on the list of unscheduled features. It has not been around in IcedTea-Web and didn't achieved higher priority by any OWS sponsors so far.

Post Reply