Hexagon Geospatial
MENU

Developer Discussions

Discuss topics with other Hexagon Geospatial Power Portfolio developers and experts to get the most out of our products.
Showing results for 
Search instead for 
Do you mean 
Reply
Highlighted
Super Contributor
Posts: 301
Registered: ‎02-10-2016
Accepted Solution

Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

HI team,

 

We're in a process to migrate a Java plugin from GMSC (before 16.5) to GMSC version 15.5.323.9. Our plugin has a simple SOAP server (HTTP 1.1) that communicates with IE. In the Java plugin project, we only references the GMSC core jar files, no external jar file referenced, so so should be no version conflict. We also confirm that the SOAP server is working independently 

 

 independently SOAP.png

 

Even though, there are some red warning, it still works. 

 

However, when we load the plugin in the GMSC, the soap server suddenly throws exception "Couldn't load light weight http server" which is very confusing.

 

Exception in GMSC.png

 

Appreciate all the suggestion and help. For convenience, I also attach the code implementing the SOAP service in GMSC Java plugin here

 

Kind regards

Frequent Contributor
Posts: 112
Registered: ‎04-05-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Bob,

 

some Java EE modules (like javax.xml.soap and javax.xml.ws) formerly included in Java SE got deprecated in Java 9 and removed in Java 11. You have to manually add them as third party dependencies.

 

Hope this helps.

 

Regards,

Sven

Super Contributor
Posts: 301
Registered: ‎02-10-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

[ Edited ]

HI Sven,

 

As I mention, I create an independently project, references only the GMSC core jars and the SOAP service works just fine, but when it runs from a GMSC plugin, it throws the exception. So, something in the GMSC running environment prevents it.

 

Kind regards,

Frequent Contributor
Posts: 112
Registered: ‎04-05-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Bob,

 

I can see that you included the independent project to your post about which you say that it works fine. It would be helpful if you sent the code of the version included in a GMSC plugin that is not working for you.

 

Regards,

Sven

Super Contributor
Posts: 301
Registered: ‎02-10-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Sven,

 

Thank you for looking at that. Here is the plugin source code.

Frequent Contributor
Posts: 112
Registered: ‎04-05-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Bob,

 

thanks for sharing your plugin code. Both the GMSC plugin (with GMSC 16.5 SP3) and the standalone application work fine for me. The endpoint is published correctly and I can call it via my browser.

 

19.02.2019 07:08:41 FINEST:    ListenerPlugin - endpoint.isPublished()= true                --> [pool-2-thread-2] nz.co.intergraph.extensions.ListenerPlugin.loadOnStart

 

All I did is reference my own GMSC jars library, because the path to the jars you referenced doesn't exist on my machine.

 

Maybe you have a bad reference or there is an issue with your GMSC client or server, I can't tell. Does it work if you install the plugin on the server and run it outside of debug mode?

 

Regards,

Sven

Super Contributor
Posts: 301
Registered: ‎02-10-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

HI sven,

 

Would you mind sending us back your updated working source code and your GMSC jars library?

In the mean time, I will try to use different references.

 

Kind regards,

Super Contributor
Posts: 301
Registered: ‎02-10-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Sven,

 

I've also just tried a couple of different ways to reference GMSC core jar library but it still shows the same error. So, I very appreciate if you could send us the updated working source code and explain how you do references. Thank you in advance

 

Kind regards, 

Frequent Contributor
Posts: 112
Registered: ‎04-05-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Hi Bob,

 

the only thing I ve changed is the reference in the classpath of the project and I cant send you that. Basically I've referenced every jar that is included in the GMSC program directory and it's subdirectories. I haven't changed anything in the code itself.

 

I doublechecked and noticed that I referenced the jars of version 16.5.304.1 because that's the version of my dev environment. Maybe thats the reason.

 

Sorry I can't help you on this issue.

 

Regards,

Sven

Super Contributor
Posts: 301
Registered: ‎02-10-2016

Re: Issue with migrating Java plugin having SOAP service to GMSC 16.5.323.9 version

Thanks Sven for looking at that. It really narrows down possible issue.

Do you need immediate support?
Please submit a Ticket through our
Development Ticket Portal.