aspose file tools*
The moose likes Websphere and the fly likes Configure RAD to Avoid Re-Build and Re-Deploy Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Websphere
Bookmark "Configure RAD to Avoid Re-Build and Re-Deploy" Watch "Configure RAD to Avoid Re-Build and Re-Deploy" New topic
Author

Configure RAD to Avoid Re-Build and Re-Deploy

JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
I have seen people using WAS and WSAD. I think that they did some kind of configuration. If they modify the Java class code, they do not have to re-build or re-deploy the application. They are able to run and display the application the reflects the changes made.

I have no idea about how they did it.

I have WAS and RAD 6.0. How do I configure WAS and RAD to do the same thing? I would appreciate very much if anybody could help. Thank you.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29245
    
139

The WebSphere server that is embedded in RAD does the same thing. Are you trying to auto-deploy to that or to a separate WAS instance?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Daniel Gee
Ranch Hand

Joined: Aug 29, 2003
Posts: 202
I already have a WAS instance. It is already configured and working fine. But, each time I change some code in my Java classes, I have to re-build and re-deploy, which take time.

For the time being, I am working on some Java class that does not have any dependency on the involvement of EJB, messaging, etc. What I am trying to say is my current work concentrates on using the web server only.

Therefore, I wish to do some more configuration to AutoDeploy. I think what I need to do are:

1. setup right classpath in RAD to re-compile and re-build once I change my Java class code;
2. configure to deploy automatically.

Please provide instructions to do the above. I would really appreciate your help.

I am new to the WebSphere. I could not get help from my co-workers. Either they are too busy or they do not care about helping me.
[ May 08, 2006: Message edited by: Daniel Gee ]
Daniel Gee
Ranch Hand

Joined: Aug 29, 2003
Posts: 202
Would anybody kindly care about helping?
Daniel Gee
Ranch Hand

Joined: Aug 29, 2003
Posts: 202
Please help if you could.
Shailesh Chandra
Ranch Hand

Joined: Aug 13, 2004
Posts: 1081

Have patience !


There is Only one setting which will help you in this regard otherwise I don't recall any such configuration, Even I am not sure if there is any.

Modify the setting of your application and, set the reload to true, do not forget to put a reload time .

Websphere checks for a given time if any class has changed it reloads the modified class.

All you need to replace the modified class it wil work untill you change the signature of you EJBs.

To replace the class I use winrar, you can use winzip too which is less friendly in this regard.

Hope this helps

Shailesh


Gravitation cannot be held responsible for people falling in love ~ Albert Einstein
Daniel Gee
Ranch Hand

Joined: Aug 29, 2003
Posts: 202
I found this url for rapid deployment. Am I on the right track?

http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.etools.wrd.freeform.doc/topics/cwrdrapid.html
Chintan Rajyaguru
Ranch Hand

Joined: Aug 19, 2001
Posts: 341
Looks like you need some help. If you want to use the approach described in the link you have posted, I would go with Automatic installation project section. But wait, there is an even easier approach depending on what development tool you are using.

If you are using RAD and have installed WebSphere Application Server Test Environment, you can create a server instance within RAD. To do this, all you need to do is right click your EAR file in J2EE perspective and choose "Run on Server." RAD will ask you whether you want to create a new server or use an existing one (create a new if you haven't done so already) and RAD will run the application on the server. If you make changes to the application, depending on the change, you may
1. simply run the application again and see your changes (e.g. JSP changes)
2. restart the project within the server and see your changes (e.g. properties file changes or some server side code changes)
3. restart the server to see your changes (e.g. data source configuration)

Remember, all this is happening in the test environment, which is sort of a server running within RAD. So, if your application needs special configuration (say data source configuration), you will have to setup that configuration within the test environment. Once your application is stable, you can deploy to the standalone WAS server.

Let me know if you have more questions


ChintanRajyaguru.com
SOADevelopment.com - Coming soon!
JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
Hi Chintan, thanks for your reply.

I am still very confused.

First,

I followed the Automatic Installation Project section found at
http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.etools.wrd.freeform.doc/topics/cwrdrapid.html

1. I was able to follow the instructions. In the Parameter Configuration Settings dialog, I specify 9060 for the value of the serverJMXPort because I usually use localhost:9060 to bring up the Administrative console. (the serverName is server1 and the serverJMXHost is localhost)

2. Then I went to the Starting a rapid deployment session. From the command prompt, I typed wrd.bat at the place the WebSphere Application Server is installed.


From the DOS command prompt, I saw "Launching WebSphere Rapid Deployment. Please wait .... Starting Workbench .... Starting up the workbench. WebSphere Rapid Deployment ready for e-business ... Type 'q', 'quit', or 'exit' to shut down WebSphere Rapid Deployment processes.

Then nothing happened thereafter.

Q1. Is it normal?
Q2. How to I verify that the server on which I want to deploy my application is running?


originally posted by Chintan:
If you are using RAD and have installed WebSphere Application Server Test Environment, you can create a server instance within RAD. To do this, all you need to do is right click your EAR file in J2EE perspective and choose "Run on Server."


I use RAD.

Q3. What is the Test Environment.
Q4. I have successfully built my application. But, I do not see EAR files in RAD J2EE perspective.

Thanks for your help in advance.
JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309

restart the project within the server and see your changes (e.g. properties file changes or some server side code changes)


Please help me with what "restart the project within the server" mean.

Does it mean

1. under the Server tab in RAD J2EE perspective, right click on the WebSphere Application Server v6.0, and select the Run the Administrative Console.

2. in the Administrative Console, mark the project check box and click on Stop. After it is stopped, click on Start?
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29245
    
139

JiaPei,
I don't know Chintan meant for sure, but I think it means right click the server in the server view and select restart project/application.

You shouldn't have to go into the admin console to do this. You could, but then there is the chance that RAD gets confused again.
JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
Thanks a lot, Jeanne, for your valuable help. I have figured out how to automatically install EAR files, etc. on WAS v6.0 using the rapid deployment tool. I am still struggling with the RAD built-in WAS to streamline the building and deployment process.
[ June 09, 2006: Message edited by: JiaPei Jen ]
JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
Jeanne, thanks a lot for your continuing support.

I have one more question.

If I already have a "build" of my application by running ANT, I can modify my JSPs, properties file, server side Java classes code, re-configuration of data source, etc. Provided that I have the RAD built-in WAS test environment correctly set up, I can re-run the application, re-start a particular project, or re-start the server to see my code modifications in the browser.

What should I do if I have a "new build" of my application? For example, do I click on "Project" in RAD title bar area, select "Clean" from the menu? And then re-run the application? What am I supposed to do in order to see all the changes in the browser after I re-build the application?
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29245
    
139

JiaPei,
How did you get the original build into RAD? Did you import it?

Where is the actual development being done? I'm a bit confused what Ant is building vs what RAD is building.
JiaPei Jen
Ranch Hand

Joined: Nov 19, 2000
Posts: 1309
Soory for the confusion caused by me.

I think that I understand it now. Anytime I update my entire application from the version control repository, I should restart the server (probably it does hurt to clean the project first) because the modifications of code are across the spectrum from the front end all the way to the back end.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29245
    
139

JiaPei,
That is certainly safest. In theory RAD will autoupdate when you pull in the new code. This works well when you pull in a small amount of code. For a lot of code across layers, it confuses things. It's certainly faster to just restart the server.
kshitij raval
Greenhorn

Joined: Oct 20, 2001
Posts: 15
Hi JiaPei,

I would like to add to your confusion sorry about that. But I was just curious which "server" you are talking about here ...


I think that I understand it now. Anytime I update my entire application from the version control repository, I should restart the server


Are you talking of a proper WAS runninng on a seperate machine or WAS on your RAD Test Environment?


Your concern: I have seen people using WAS and WSAD. I think that they did some kind of configuration. If they modify the Java class code, they do not have to re-build or re-deploy the application. They are able to run and display the application the reflects the changes made

Daniel's concern: What I am trying to say is my current work concentrates on using the web server only. Therefore, I wish to do some more configuration to AutoDeploy


Yes you can do this with WebSphere Test Environment installed on your RAD:http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.etools.websphere.tools.common.doc/topics/cwte.html


I agree with Chintan and thats what we also do:
- You've RAD with Test Environement
- You create your web application and just say "Run on Server" - select the server you want and run your project on WAS within RAD
- You can do changes, and depending on what type of change it is, to see that reflection is very easy: (1) If you've done changes in just JSPs you can just do a Refresh (2) but even if you've done some changes in java code all you do again is right click and "run on server".

HTH and hope this is what you're looking for.

regards,
Kshitij
[ June 16, 2006: Message edited by: kshitij raval ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Configure RAD to Avoid Re-Build and Re-Deploy
 
Similar Threads
Sun JDK 1.5 with websphere 5
ANT script to deploy applns
Classpath variables
To Use the Test Server in RAD 6.0
TO deploy Application build in RSA 7.5.5 to WAS8