Win a copy of 97 Things Every Java Programmer Should Know this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

Testing that dynamic code download does NOT occur

 
Ranch Hand
Posts: 92
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi folks,

I'm trying to ensure that dynamic code downloading doesn't occur when I run my client. Is is enough to see that the stub is loaded when running Java in verbose mode;

java -verbose -jar runme.jar
....
Loaded suncertify.server.Server_Stub from file:/C:/cygwin/home/jmcparla/SCJD/scjd/runme.jar]

I think I got this idea from this forum but I can't remember where.

There is only one class which I export to the RMI registry and it is suncertify.server.Server. I've used RMIC to build the stub.

Regards,

John
 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, technically it says 'You must provide all classes pre-installed so that no dynamic class downloading occurs.' I would think that doesn't mean to disable dynamic class downloading, but instead to make it 'unnecessary' by supplying all classes.

Just a guess from reading the assignment, though - that's how I interpreted that section, anyways. I would think ensuring all your class files are there would be sufficient.

 
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

John McParland wrote:I think I got this idea from this forum but I can't remember where.

I guess you find your inspiration here.
 
John McParland
Ranch Hand
Posts: 92
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Cindy / Roel,

that's cleared things up. That was the post I was looking for. I don't know how I couldn't find it.

Oh well, looks like I will be submitting this week. Getting nervous / excited.

Regards,

John
 
John McParland
Ranch Hand
Posts: 92
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If anyone's interested the output you get when you don't use the stubs (which happens in alone and server mode) is;

[Loaded suncertify.server.Server from file:/C:/cygwin/home/jmcparla/SCJD/runme.jar]
 
Normally trees don't drive trucks. Does this tiny ad have a license?
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic