In our development environments we need to re-deploy our codebase on a regular basis. We go through a deployment process where we do the following steps (all through PowerShell):

  1. Delete our old site collection where it was last deployed (if it exists).
  2. Create the site collection.
  3. For each solution:
    • Disable each feature in the solution (if it exists)
    • Uninstall the solution (if it exists)
    • Remove the solution (if it exists)
    • Add the solution
    • Install the solution
    • Enable each feature in the solution

One of our solutions contains all of the list schema.

We are seeing a problem where changes in our list schema (esp. changes in the view definitions) do not show up when we run the steps above. SharePoint "remembers" the old definition somehow.

We have tried IISESET, restarting services such as OWSTimer, the user code service, and we have even tried restarting SQL server as well as tried using a new content database.

The only solution that seems to work is to reboot the SharePoint server (our dev environment is just a single server) before running our deployment steps above. This works every time, but is a pain and we want to avoid it. In our load test environment I reboot the app server and all WFEs (I do not reboot the SQL server). This seems to work in this multi-server environment.

There is a cache somewhere. We believe it is on disk and not in memory since we have stopped all manner of background processes that could be holding onto the cache.

My research has found that there is a "CacheSchema" property for the ListTemplate. We do not set this and I haven't seen any good description on what this is - everyone just reiterates what is on the link I just provided:

Optional Boolean. TRUE to enable schema caching of the list when provisioning a site. The CacheSchema attribute is used, for example, in the global Onet.xml file to enable caching of the user list for the current site collection.

Does anyone know if this could help? Is the default value of this property "TRUE"?

How in the world do we clear this cache?

Note that our solution uses content types and site columns for every list/field we create and that we deploy all solutions as sandboxed solutions.

  • Something is not adding up. Sandbox solutions live in a site collection's solution gallery and would be deleted along with the site collection. Are you sure that (a)the list definitions are sandbox solutions, and (b) the site collection is really deleted during your redeployment process? Commented Jun 27, 2012 at 17:50
  • Also, keep in mind that when you update a schema, existing lists are not affected, only newly created lists. Existing lists will retain the schema it was created with. Commented Jun 27, 2012 at 17:53
  • Yes, I'm sure the list definitions are in a sandbox solution and I'm sure site collection is really deleted. And yes, something is not adding up :-S. We do not modify existing lists. We use a team site template, but I'm not concerned with any of the lists that are part of it. I am only concerned with the new lists that we add. Commented Jun 27, 2012 at 18:43

1 Answer 1


I think I have had this problem before and just doing an IISRESET, [Edit]Recycle of SP User Code Host Service[End edit] and restarting Visual Studio before the redeployment solved the issue for me.

I may be completely wrong but it seems Visual Studio maintains some kind of cache which holds the old schema.If I did not restart visual studio, I would get the old schemas. If I did restart VS, it seemed like the cache was cleared and I got my new schemas.

And yes, I was working with Sandbox Solutions too.

  • At first this sounded promising for us, but we have this problem in QA environments that do not have Visual Studio installed. However, it could be that we have not done a full IISRESET in these QA environments. We'll keep this option in mind and let you know how it works out next time we run into this (we are in code freeze at the moment so it may be a few days/weeks). Thanks for the suggestion. Commented Jul 2, 2012 at 13:23

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.