Which, if any, of the automatically generated stub & skeleton class files does one need to include in a JAR file to be used when creating stand-alone clients? (I would like to create a client-side jar file which contains only the class files actually needed by the client.)

Siva Visveswaran

The answer is really not that generic as one may like to believe! Basically what a client needs to invoke the services of an EJB layer are:

  • locate the home interface (using a JNDI SPI) & invoke methods of the bean instances (over IIOP). Depending on the vendor (e.g. IONA builds JNDI over CORBA) the actual files will vary. You have to check with your vendor.
  • definitions of serializable objects that are returned to client due to network considerations (instead of object references).
[Can someone please provide examples, for a specific EJB server if need be?]

See also: