11 Replies Latest reply: Feb 5, 2013 1:57 AM by Anuj Dwivedi-Oracle RSS

    OSB Deployment on remote box using ANT Script

    961903
      Is there any ANT script available, for carrying out the following activities using the Source SOA server (server1), Target SOA server (server 2) and deployment box (server3)
      1. Run the ANT script on deployment box (server3) to export OSB project from source SOA server (server1)
      2. Making URL and other environment related changes in the exported OSB project [server3]
      3. Run the ANT script on deployment box (server3) for deploying the exported OSB project to a target SOA server (server2)

      Thanks.
        • 1. Re: OSB Deployment on remote box using ANT Script
          Anuj Dwivedi-Oracle
          Please refer -

          http://biemond.blogspot.in/2010/07/osb-11g-ant-deployment-scripts.html
          2. Making URL and other environment related changes in the exported OSB project [server3]
          Please use customization file for this -

          http://docs.oracle.com/cd/E23943_01/admin.1111/e15867/customization.htm#CACJCAGD

          Regards,
          Anuj
          • 2. Re: OSB Deployment on remote box using ANT Script
            961903
            Thanks Anuj. The above blog was useful for performing the export and import of OSB project. Have hit into few issues with respect to customization file.

            1. The customization file created from the script has less content compared to the customization file created from the SB consoles (System Administration > Create Customization File). Can this be ignored ?
            2. My OSB is a simple proxy service having normal components like WSDL, Business Service and Proxy service. Manually edited the customization file, to replace hostname1 with host name2. Imported the process via ant script. From the SB console noticed that in Business Service part, hostname2 is being referenced. But under WSDL, i still see reference to Host name 1.

            Thanks
            • 3. Re: OSB Deployment on remote box using ANT Script
              961903
              Team, Any help here ? especially on point # 2 stated above.
              Thanks.
              • 4. Re: OSB Deployment on remote box using ANT Script
                vladodias
                under WSDL, i still see reference to Host name 1
                This will not be relevant and won't be used in runtime as you define the actual endpoint in the Business Service configuration...

                Hope this helps...

                Cheers,
                Vlad
                • 5. Re: OSB Deployment on remote box using ANT Script
                  961903
                  Vlad,
                  Thanks for your response and I do agree with your statement. But client is insisting to remove the reference to host name 1 from WSDL too. Is there any way to do this ?
                  • 6. Re: OSB Deployment on remote box using ANT Script
                    vladodias
                    958900 wrote:
                    Thanks for your response and I do agree with your statement. But client is insisting to remove the reference to host name 1 from WSDL too. Is there any way to do this ?
                    Well... You can always unpack the jar and do a string based replace in the file and pack it again before deployment...
                    • 7. Re: OSB Deployment on remote box using ANT Script
                      961903
                      One more question
                      While deploying OSB process using ANT script, can we specify the target folder in OSB, where the project needs to be deployed ? This requirement is similar to specifying the partition name under which BPEL process is deployed.

                      Thanks.
                      • 8. Re: OSB Deployment on remote box using ANT Script
                        961903
                        Any solution or around here.
                        Thanks
                        • 9. Re: OSB Deployment on remote box using ANT Script
                          Anuj Dwivedi-Oracle
                          1. The customization file created from the script has less content compared to the customization file created from the SB consoles (System Administration > Create Customization File). Can this be ignored ?
                          No, it can't be ignored. There should be some issue with the code generating the customization file. Can you post it here?
                          2. My OSB is a simple proxy service having normal components like WSDL, Business Service and Proxy service. Manually edited the customization file, to replace hostname1 with host name2. Imported the process via ant script. From the SB console noticed that in Business Service part, hostname2 is being referenced. But under WSDL, i still see reference to Host name 1.
                          OSB does not make any change in the business service WSDL. You may change the URL in the WSDL to a dummy URL, before uploading it in lower OSB environment. It should address the concern of having an actual URL in the WSDL.
                          While deploying OSB process using ANT script, can we specify the target folder in OSB, where the project needs to be deployed ?
                          There is nothing like partition in OSB. Each and every OSB project itself is a new folder.

                          Regards,
                          Anuj
                          • 10. Re: OSB Deployment on remote box using ANT Script
                            961903
                            Thanks Anuj for your response.

                            2. We have implemented search and replace feature of ANT, to replacing the URLS in the WSDL files.

                            3. Our requirement is that we need to organize the OSB projects under different folders, based on their functionality. Hence when we import the OSB project, some projects would go into the root folder (and this is working great) and there are few OSB projects when should get deployed under a specific folder. This is possible, if we create the OSB project from the SBconsole, but later, when we migrate from dev to test, we are not sure, how to achieve it. Still search, the best way to implement this.

                            Thanks once again.
                            • 11. Re: OSB Deployment on remote box using ANT Script
                              Anuj Dwivedi-Oracle
                              and there are few OSB projects when should get deployed under a specific folder.
                              Here you are making an incorrect assumption. All the projects will have a folder with their name and they cannot be deployed under any other project. However as part of the OSB project, you may add as many resources as you want under any folder. So what you are trying to do is to create a folder inside an existing project and create resources under it, which is valid as per OSB concepts.

                              To migrate resources selectively, instead of exporting the entire project, export the selected resources which you want to migrate. When you will import the exported archive then all the resources will be created under same project and in same location in target environment.

                              Regards,
                              Anuj