My implementation of Experience Manager 2013 - specifically Session Preview - is having trouble and I can't quite put my finger on why. Site Edit works just fine - I can hook into it from the pages that I've configured to be editable, make adjustments to the appropriate components, etc. After editing a component, the message "The preview for this page is not up to date" appears - as expected. The changes I made to the component are successfully committed to the CME, and a republish from within THAT system works just fine. However, if I try to update the preview inside XPM - or do any publishing from within that context - it fails without throwing an error. The page refreshes, but the "Preview out of date" message appears again and the component presentation has not been updated through a publish

After digging into the logs, there is an error present there:

ERROR SessionWrapperFactory - Exception while cleaning-up session data: Error while committing the transaction, Error while committing the transaction

Well, that's not particularly helpful (or maybe it is, just not to me - in which case awesome! Please explain :). To dig deeper, I turned the log threshold to DEBUG, and some more information fell out, immediately preceding the ERROR above:

DEBUG SqlExceptionHelper - The DELETE statement conflicted with the REFERENCE constraint "FK_VARIANTS_BINARY". The conflict occurred in database "Tridion_Experience_Manager", table "dbo.BINARYVARIANTS". [n/a] com.microsoft.sqlserver.jdbc.SQLServerException: The DELETE statement conflicted with the REFERENCE constraint "FK_VARIANTS_BINARY". The conflict occurred in database "Tridion_Experience_Manager", table "dbo.BINARYVARIANTS".

The stack trace is quite long and seems irrelevant although I can provide it if that would be helpful.

The debug log shows that the file was an image contained in the presentation that I edited (hence no doubt the BINARYVARIANTS table being involved in the complaint). Unfortunately at this point I'm kind of stumped - I can't figure out why session preview is having trouble publishing this binary file. The official documentation isn't much help here - it's very probable that I've misconfigured something, but I can't tell WHAT it is that I've misconfigured. Hopefully someone who has a better understanding of what Session Preview does internally will be able to take a look at this and see what the trouble is.

Additional information available on request - another problem I'm having is that I'm unsure what is and is not worth investigating as part of the troubleshooting process, so any guidance in that regard would be most helpful.


  • I've understood that the Exception while cleaning-up session data error will often appear in the log, something which couldn't be suppressed. But the error you see in debug is something you might want to report at Customer Support, seems like something is either not configured correctly or you stumbled upon a defect. Apr 22, 2013 at 11:02
  • 1
    When you press the "Update preview" button, what happens is that CM gathers-up the right changed data, submits it to the Session Preview WebService which saves it to the Session Database and then CM requests the updated page from the Staging site. You need to go on this thread and see where something goes wrong. Your first step: clean the Session DataBase and check that you have data in that DB after the "Update preview" button is clicked. If you do not have, repeat the test with DEBUG enabled on it. If you do have it, turn on DEBUG on Staging site. Apr 22, 2013 at 14:23
  • BTW: do you have problems only with Binaries? Or also with just modifying the text in a CP? Apr 22, 2013 at 14:25
  • 1
    When you're ready to test again, just set the DEBUG level for the Staging site and hit "Update preview". Check for stack-traces. Check for strange messages that look like warnings. Check for messages tell you if the session was identified. Check for messages that indicate something strange with Ambient Data Framework. Check for messages that indicate if the Page Metadata for the current request was found or not. Apr 22, 2013 at 15:36
  • 1
    The warning you're seeing seems to indicate that Ambient Data Framework is not correctly set-up for the Staging site. Can you confirm that you performed step 1 and 2 from David's answer? If yes, then it would be better if you were able to upload somewhere a DEBUG log file containing a request which failed Session Preview. Apr 26, 2013 at 10:01

2 Answers 2


From the follow-up discussion on your question it sounds to me like everything is working apart from the Ambient Data Framework of your actual web application.

I suspect you may have already tried these, but looking at previous answers around this topic suggests the following:

  1. Check that you do not have <Cartridge File="cd_ambient_cartridge_conf.xml"/> in your cd_ambient_conf.xml. This is just an example cartridge that should be removed/commented.

  2. Also check your web.config or web.xml files for configuration of the Ambient Data Framework. Compare them to the ones provided with the sample web apps in the Tridion installation media.

  3. Check that the Publication Path and Publication Url properties of your publication correspond to your actual environment.

  4. If you have upgraded your application from a previous version's Content Delivery, ensure that you have upgraded ALL the JARs to the newer version, not just those related to the Ambient Data Framework.

  • 1.) I can confirm that cd_ambient_cartridge_conf.xml is commented out in all of my cd_ambient_conf.xml files. The only included cartridge is cd_webservice_preview_cartridge.xml. 2.) There is a httpModule registration for the Tridion.ContentDelivery.AmbientData.dll in my Session Preview web service. Are there additional config requirements? The official docs don't make additional requirements apparent, I don't think... 3.) Confirmed - this location is being correctly populated by transaction data. 4.) This is a fresh install from the 2013 Installation media, thankfully. Apr 26, 2013 at 10:18
  • Can you try adding a httpModule registration for Tridion.ContentDelivery.AmbientData.dll to your web application? I suspect this might be the issue. See sdllivecontent.sdl.com/LiveContent/content/en-US/… Apr 26, 2013 at 11:10
  • Do you mean the staging website? I've done that; the error persists. Or did you mean the content manager editor? Apr 26, 2013 at 15:07
  • Correct, I meant the staging site. You don't need to do anything to the CME. Next step I suggest then is to read the documentation and watch the video at sdllivecontent.sdl.com/LiveContent/content/en-US/… to see if there's a step that you missed Apr 26, 2013 at 18:20
  • Having now watched the (actually quite useful) video and re-tracing my own steps, I can confirm that I have not missed anything. Apr 30, 2013 at 14:54

There's a lot of steps involved in Session Preview. Tackle them one-by-one and you will find the root cause.

  • Rendering of your template is executed in "Preview" mode. Try previewing your template and make sure your binaries are included as a result of this.
  • A POST is done to OData webservice. Go check the OData webservice logs for any error that may have occurred when pushing the binary. Is the binary too large? Is POST allowed? Any errors?
  • Is the Ambient Framework properly loaded in your staging site? Can you trace all the steps done when the page is refreshed and see the data coming from the session preview database?

I have put a more detailed step-by-step guide in this question.

  • Thanks, Nuno. When I've got some time to go through your guide step-by-step I shall. Apr 26, 2013 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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