Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

Team System Web Access 2008 Sp1 exception - Unable to create workitemstore


Source: Microsoft Support

↑ Back to the top


RAPID PUBLISHING

RAPID PUBLISHING ARTICLES PROVIDE INFORMATION DIRECTLY FROM WITHIN THE MICROSOFT SUPPORT ORGANIZATION. THE INFORMATION CONTAINED HEREIN IS CREATED IN RESPONSE TO EMERGING OR UNIQUE TOPICS, OR IS INTENDED SUPPLEMENT OTHER KNOWLEDGE BASE INFORMATION.

↑ Back to the top


Symptom



In a complex Team Foundation Server 2008 environment where there are large number of users and huge Team Foundation Server Projects, the Team System Web Access 2008 (with Service Pack 1) may not be accessible intermittently.

You  see the following errors:


"Unable to create workitemstore see exceptions for more details."
"Work item editor state can not be found."

The Application event log on the Application Tier machine has the following warning:
==============
Event Type: Warning
Event Source: ASP.NET 2.0.50727.0
Event Category: Web Event
Event ID: 1309
Date: 2008-11-21
Time: 10:23:25
User: N/A
Computer: XXXXXX
Description:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 2008-11-21 10:23:25
Event time (UTC): 2008-11-21 08:23:25
Event ID: 657f24beb9c7499c9a06e7f1c662638c
Event sequence: 55269
Event occurrence: 4
Event detail code: 0

Application information:
Application domain: /LM/W3SVC/1444869424/Root-1-128689773173013532
Trust level: Full
Application Virtual Path: /
Application Path: C:\Program Files\Microsoft Visual Studio 2008 Team System Web Access\Web\
Machine name: XXXXXX

Process information:
Process ID: 3868
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE

Exception information:
Exception type: WorkItemStoreException
Exception message: Unable to create WorkItemStore see inner exception for details.

Request information:
Request URL: http://xxxx.abc.com:8090/index.aspx
Request path: /index.aspx
User host address: 10.191.29.109
User: abc\xxxx
Is authenticated: True
Authentication Type: Negotiate
Thread account name: NT AUTHORITY\NETWORK SERVICE

Thread information:
Thread ID: 9
Thread account name: NT AUTHORITY\NETWORK SERVICE
Is impersonating: False
Stack trace: at Microsoft.TeamFoundation.WebAccess.TfsConnection.get_Store()
at Microsoft.TeamFoundation.WebAccess.TfsConnection.GetProject(String projectName)
at Microsoft.TeamFoundation.WebAccess.TfsConnection.InitProject()
at Microsoft.TeamFoundation.WebAccess.TfsConnection.get_CurrentProject()
at Microsoft.TeamFoundation.WebAccess.TfsConnection.GetActiveTabs()
at Microsoft.TeamFoundation.WebAccess.UI.Controls.PageHeader.RenderTabs(String activeTab)
at Microsoft.TeamFoundation.WebAccess.UI.Masters.Content.RenderPage()
at Microsoft.TeamFoundation.WebAccess.UI.WebAccessPageMaster.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
==============

↑ Back to the top


Cause

This is a known issue with the product. The Team System Web Access 2008 + Sp1 that exists today does not scale up to the complexity of the projects and the environment.

↑ Back to the top


Resolution



To workaround the issue, try one of the following:


1)  Restart the "TSWAPool" AppPool in IIS Manager.


or


2) Clear the Team System Web Access cache which is by default located in the installation folder which is at %Microsoft Visual Studio 2008 Team System Web Access%\Cache\Tswa
A script also can be written to delete the cache in a timely manner using windows Task Scheduler located in Control Panel.

↑ Back to the top


More Information



Below is an SAMPLE script file to automate and run the commands in a timely manner. You may need to alter it for your our particular situtation.


 


' Below code is to check if the folder exisits
'---------------------------------
dim strfolderpath
Dim objAlert
Dim objEvent
Dim flag
flag=1


const EVENTLOG_WARNING = 2


strFolderPath = "C:\Program Files\Microsoft Visual Studio 2008 Team System Web Access\Cache\Tswa"

set objFSO = CreateObject("Scripting.FileSystemObject")


if Not objFSO.FolderExists(strFolderPath) then
flag =0


End if
'---------------------------------


 
if flag=1 then
'Code to stop App Pool  goes here
  strComputer = "."
Set objWMIService = GetObject _
    ("winmgmts:{authenticationLevel=pktPrivacy}\\" _
        & strComputer & "\root\microsoftiisv2")


Set colItems = objWMIService.ExecQuery _
    ("Select * From IIsApplicationPool Where Name = " & _
        "'W3SVC/AppPools/TSWAPool'")


For Each objItem in colItems
    objItem.Stop
Next


wscript.sleep 3000


objFSO.DeleteFolder(strFolderPath)
eventwriting (" The folder " & strFolderPath & " deleted!! ")  


'App Pool will be started  here


strComputer = "."
Set objWMIService = GetObject _
    ("winmgmts:{authenticationLevel=pktPrivacy}\\" _
        & strComputer & "\root\microsoftiisv2")


Set colItems = objWMIService.ExecQuery _
    ("Select * From IIsApplicationPool Where Name = " & _
        "'W3SVC/AppPools/TSWAPool'")


For Each objItem in colItems
    objItem.Start
Next
eventwriting (" App pool Started!! ")
Else 'writing to the event log
call eventwriting ("The folder " & strFolderPath & " does not exist!!")


end if


public sub eventwriting (StrMessage)
set objShell = CreateObject("WScript.Shell")
objShell.LogEvent EVENTLOG_Warning, strMessage
set objshell=Nothing
End sub


set objFso=Nothing

↑ Back to the top


DISCLAIMER

MICROSOFT AND/OR ITS SUPPLIERS MAKE NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY, RELIABILITY OR ACCURACY OF THE INFORMATION CONTAINED IN THE DOCUMENTS AND RELATED GRAPHICS PUBLISHED ON THIS WEBSITE (THE “MATERIALS”) FOR ANY PURPOSE. THE MATERIALS MAY INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS AND MAY BE REVISED AT ANY TIME WITHOUT NOTICE.


TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, MICROSOFT AND/OR ITS SUPPLIERS DISCLAIM AND EXCLUDE ALL REPRESENTATIONS, WARRANTIES, AND CONDITIONS WHETHER EXPRESS, IMPLIED OR STATUTORY, INCLUDING BUT NOT LIMITED TO REPRESENTATIONS, WARRANTIES, OR CONDITIONS OF TITLE, NON INFRINGEMENT, SATISFACTORY CONDITION OR QUALITY, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, WITH RESPECT TO THE MATERIALS.

↑ Back to the top


Keywords: kbnoloc, kbnomt, kbrapidpub, kb

↑ Back to the top

Article Info
Article ID : 968552
Revision : 1
Created on : 1/7/2017
Published on : 10/26/2011
Exists online : False
Views : 214