This is still work in progress and needs refinement (a How-I-Did-It not a How-To).
Running with Rational Application Developer 188.8.131.52 w/Interim Fix 003.
Although I’ve tested the concepts, yet, I haven’t yet managed to execute a compete cycle of Checkout (from CVS), Build App, Generate EAR, Deploy EAR to server. I still have issues to deal with regarding the migration from WS5.x to WS184.108.40.206 (It might not be solved before WS 6.0.1).
Some of the targets below are used to invoke Headless ANT targets instead of using a batch file as per IBM examples (regular ANT targets invoking Headless ANT targets).
Also, the ear.deploy target need to be reworked following the other targets (though it works in its current state).
Again this is still work in progress which I currently have to leave for a while.
For all the desperate Websphere ANT tasks googlers – here it is – deploy.xml
End of deploy.xml
Migrated Comment - Subhan on July 14, 2005: Nice theme for the blog. I came here surfing AJAX :)
Migrated Comment - Youssef on July 25, 2005: I am thinking of doing the same in my current project (customizing some Siebel application that runs on WAS and i have a WSAD workspace) However, I wanted to follow another approach! I was thinking that my ANT build file should be IDE independent (using regular javac for compiling and xdoclet to generate DDs) and only use the tasks related to WAS. What do you think of that?
Migrated Comment - Tamer Salama on July 25, 2005: Well Youssef: I think if you’re going to rely on WAS tasks anyway, then you’re at IBM’s mercy. It looks like their tasks are strongly dependent on WSAD/RAD workspaces. Moreover, some of the common ANT tasks might produce files that are “incompatible” with WAS (as was produced via the ear task) – you might want to dig into the differences. HTH
Migrated Comment - Youssef on July 26, 2005: Thanks, but you replied on the second part of my comment. The first was that I am thinking that the ant biuld should be IDE-independent so that you might use WSAD, eclipse 3.x or Netbeans. for debugging, i used to use remote debugging feature JPDA which worked great for me.
Migrated Comment - Tamer Salama on July 26, 2005: Absolutely! That was the idea about using ANT in the first place (IDE Independency). But, using IBM supplied ANT tasks meant that you?re tied to WSAD/RAD environment. For instance, placing a project under the workspace directory is not enough for the project to be comprehended by those ANT tasks. The project has to be explicitly “imported” into the “workspace” using another ANT task. I’d really love to see if anyone has a simpler approach for deploying WAS applications remotely. Sorry Youssef, I didn’t understand the part of remote debugging. May be if you wish to mail me about it? :)
Migrated Comment - xiuxiu on August 9, 2005: I just start the topic. And I am also willing to use ws_ant or wsadmin to complete the deployment.but Tamer’s weblog really disappointed me.Anyway, I still want to have a try. Wish to see the good result.
Migrated Comment - Sanjeet on March 18, 2006: Hello, I am trying to run the example C:\Program Files\IBM\Rational\SDP\6.0\rwd\eclipse\plugins\com.ibm.etools.j2ee.ant_220.127.116.11 provided by IBM. It is giving me error
[projectBuild] Building: AdderJAVA (Done) [projectSetBuild] ERROR: . Type=org.eclipse.jdt.core.problem Line=0 Resource=\AdderJAVA [projectSetBuild] ERROR: .. Message=The project was not built since its build path is incomplete. Cannot find the class file for java.lang.Object. Fix the build path then try building this project [projectSetBuild] ERROR: . Type=org.eclipse.jdt.core.problem Line=1 Resource=\AdderJAVA\com\ibm\etools\ant\extras\sample\AdderJava.java [projectSetBuild] ERROR: .. Message=The type java.lang.Object cannot be resolved. It is indirectly referenced from required .class files
I configured these properties only: classpathVariable.WAS_60_INSTALLDIR=C:/Program Files/IBM/WebSphere/AppServer1 targetRuntime.targetLocation=C:/Program Files/IBM/WebSphere/AppServer1 set WORKSPACE=C:\Program Files\IBM\Rational\SDP\6.0\rwd\eclipse\plugins\com.ibm.etools.j2ee.ant_18.104.22.168\Example Do I need to configure more properties? Why I am getting these error? Please advice me, Regards, Sanjeet.
Migrated Comment Stef P on May 31, 2006: I would like to ask you something concerning the headless targets, e.g. “headless.import”. The tasks that exist in its body, for example “eclipse.refreshLocal” and “ProjectImport” are not core ant tasks (right?). Are they eclipse’s extensions or what? Where can i find some info about them? Thanks, im trying to understand the buildfile im working on:))