2

I have an APEX Class that needs some updates, that is on version 18. When I make the updates, the version is also updated to the most recent (v41). When I try to push to production I get errors saying there are 300 dependent classes that need recompilation.

With all of the said, I am not sure what is the best way to go about pushing the class changes. Is it possible to made code changes but keep the old version of the class? If not, what are the repercussions of recompiling all 300 classes?

I cannot look through each class and decipher if the recompilation will have a negative impact or not, that will be too time consuming. Overall, I am not sure how the updating of the version will effect the code which is causing hesitation on just recompiling the classes.

Has anyone dealt with something like this before? An extremely out of date production org?

  • 1
    You likely just have one root failure. Take a closer look at the failure messages and see if they point towards one originating failure. – Adrian Larson Feb 9 '18 at 14:25
  • Related: salesforce.stackexchange.com/questions/70387/… ... You're going to have to take the time to bump up your code one version at a time, fixing any errors that occur, until you catch up to the latest version. Making a change from 18.0 to 41.0 is inadvisable. – sfdcfox Feb 9 '18 at 14:45
  • @sfdcfox thanks for the advice, I am going to try and find another way. I don't want to risk anything crashing in production and don't have enough time right yet to bump everything one by one. – Olivia Feb 9 '18 at 16:22
1

Refresh a Developer sandbox or fullcopy sandbox from the Production instance, so that you will get production version of code. Perform a recompilation of necessary classes which will help you to analyze the impact and then perform the same steps on Production.

Also, if your organization has premier support agreement with Salesforce, then raise a ticket to Salesforce. Ask Salesforce to take the backup just in case if everything needs to rollback in case of failure.

By the way, this weekend Feb 9-10 Salesforce is rolling out Spring 18 release on rest of the instances, so better wait for this weekend.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.