function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Vinny Gebhart 10Vinny Gebhart 10 

Deploying code designed to be in managed package as unmanaged to a new org

Hi all,

Here's our back story:

We have an app that we developed (with a partner) to be a managed package deployment.  It's not meant for app exchange, simply a package we deploy for each of our clients when they come online with our service.  The partner who developed the org worked from one sandbox for their development, then bundled components as they were complete and moved to a "packaging" dev org where they created a managed package which we then install on client orgs.

Here's our current challenge:

That original org where the app was developed is no longer sufficient as we're expanding our dev team.  Our goal is to pull all of that code to a new fully licensed org so we can spin off developer sandboxes, refresh them as necessary, and streamline our deployment and development processes.  The issue is when we use the meta-data API to extract all code from the original org, we're unable to deploy it to a new org due to many dependencies and circular references between classes, objects, etc.  It seems Salesforce isn't able to handle "fixing" these dependencies on the fly.  We have tried scrubbing the XML package for any dependendent fields, classes, etc. which does limit the number of errors we get but we do still need to deploy all of the code at some point and at this point its incredibly manual and best described as "brute force".

Can anyone recommend a better / stronger practice for deploying a batch of metadata, code, classes, etc. to a new org in a way that will be successful?  Please note - the reason we're not deploying this as a managed pkg is so developers can work on the code / classes directly and test in place.  

Any help is greatly appreciated.

-Vinny  

 
Prateek Singh SengarPrateek Singh Sengar
Hi Vinny,
Did you tried using force.com Migration toolkit to migrate the complete code/configurations from your dev org into one of your sandbox. Now Doing this you will get some unwanted code and configurations but then you can remove them from your sandbox and create a clean copy. Alternatively you can use eclipse with force.com plugin to migrate your complete org into sandbox.


 
Vinny Gebhart 10Vinny Gebhart 10
Hi Prateek, we're currently using eclipse but we still get the same dependency errors.  We haven't tried the force.com Migration toolkit - will look into that to see if that offers any relief.
Prateek Singh SengarPrateek Singh Sengar
Hi Vinny,
Did you create a complete force.com project using eclipse? While creating a force.com project after you enter your credentials in the "Choose Initial Project Contents" window you should select "Select metadata components", click choose and then select all. This will create a complete project including metadata such as objects, project and code. You should then be able to select all and deploy to your sandbox.