• 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
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

Packaging of the server and client  RSS feed

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've decided to make one server.jar and one client.jar and package them both in scjd.jar together with the documentation and database file.
server.jar contains all the required classes to run the server (including stub/skel), but when I try to start the server without the -Djava.rmi.server.codebase argument, it complains about not finding the stub, even though it's there. When I specify server.jar as codebase it works, but I would like for the examiner to pass as few arguments to the program as possible.
Anyone got any information on this? The stub and skeleton are in the jar, so it should work..
 
ranger
Posts: 17314
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you have a manifest file in the jar file, that points to where the main class is, then you can have an executable jar file, and then you don't need any codebase at all.
Mark

Sample manifest file
 
Ranch Hand
Posts: 560
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Before you start the RMI Registry, issue the command,
set CLASSPATH=server.jar. The message you get is the result of RMI Registry not able to locate the _Stub and not the RMI server.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!