Wednesday, June 23, 2010

Build and Deploy SOA Composites using ANT targets

The steps to build and deploy a SOA composite using an ANT target of build.xml is demonstrated in the current post.

Steps
=====
1. Download build.properties and build.xml.
2. Place the above two files inside build or deploy folder of the composite project. i.e. if HelloWorldProject is the directory of the composite project, then these files should be located inside HelloWorldProject/build or HelloWorldProject/deploy
3. Change the property values of build.properties file as per your scenario. The documentation above each property should be self explanatory.
4. Ensure that you have ANT has been installed and paths have been property set in environment. You can find more details of installing ANT here
5. Now open the command promt and change to the directory where the above two downloaded files have been placed.
6. Use the three targets defined in build.xml as explained below ::
- If you require only to build the composite SAR, then type "ant compile-package"
- If you already have the jar and want to deploy onto SOA server, then type "ant deploy"
- If you want to both build and deploy, then type "ant buildAndDeploy" or just typing ant should suffice as buildAndDeploy has been given as the default target in build.xml

4 comments:

  1. Hi ,

    I tried ur link but landed in an error while deployment .Below is the summary of error:

    [deployComposite] Received HTTP response from the server, response code=500
    [deployComposite] ---->response code=500, error:Error during deployment: Error o
    ccured in processing sar file sca_HelloWorldProject_rev1.0 .jar before transferi
    ng into MDS store. Please make sure the sar file is a valid jar file.: C:\DOCUME
    ~1\ADMINI~1\LOCALS~1\Temp\1\sar_base_dir_1290166022807\deployed-composites\defau
    lt\HelloWorldProject_rev1.0 \META-INF\MANIFEST.MF (The system cannot find the pa
    th specified).

    Could you please let ne know what could be the possible reason

    ReplyDelete
  2. Hi Harish ,
    Thanks for this wonderful article.

    I am facing the below issue:

    1. Have generated AIA 11g ABCS using artifacts generator.
    2. Try to compile using this script. But got the below exception even when we set the "aia.jar" file in the classpath.

    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe8.java:3: package oracle.apps.aia.core.eh does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe8.java:3: package oracle.apps.aia.core does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe9.java:3: package oracle.apps.aia.core.eh does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe9.java:3: package oracle.apps.aia.core does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe1.java:107: package oracle.apps.aia.core.eh.logging does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe11.java:423: package oracle.apps.aia.core.eh.logging does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe11.java:432: package oracle.apps.aia.core.eh.logging does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe12.java:447: package oracle.apps.aia.core.eh.logging does not exist
    [scac] C:\Development\CreateItemEbizReqABCSImpl\SCA-INF\bpel\CreateItemEbizReqABCSImplProcess\src\or
    abpel\createitemebizreqabcsimplprocess\ExecLetBxExe12.java:456: package oracle.apps.aia.core.eh.logging does not exist


    I am not able find solution for the same.

    ReplyDelete
  3. Hi Harish,

    Thanks i am able to fix that error, there was a space in classpath of the jar file aia.jar.

    Now I am able deploy the composite :).

    Regards,
    Srini

    ReplyDelete
  4. Hi Harish/Srini,

    Can you please let us know how to deploy AIA composite using above build.properties and build.xml? How to set aia.jar classpath in ant-sca-complie.xml file??

    Thanks in advance
    Ramu

    ReplyDelete