5 steps tips for migration to salesforce using ANT migration tool

The Five Step Method of Deploying Salesforce Using ANT Migration Tool

Salesforce is the in-thing nowadays. Just about every business has Salesforce and those that do not have it yet are seeking ways to get it set up as soon as possible. This is because the benefits that it has to offer are just so many. Nevertheless, it can get a bit tricky if you do not get the guidance that you need to deploy various features or use the tools offered by Salesforce. The ANT migration tool is one of the finest tools from the company but then you will need several things in order to use it effortlessly.

deploying salesforce

What do you need?

It is possible to migrate schema, objects, codes and so much more from one organization to another very easily. There are several methods of doing this including the SalesforceChangesets, Eclipse or ANT. The ANT migration tool is Java based and therefore one of the necessities for Saleforce deployment using this tool is the Java Deployment Kit 1.5 or above. If you have the JDK then you proceed as follows:

Step 1:

Download ANT distribution. You can do so from http://ant.apache.org/bindownload.cgi.

Step 2:

Set Environment variable ‘ANT_HOME’ and make sure that the path is in the parent folder of ‘bin’. Ensure that you add the ‘bin’ folder to your path as well.

Step 3:

Check to see whether ANT has been installed properly or not by running command ‘ant –version’. It is possible that you will receive a message that reads something like this: ‘unable to find tools.jar’. You can copy this jar from ‘JDK_HOME/lib/tools.jar’, which you will move to the ‘JRE/lib’ folder.

Step 4:

The fourth step is to login to Salesforce and then navigate to ‘You Name| Setup| Develop| Tools’ and the download the force.com migration toolkit. Unzip the downloaded file to any directory of your choice and then copy the ‘ant-salesforce.jar’ file into the ant lib directory from the unzipped file.

To begin the deployment process using ANT you will need ‘build.xml’ as well as ‘build.properties’ files. Well, there really is no need of the later file but it is always good to have it to avoid confusion. The configuration related settings are going to be stored in this file, different from others settings. Both files can be copy from ‘sample’ folder of the unzipped content you get from Salesforce.

Step 5:

Copy all the folders with source code from the source organization by using eclipse. For instance if the root folder name is ‘test01’ you create a ‘build.properties’ field or copy it from the Salesforce unzipped folder. After this, create the ‘build.xml’ folder, which ANT needs. Finally go to the folder titled ‘test01’ from command line and then run command ‘ant deployCode’. This is the whole process.  If you want to check the status of the task, you can run the command: Ant targetName-Dsf.asynchRequestID=requested.

Patience is vital. The process can take a good amount of time to complete and if you skip some steps then you will definitely find yourself starting over. The time taken will depend on a variety of factors such as the speed of the internet connection.

Pin It on Pinterest