16

I received this error message yesterday in the Developer Console, preventing me from saving any new code (Apex, Visualforce) for the past 24 hours.

FIELD_INTEGRITY_EXCEPTION

Failed to create deployment: This container has a save in progress with deploymentId=1drS00000004vRv. You may not enqueue a request until this completes.: Metadata Container ID

enter image description here

How can I fix this to have the possibility to save back again to my Salesforce instance?

4
  • I've been getting this a lot. I save a copy of my unsaved work to a text Editor (Notepad ++ or Sublime Text 3), and then I close out the Developer's Console and restart it. It seems that something in my code rubs SFDC the wrong way :/ @jpmonette's answer looks good though :) Commented Nov 15, 2013 at 16:44
  • @amatorVitae Happy to know that it might help you. We seem to have a similar development process (with Sublime Text). I started having this issue since Winter 13 I think, never had that before. It should fix most deploymentID issues.
    – jpmonette
    Commented Nov 15, 2013 at 16:46
  • Not a duplicate, but this question should be linked.
    – Adrian Larson
    Commented Dec 10, 2015 at 22:57
  • Years later and I'm hitting this. I'm unable to reach the https://[INS].salesforce.com/[PUT-DEPLOYMENT-ID] page. It says the page does not exist. I'm having to make all my edits in the Salesforce > Quick Find > Apex Class editor, and open it in the Developer Console to test any changes. This is exteremely cumbersome. Commented Jan 22 at 21:06

2 Answers 2

20

Copy the Deployment ID in your clipboard, and head to:

https://[INS].salesforce.com/[PUT-DEPLOYMENT-ID]

Click on the Delete button to delete the deployment record, and everything should be back to normal.

5
  • 2
    I've deleted the deployment record multiple times, but each time I do and attempt to resave my apex class, I get the error again with a new deployment record ID. What can I do?
    – smohyee
    Commented Mar 25, 2014 at 16:47
  • After pressing delete on the link above, Close the file you were trying to edit in the dev console, then close the dev console. Then try going to Setup -> Develop -> Edit on your class. Press save in the Edit screen. Re-open your dev console and try to save it again.
    – anataliocs
    Commented Aug 27, 2014 at 18:33
  • 3
    You can also right click on the tab and click "Cancel Save"
    – Thomas
    Commented Sep 30, 2014 at 15:58
  • 1
    Life and sanity saver!
    – sberley
    Commented Mar 17, 2015 at 3:51
  • 3
    Not working with a lightning org :/ arriving on "URL No Longer Exists" even if switch back to SFDC classic mode Commented Feb 18, 2017 at 23:38
16

As an alternative, you can click on the Progress panel in the developer console and click "Cancel All Deployments."

What is going on?


Apex and VF are interesting because they need to be compiled to ensure the saved state of the org is valid. Before, the only way to do this was a deploy in the Metadata API, which requires a ZIP file and a lot more time.

In the Tooling API, a new concept of a Container and Container Members were introduced. Now, these containers can be saved to the org even if they aren't valid. When the user is ready, a Container Deploy Reqeuest is created to deploy that container and all it's members (No more zip file!). This, in general, makes for a much faster save and smaller payloads (instead of one large payload).

The Dev Console has already (mostly) moved over to the Tooling API, and all tools should be moving over eventually. I think Mavens Mate and Brain Engine have already started to use the Tooling API, which is why you may see that error on there too.

There is a restriction where you can't create a deploy request on an entity that is already being deployed (isCheckOnly=false). This helps prevent multiple people from deploying the same object, and overwriting changes. Although, in your case, the developer console most likely got in a weird state where it doesn't think the entity you're trying to save has a member, so it tries to create a new one and deploys that when there is already one on the server. We are constantly trying to make the console more robust to prevent the state from getting out of whack and causing errors like that.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .