6 Replies Latest reply: Dec 3, 2012 2:50 AM by Anuj Dwivedi-Oracle RSS

    Deploy Agreements using ANT in B2B 11g

    916888
      Hi,



      kindly advice me where we can get Script files to deploy Agreements using ANT scripts.
      What are the steps we need to perform to deploy Agreements using ANT.
        • 1. Re: Deploy Agreements using ANT in B2B 11g
          user9285225
          Ant scripts are available in oracle b2b 11g. U would find all the ant scrips in the server. In my installation the files were present in following location ex: C:\Oracle\Middleware\Oracle_SOA1\bin

          To execute the command line utilites, following two prerequisites should be done
          1. To execute these command first set the environment variables;
          -ORACLE_HOME; ANT_HOME; JAVA_HOME
          or
          The environement variable can also be set by running the soaDomianEnv.cmd file.

          2. Create jndi.properties file.
          Browse to the ant files location in the server and run the following command
          ant -f ant-b2b-util.xml b2bcreate-prop
          This will create the jndi.properties. Edit file and include weblogic password ( password used to login to ur weblogic console)

          To deploy all agreements in repository follow the below command.
          ant -f ant-b2b-util.xml b2bdeploy

          To deploy specific agreement follow the below command

          ant -f ant-b2b-util.xml b2bdeploy -Dtpanames="OracleServices_001_Agr, MarketInc_001_Agr”

          For more information read the below tech note
          http://www.oracle.com/technetwork/middleware/b2b-integrations/learnmore/tnb2b11g005commandline-1648788.pdf
          • 2. Re: Deploy Agreements using ANT in B2B 11g
            916888
            1. To execute these command first set the environment variables; -


            In my case the environment variables are like this.

            ANT_HOME:

            C:\Oracle1\Middleware\modules\org.apache.ant_1.7.1


            ORACLE_HOME

            C:\Oracle1\Middleware

            JAVA_HOME

            C:\Oracle1\Middleware\jdk160_21


            2. Create jndi.properties file.
            Browse to the ant files location in the server and run the following command ant -f ant-b2b-util.xml b2bcreate-prop This will create the jndi.properties. Edit file and include weblogic password ( password used to login to ur weblogic console



            My Ant Files location is
            C:\Oracle1\Middleware\jdeveloper\bin

            Is this **ant-b2b-util.xml* location?


            to create jndi.properties file when i am trying to run below command

            C:\Oracle1\Middleware\jdeveloper\bin>ant -f ant-b2b-util.xml b2bcreate-prop


            i am getting below error

            error:
            'ant' is not recognized as an internal or external command,
            operable program or batch file.


            Please correct me where i am wrong

            Edited by: 913885 on Nov 29, 2012 3:54 AM
            • 3. Re: Deploy Agreements using ANT in B2B 11g
              user9285225
              My Ant Files location is
              C:\Oracle1\Middleware\jdeveloper\bin

              The above location seems to be your local JDeveloper location. This is not the location where u need to execute.
              You need to browse to the following location present in your SOA Suite server not in your local machine...

              ex C:\Oracle\Middleware\Oracle_SOA1\bin

              Hope you have understood. Let me know if you need further details
              • 4. Re: Deploy Agreements using ANT in B2B 11g
                916888
                The SOA is installed in some Remote location.could you please tell me how we can browse that path

                C:\Oracle\Middleware\Oracle_SOA1\bin>ant -f ant-b2b-util.xml b2bcreate-prop
                • 5. Re: Deploy Agreements using ANT in B2B 11g
                  user9285225
                  Note that these scripts should be executed in the machine where soa suite is installed.

                  If it is a linux/unix/solaris machine, u can use putty or any other tool to connect remotely.

                  Check with the soa admin in your team and he should be able to help u out.
                  • 6. Re: Deploy Agreements using ANT in B2B 11g
                    Anuj Dwivedi-Oracle
                    The SOA is installed in some Remote location.could you please tell me how we can browse that path
                    You may run these scripts remotely as well, provided you have a SOA installation at the machine from where you are running this script. So if you have SOA installation at your machine then just modify the value of "java.naming.provider.url" in jndi.properties to refer to the remote server and change the value of java.naming.security.principal and java.naming.security.credentials also accordingly. After this, you may execute all B2B commands, remotely as well.

                    Regards,
                    Anuj