Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JWS Applet fails to start on 1.1.7, worked on 1.1.6 #269

Open
shyrodgau opened this issue May 25, 2020 · 17 comments
Open

JWS Applet fails to start on 1.1.7, worked on 1.1.6 #269

shyrodgau opened this issue May 25, 2020 · 17 comments
Labels
bug Something isn't working tracked internally

Comments

@shyrodgau
Copy link

I attach logs from 1.1.6 and 1.1.7 (the earlier one is from 1.1.7!)

The JWS Application works on OWS 1.1.6. On OWS 1.1.7 it starts up, but ends before properly building up the Application Window.

Platform is Win10 64bit.

itw-javantx-2020-05-25_16_02_02.716_VERSION_1_1_6.log
itw-javantx-2020-05-25_15_31_19.967_VERSION_1_1_7.log

@sclassen
Copy link
Member

From 1.1.6 to 1.1.7 we changed the way OWS is terminated, because we saw some application did not end their process properly.

So OWS 1.1.7 will end the application when the main method returns. Please make sure in your application that main() only returns when the application is closed

@shyrodgau
Copy link
Author

It looks like it does not run the main Method at all because the jar (Main-class actually) is/should be dual-use Applet/Application. When I add a main method, it does not get called. It seems to "only" instantiate the subclassed Applet and call init/start etc. How then can "main" made not to terminate? Thanks in advance!

@shyrodgau
Copy link
Author

Refinement: it actually is declared with applet-desc in the jnlp, so actually no need to run as application at all...

@shyrodgau shyrodgau changed the title JWS Application fails to start on 1.1.7, worked on 1.1.6 JWS Applet fails to start on 1.1.7, worked on 1.1.6 May 27, 2020
@sclassen
Copy link
Member

You have a point.
It looks like we broke applets with the release of 1.1.7

@sclassen sclassen added the bug Something isn't working label May 27, 2020
@sclassen
Copy link
Member

Short question about the expected behavior.
Are the following assumptions correct?

  • The applet should start in a window.
  • It can only be terminated by closing the window.

@shyrodgau
Copy link
Author

Well, like it does in 1.1.6. Yes, start in a window. Can be terminated by closing the window or from inside the applet by System.exit() or maybe clean return from the run method

@shyrodgau
Copy link
Author

The termination is the point I am not entirely sure about. I was working on a bug inside my applet that appeared in Amazon Corretto + ITW or OWS (1.1.6) that it did not terminate on System.exit(), but could fix it by terminating the run Method (and then call System.exit(), no idea what does terminate it in the end). During the investigation, I chose the 1.1.7 OWS which leads to the bug report. Sorry about starting the confusion with the "application"

@sclassen
Copy link
Member

which run method?? on Applet API I only see init and start

@shyrodgau
Copy link
Author

The window size can be determined by parameters in the applet-desc in the jnlp:

 <applet-desc main-class="com.xx.yy.AppletZzz" width="850" height="650" name="My applet">
   <param name="language" value="DE"/>
 </applet-desc>

@shyrodgau
Copy link
Author

shyrodgau commented May 29, 2020

Hm, I see, mine implements Runnable and then in the start() Method fires off itself in a thread (without waiting in the start() Method for that thread to terminate of course), which may or may not be a common pattern. So I can't actually explain thoroughly why my applet can terminate programmatically. Can it be that no running threads left is such a condition?

@netopyr
Copy link
Contributor

netopyr commented May 29, 2020

Hi @shyrodgau
OpenWebStart does not support applets. It would certainly be nice, but currently we do not have the resources to implement it. You can either stick with the old version of OpenWebStart, if it works for you, or use IcedTea-Web. Another option is to sponsor the development of applet-support in OpenWebStart. Would that be interesting to you?

@shyrodgau
Copy link
Author

I see. Is there a place where this is documented? That would be nice .The applet is being used by our customers in the end (hopefully not very much longer, but currently...) and if we can point them to a notice that from 1.1.7 OWS does not support applets, then we can recommend either sticking with 1.1.6 or using ITW.

@netopyr
Copy link
Contributor

netopyr commented May 29, 2020

You can find the full list of features here: https://openwebstart.com/feature-table/
Please note that applets were never really supported. If they used to work with versions prior to 1.1.7, it is by coincidence. There may be other issues. We have never tested applets.

@mvw
Copy link

mvw commented Jun 8, 2020

Applets seem not to work in 1.1.8 too.

@mvw
Copy link

mvw commented Jun 8, 2020

Another option is to sponsor the development of applet-support in OpenWebStart.

Do you encourage code contributions?

I tried getting management to sponsor but did not succeed so far. Leaves only fixing it myself at the moment or dropping web start for some install4j solution.

First step would be to find out how to build ows + icedtea-web myself.

@sclassen
Copy link
Member

sclassen commented Jun 8, 2020

Hi, I can give you a start on the technical stuff:

ITW and OWS are both maven projects. So you should be good to go with mvn clean install
We build on a Java8 and a maven 3.5.4

Once you have the build running come back and I try to give you a starting point for a fix

@shyrodgau
Copy link
Author

@sclassen Thanks a lot for the hints. Will have a look on opportunity. Donating some coding does look more feasible than money...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working tracked internally
Projects
None yet
Development

No branches or pull requests

4 participants