Wednesday, January 23, 2013

Deploy Apex class from Sandbox to Production

STEP BY STEP PROCESS TO DEPLOY FILES FROM SANDBOX TO PRODUCTION


Step1:
Go to the production environment
Step2:
 In the production environment go to Setup and navigate to App Setup –> Deploy –> Deployment Connections.
Step3:
Click Edit and check the box to allow Inbound connection from samplesand (my Sandbox instance) and click Save. This will allow changes from the Sandbox to be deployed to Production.

Step4:
From the Sandbox environment, click on App Setup –> Deploy –> Outbound Change Sets. An outbound change set is a set of changes you want to send from the currently logged in environment to another environment. E.g. Sandbox to Production. Click Continue if you see the “Understanding Deployments” page and then click “New.”
Step5:
 Give it a name such as ‘apexclassDeployment’ and click Save to go to the Change Set page for apexclassDeployment.
Step6:
 Under Change Set Components click Add.


Step7:
In the Component Type drop down select Apex Class, select both of the classes that were created and click “Add To Change Set.”

Step:8
Back on the properties page for the Change Set, click on Upload.


If all goes well, a message will let us know the change set was uploaded successfully. At this point we need to go to the Production environment and deploy the change set.

Step:10
 In the production environment go to Setup and navigate to App Setup –> Deploy –> Inbound Change Sets. The new change set will be listed under Change Sets Awaiting Deployment.

Step11:
Click the change set name and then click Deploy. Validate can be done before this, but we are going to assume it will work. If so you will should see the deployment with a status of succeeded.




1 comments: