File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB start

 
Brian Nice
Ranch Hand
Posts: 195
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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).]
 
Brian Nice
Ranch Hand
Posts: 195
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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).]
 
ruilin yang
Ranch Hand
Posts: 334
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
 
Balaji Loganathan
author and deputy
Bartender
Posts: 3150
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi brain,
if u r using weblogic server 6.0 it comes out with their own build.cmd file -a build script which could help you to put the jar at appropriate location try to explore it.
Originally posted by Brian Nice:
Does any one have any ideas on this? I'm using windows 2000
If I say:
jar cfv salary.jar simpleBean\*.class meta-inf\*.*
]

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic