• Post Reply Bookmark Topic Watch Topic
  • New Topic

Setting the Codebase at runtime

 
mark pashley
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am developing an application that uses OSGi to download jar files at runtime. Some of these files use RMI (exporting services).
Modifying the the codebase after I have started the RMIRegistry seems to have no effect.
Am I right in thinking that RMIRegistry only reads this value at startup and caches the value?
Is there a way to force the RMIRegistry to re-read this value?
Is there a way of shuting down the RMIRegistry and re-starting it after setting the new codebase?
Any suggestions would be greatly appreciated.
Cheers
Mark
 
Chris Shepherd
Ranch Hand
Posts: 286
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mark, as far as I have found, there is no way to shut down the registry except to kill its JVM. I have found that starting it from within my code makes it cleaner to rerun my code and thus get a clean registry. You might be able to set up a separate program to run the registry. then you could write out to a file from your active program code. kill your registry program and then restart it, pulling in the file with the new codebase written in it. It would be a horrible mess fraught with pitfalls I'm sure, but if you gotta do it...
I'm sure this doesn't help much, but it might give you something to think about.
Chris
[ November 06, 2003: Message edited by: Chris Shepherd ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!