Hot questions for Using Applets in web applications

Top Java Programmings / Applets / web applications

Question:

So this year I found out that when compiling a java applet in Eclipse Oxygen that java applets are about to be obsolete. Is Oracle going to release a new API that allows applets in websites? If not, what are the alternatives and what are their advantages and disadvantages?


Answer:

Is Oracle going to release a new API that allows applets in websites?

No. They are accepting the decision of browser manufacturers to remove all plug-ins from their rendering of web pages. See Moving to a Plugin-Free Web for more info.

If not, what are the alternatives ..

HTML 5 and JS can replace the vast majority of the reasons people ever used applets.

.. and what are their advantages and disadvantages?

The primary advantage of JS / HTML is that - it is supported in modern browsers. It also helps keep the web page a keyboard navigable thin client.

Question:

I have a WEB-application which implements Java Applet technology. Java applet itself is opened from WEB-app and it is a FTP-client which semi-automatically(pre-configured IP, un, pw...) gets a file list from a FTP-server and user selects a file to transfer.

In Applet, the file is downloaded via FTP and then streamed through HTTPS to the WEB-app.

This functionality now needs a replacement as the Applet are no longer supported by majority of the browsers.

My own thought is that this function would be replace with JNLP. As JNLP cannot be embedded into "same session", the upload phase to WEB-app must be implemented differently.

I've been thinking that WEB-app would provide an one-time upload URL which would receive the file and then continue processing it.

What other possibilities I have and what would you recommend?


Answer:

If you want less to no code changes, go with JNLP, otherwise, refactor the view (if your using MVC) to use modern java web technologies such as Servlets, JSPs or JSF.