How a Sharepoint Sandbox Solution is saved

1.8k views Asked by At

I have been watching some Pluralsight training videos on SharePoint development.

One of the things I see is that you can make a sandbox solution or a Farm Solution.

From the training video, it says that the sandbox solution does not change the file system of the SharePoint Server at all. (While a Farm Solution is deployed to the GAC and saved in the SharePoint directories.)

So, my question is, if it is not stored on the file system how is it persisted? When I upload a SandBox solution and then reboot my SharePoint server, where is the sandbox solution loaded from if it is not on the file system anywhere?

I am guessing that the trainer made an oversight and that the sandbox solution is saved somewhere "safe". My question is, how does that work? If it is not saved, then how is it re-loaded after the SharePoint Server reboots? If it is saved, where is it saved?

2

There are 2 answers

0
Ryan On BEST ANSWER

When a sandboxed solution is deployed the assemblies are contained in the WSP package - which is persisted to the content database. The sandbox solution content is kept in the 'Solutions' table in the content database itself (see Definitions column).

They are only put into the UCCache when the assemblies are ran (such as a page load) and they are removed at some point afterwards.

See - Microsoft SharePoint Developer Documentation Team Blog > Where are Assemblies in Sandboxed Solutions Deployed?

0
Ashutosh Singh-MVP SharePoint On

When you deploy sandbox the assemblies it goes to UCCache. When you deploy farm they go to either the GAC or bin. the sandbox assembly is written to the disk at C:\ProgramData\Microsoft\SharePoint\UCCache on each server in the farm that runs the user code service.