• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

One jar file or seperate jar files

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, All
I am just writing the user document and programmer note, I want to know whether I can put all the class file into one jar file and include this file when I run server and client.
I find lots of people here use two jar files one is for server, the other is for client. It is ok but where I put the stub class. It seems I have to put stub class both in server and client jar file. Is it too much redundency?
Need I create skeleton and stub for my application compatiable to both jdk1.1.* and java 2 or just use only one stub class used in java 2?
Any advice?
 
author
Posts: 3252
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Think of your reuse objectives! The Data class and its networked version should be completely generic and reusable. They can be expected to lead an independent life, so they are best packaged separately from the remainder of the application. You can use the Class-Path attribute in the Manifest file to tie the jars together.
A simple but clean packaging could be:
  • jar A with the local Data, the Data interface, and remote Data stubs
  • jar B with the Data network enhancements and the remote Data skeletons
  • jar C with the flight booking client; its class path would include jar A
  • jar D with the flight booking server code; its class path would include jars A and B
  • If your server is completely generic you could merge jars B and D.
    - Peter
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic