aspose file tools*
The moose likes EJB and other Java EE Technologies and the fly likes how to reduce the deploy time of ejbdeploy command  Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "how to reduce the deploy time of ejbdeploy command  " Watch "how to reduce the deploy time of ejbdeploy command  " New topic
Author

how to reduce the deploy time of ejbdeploy command

Dini Bang
Greenhorn

Joined: Mar 21, 2006
Posts: 21
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???


SCJP, SCBCD, SCWCD
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17260
    
    6

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


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
Dini Bang
Greenhorn

Joined: Mar 21, 2006
Posts: 21
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

Joined: Mar 21, 2006
Posts: 21
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

Joined: Apr 14, 2004
Posts: 10336

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.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17260
    
    6

I'd just create an Ant script that does my builds for me, I can run Ant through most IDEs.

Mark
Dini Bang
Greenhorn

Joined: Mar 21, 2006
Posts: 21
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

Joined: Sep 20, 2005
Posts: 14
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

Joined: Mar 21, 2006
Posts: 21
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??
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to reduce the deploy time of ejbdeploy command