This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
I am working through the example in chapter 2 of Professional EJB from Wrox have a couple of questions. First I'm not sure if I created the .jar file correctly. I'm in a directory called c:\temp\ejb where I have two directories called /simpleBean which contains my .class files and /META-INF (which has the .xml file) When I do jar cfv salary.jar *.*, it jars everything including the .java files which are in the c:\temp\ejb directory. Does that mess things up? If so, how do I jar up just the files in the /simpleBean and /META-INF directories? also, after I create the application with the deploytool, called SimpleBean.ear, and try and add the .jar file that I created, I get: Warning: Could not re-open C:\temp\ejb\SimpleBean.ear C:\temp\ejb\SimpleBean.ear does not exist What do I need to do? Thanks Brian [This message has been edited by Brian Nice (edited August 29, 2001).] [This message has been edited by Brian Nice (edited August 29, 2001).]
Joined: Nov 02, 2000
Does any one have any ideas on this? I'm using windows 2000 If I say: jar cfv salary.jar simpleBean\*.class meta-inf\*.* it creates a jar file, but then in the deploytool when I try and add it to my newly created .ear file, it says "salary.jar does not appear to be a valid EJB JAR" If I say: jar cfv salary.jar *.* it creates a jar file, but then in the deploytool when I try and add it to my newly created .ear file, it says "There was an error inserting components into this application, the application has not been updated" what am I doing wrong? Thanks Brian [This message has been edited by Brian Nice (edited August 31, 2001).]
Brian, I followed the J2EE Tutorial. I found it was very useful for me. I went through the examples for creating .ear files and runned the examples successfully. You may try that. The link is http://java.sun.com/j2ee/tutorial/ Best luck Ruilin