Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to reduce the deploy time of ejbdeploy command

 
Dini Bang
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ranchers..
I am deploying a Entity Bean JAR using the ejbdeploy command of the command line. Its working fine.
But now even if a change is made in single bean, i have to deploy the complete jar and get the deployed code. While if the same task is done in RAD its very quick.
Is there any way to generate deployment code either for individual enterprise beans that you have modified or added newly to the project???
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ejbdeploy? Is that a program that is needed for deploying on BEA or WebSphere? Do you actually have to run a seperate program to deploy?

Anyway, if you have an Ant or Maven build script, then you can simply run it and it will deploy it. It has the ability to determine which files to compile, when it needs to do certain tasks or not.

But you have to build that into your script. I suggest using that.

Mark
 
Dini Bang
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hiii..
Basically ,I have RAD(Rational's tool)to deploy n create the deployed jar from it. But I am explictly deploying the complied code using the ejbdeploy.bat of RAD.(And I am able to get the dseployed JAR too, from it) But its always takes the same amout of time to deploy the code even though only very few files(Beans) have changed. Whereas RAD for the first time takes quite higher time, but then onwards its quite quick. So I wanna know is there, so by which ejbdeploy.bat can be used so that it deploys only the changed files.
 
Dini Bang
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hiii..
Basically ,I have RAD(Rational's tool)to deploy n create the deployed jar from it. But I am explictly deploying the complied code using the ejbdeploy.bat of RAD.(And I am able to get the dseployed JAR too, from it) But its always takes the same amout of time to deploy the code even though only very few files(Beans) have changed. Whereas RAD for the first time takes quite higher time, but then onwards its quite quick. So I wanna know is there, so by which ejbdeploy.bat can be used so that it deploys only the changed files.
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Dini Bang:
Hiii..
Basically ,I have RAD(Rational's tool)to deploy n create the deployed jar from it. But I am explictly deploying the complied code using the ejbdeploy.bat of RAD.(And I am able to get the dseployed JAR too, from it) But its always takes the same amout of time to deploy the code even though only very few files(Beans) have changed. Whereas RAD for the first time takes quite higher time, but then onwards its quite quick. So I wanna know is there, so by which ejbdeploy.bat can be used so that it deploys only the changed files.


I think RAD uses some clever hot deployment to manage this. ejbdeploy is always slow - I think is regenerates and compiles all its deployment code each time you run it. You can have a search through the redBooks on IBM's website, but I don't remember anything that can be done. I'd just use RAD to deploy while you develop.
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'd just create an Ant script that does my builds for me, I can run Ant through most IDEs.

Mark
 
Dini Bang
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yep, I am trying to emulate Hot deployment, through my own command.

Anyways thank you all for responses.. do post your responses ,if you get any information..
 
Pratheep Nair
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You have to do ejbDeploy only when you add a new bean, add a new remote/local method to an existing bean or change the signature of an existing remote/local method. The important thing that ejbDeploy does is, it registers your EJB in the container through its JNDI name and creates the stub and proxy classes for your EJBs. So when the change involves any one of the things mentioned above, you have to deploy your beans. If you are doing some changes to the body of the bean method, you can just copy the bean class into the installedApps folder of WebSphere and restart the application. You very easily do all these through ANT scripts. You can check for changes using "touch", update the JARs and restart the application using wsadmin scripts. This is an interesting discussion...I feel so productive
 
Dini Bang
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
Thank you for the details of ejbdeploy...
But our problem is still stuck at the same place, i.e. RAD takes quite a time when I deploy the beans for the first time or when I change/add any new ejb references. But then on, even if I just add new method(services) it takes rarely few seconds . RAD also internally calls the ebjdeploy.bat file,then how does it manage to deploy only the changed files n not the others, n hence deploying the project very quick..
Can such thing be done through ANT/Batch such that we only deploy the changed beans??
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic