Hi Team,
One more amazing troubleshooting day, And this is when one fine morning one of the developer in our team raised the FLAG that she is not able to export pages using "Export" button available in ribbon in experience editor and she was getting below exception in export wizard, and surprisingly in content editor, "Creative exchange" section and their export/import button were not showing at all.
"Export failed. There is no storage definition in the site"
We use azure virtual machines so she had the same copy as mine, and it was working fine on my machine, so my troubleshooting started, i was not expecting anything major out of it as i thought there must be something minor going on or some access issues as she was playing around with access to Sitecore items but it turned out something else and it took couple of hours to figure out what is going on, following are the steps which were performed to troubleshoot the issue.
Troubleshooting steps performed
1) First thing i checked was if there was no security changes that was done which was preventing the creative exchange not to work, but everything was fine there, user was admin and all roles were just fine no modifications there and no Sitecore item was given security policies
2) I overwrote BIN folder from recent back up and all configs too, just to avoid any possibilities of any recent config changes etc developer might have done in their local, but no luck, so first conclusion was that there is no config issues of any kind.
Surprisingly, If you search this error google was not giving any fruitful results to understand whats going on
3) So, next because SXA site gets resolved using host name, target host name and language settings defined in Site grouping, i made sure there are no issues there and correct settings are selected, but everything was just fine there.
4) There was no hints on the LOG, no error or exceptions.
5) I double checked Site Manager to make sure there is no site resolving issues while export but all looks fine there.
6) I did compare ShowConfig.aspx of my machine where everything is fine and that developer's machine's ShowConfig.aspx and everything looked same to same, all pipelines and flow was just there are evereything was fine set up wise, so second conclusion was there is no issue with SXA module set up as site and everything works just fine.
7) I even remapped the module of "Creative exchange site set up" in the site and re-installed it by right clicking site and installing module for site and selected "Creative exchange" but same behavior and no luck.
8) I observed the the error and it is not able to find the storage definitions, so i double checked that and all settings are fine under site like below
9) Now, Because our SXA solution is multi site solution and having multiple site, i tried to check export in another site and it was working just fine there, now i was 200% sure it is issue with some kind of settings on site level.
10) So i double checked all settings on site level and everything was same to same, and i compared site grouping of both the working and non working site, and with my surprise culprit was below settings
So when "Enable Preview" was false the in content editor it was not showing creative exchange EXPORT/IMPORT buttons too, and in
experience editor it was showing "Export failed. There is no storage definition in the site" message
and when you turn that FLAG to ON, everything worked fine, content editor started showing those ribbon buttons too and experience editor started working too, see below screen, in content editor the moment you click "enable preview", it started showing export and import buttons and also export in experience editor started working
Solution
If "Enable Preview" is OFF, export is not working so turn it ON, and export and import will work just fine and some how the radio button in "Export window" also started showing correct options of "Zip file" and "Folder on the server" both started showing too and export worked just fine.
Some further digging
After finding out the solution that it works with "Enable Preview" ON, i further tried to de-assemble the "Sitecore.XA.Feature.CreativeExchange.dll" and tried to find the root cause which are following findings, i am still working on to get the the exact conclusion but findings till now are following (Sharing, So that if anyone is interested in knowing and have any inputs to that)
There is a class called "ExportWizard.cs" in "Sitecore.XA.Feature.CreativeExchange.Wizards" namespace which is responsible to show the export wizard with all options
I will show you the implementation of this method in next screenshot from where the exception message us being shown, but if you closely see this method, it takes HOME ITEM, and that home items is coming from below code
this "GetSiteInfo" is under my radar and it seems, it is not getting the right context of the site and hence, Sitecore thinks that its not SXA site and not showing those creative exchange button and giving export exception, but i will have concrete findings in my next blog, but main method which gives export error is below in the code
Troubleshooting continues to find the root cause...
Comments
Post a Comment