Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Applet using multiple self-signed JARs

 
Marcelino Parado
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I'm working on an Applet which is not in a JAR. With the security issues/requirements with the latest versions of JRE, we now need to JAR the applet (and sign it). And when we did, we realized that our JAR file reached 30mb in file size! (.java files already excluded). (We do have lots of transactions with this applet)

Now we're exploring if it is possible to make this applet use separate signed jar files, which would be downloaded only as the user access the corresponding transactions. We've tried it but we've only managed to download the signed jar file which contained the applet but when we access the transactions, the JAR file wasn't downloaded. =/

I've read oracle articles about JRE / JAR signing but they didn't mention anything about applet using multiple JARs.

Need some advice / guidance on what could we do next to make this work.

Thank you very much.
 
Tony Docherty
Bartender
Posts: 3054
59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What html are you using to deploy the applet?
Have you listed all the required jars in the archive attribute?
 
Marcelino Parado
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Here's block of html code for my applet:



...

I'm trying not put the other JAR files in the archive attribute to make the initial access of the applet faster. I want the other JAR files to be downloaded only as the user access the corresponding transactions.

For example:
"JAR A" will only be downloaded as "user A" accessed "Transaction A". (Assuming "JAR A" contains the classes corresponding to "Transaction A".)

I was able to make this approach work in lower versions of JRE (1.7 update 21 or lower).

Still a bit confused on what could be the next step for me. =/

Thank you.
 
Tony Docherty
Bartender
Posts: 3054
59
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found this oracle document which suggests that indexing the jars will ensure only the required jars are downloaded.
 
Marcelino Parado
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Tony. I'll try this "indexing". Give you feedback on this. Thank you very much.
 
Tony Docherty
Bartender
Posts: 3054
59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My pleasure, yes please do let us know if it works as it may well help other people in the future.
 
Marcelino Parado
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry for the late post. Just want to give you an update:

JAR indexing solved my problem.

I've added in my manifest file a declaration similar with the following:
Class-Path: Group1.jar Group2.jar

and
execute the jar indexing command:

JAR I MyMainJAR.jar

...

Group1.jar and Group2.jar are now only downloaded as the user accessed/used the corresponding transactions/classes that are included in those JAR files.

Thank you very much Tony for your input.


 
Tony Docherty
Bartender
Posts: 3054
59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Really pleased to hear it has solved your problem and thanks for updating the thread.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic