2

Have created a Site Page Template and provisioned an instance into my Team Site's Wiki Library.

  <Module Name="CustomInFeature" Path="SitePageTemplates" List="119" Url="SitePages" >
    <File Path="Page.aspx" Url="Brian_Feature.aspx" Type="GhostableInLibrary" />
  </Module>

When I do this, it creates the file successfully whether I am in a Sandboxed or Farm solution. When I am in a Farm Solution, the SPFile.CustomizedPageStatus == Uncustomized. When I deploy via a Sandboxed Solution, the SPFile.CustomizedPageStatus == None.

Does this mean when I provision Site Page Templates in this manner, they are never ghosted, and as a result, always live in the Content Database? If I had lots of Site Collections (think a collaboration portal for a large organization), and each had it's own Site Page Templates deployed as a Sandboxed Solution, couldn't this potentially have a negative impact on the performance of my farm (as each page request, for a page created from this template, would need to pull the page definition from the Content Database, parse, and dynamically compile it)?

Putting this out there, but will try to confirm on my own using SQL Profiler and SQL Management Studio...

1 Answer 1

1

A sandbox by design is scoped inside of a site collection, and has no direct access to the GAC or the 14 hive (where the file would be ghosted).

Therefore the file will be stored in the site collection database.

The only performance hit would be the redundant files in multiple content DBs increasing disk usage but for these templates I don't see it being an issue.

1
  • Yeah, I get that. I was thinking maybe the User Code Service might cache it after first access or something.
    – Brian
    Jan 14, 2012 at 16:42

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.