270 likes | 427 Vues
Share the Vision. A Lap Around Microsoft TFS Proxy File Cache Server. Randy Pagels Team System Technical Specialist rpagels@microsoft.com Microsoft Corporation. What we will cover. Overview of Visual Studio Team System Overview of Team Foundation Proxy Fundamentals (200 level)
E N D
A Lap Around Microsoft TFS Proxy File Cache Server Randy Pagels Team System Technical Specialist rpagels@microsoft.com Microsoft Corporation
What we will cover • Overview of Visual Studio Team System • Overview of Team Foundation Proxy Fundamentals (200 level) • Information on Proxy Internals • Administering your Proxy • Proxy Best Practices
Visual Studio Team SystemExpanding Visual Studio across the Application Life Cycle Developer Database Professional Designer Architect Tester Business Analyst IT / ProjectManager Team Collaboration Software Quality Project Transparency
Dev Team (Remote) Dev Team (Local) Build Server Business User Win 2003 Server SQL Server 2005 IIS 6.0 Version Control Proxy (Remote) Active Directory HTTP / S TCP/IP Team Foundation Server Team System Architecture
TFS Clients Teamprise Explorer Teamprise Eclipse Plugin Teamprise Command Line Client Visual Studio Team Explorer Visual Studio Team Editions Teamprise On Linux Microsoft Command Line Client Team Foundation Server Teamprise On Sun / SPARC Teamprise On Mac Visual Studio 2003 / Visual Studio 6 Microsoft/ TFS Web Access
Proxy Overview Issue: • Downloading files to a user’s workspace is very common and bandwidth intensive operation • In a distributed development environment, team members might be in geographical locations with different bandwidth speeds Solution: • TFS Proxy – Improves download experience over low bandwidth/high latency networks
Supporting the EnterpriseDistributedDevelopment Designed for the Internet • Web-based protocols: HTTP & HTTPS • Optimized for high-latency, low-bandwidth scenarios Caching proxy • File content cached on LAN • Ideal for regional offices
TFS Version ControlDistributed Development Teams Copenhagen, Denmark6 Users Fargo, ND4 Users Redmond, WA368 Users Research Triangle, NC42 Users Hyderabad, India14 Users
Supporting the EnterpriseSource Control Proxy SOAP Messages File Transfers SOAP Messages File Transfers SOAP Messages File Transfers
Supporting the EnterpriseSource Control Proxy SOAP Messages File Uploads SOAP Messages Downloads File Uploads SOAP Messages File Uploads
Operations that use proxy • All VersionControl Operations that involves file download will go through proxy. Following are some examples: • Get • Unshelve • Compare (Diff) • Undo • View • Branch
Sample Proxy Performance Results • The above results are based on the following test environment • Client and Proxy deployed on the same LAN • Client and Proxy connect to AT over a 3Mbps connection
GetRequest Sample <GetRequest> <ItemSpecrecurse="OneLevel" item="C:\Samples\FillDisk\FillDisk\Program.cs" /> <VersionSpecxsi:type="LatestVersionSpec" /> </GetRequest> <GetResponsexmlns="http://schemas.microsoft.com/TeamFoundation/2005/ 06/VersionControl/ClientServices/02"> <GetResult> <ArrayOfGetOperation> <GetOperation type="File" itemid="7" slocal="C:\Samples\FillDisk\ FillDisk\Program.cs" tlocal="C:\Samples\FillDisk\FillDisk\Program.cs" titem="$/Oct272/FillDisk/FillDisk/Program.cs" sver="3" lver="3" durl="sfid=1025,0,0,0,0,0,0,0,0,0&ts=632662026304641152& s=W6d3sHjTjSLHiN2 HOOW01V621TbodRynH6kiBb2J2NQOaWd52;fid=1025"> <HashValue>jjvsK5awx+X0uA5h4489Lg==</HashValue> </GetOperation> </ArrayOfGetOperation> </GetResult> </GetResponse>
Download Ticket FileID’s (a group of FileID’s to optimize ticket generation) Expiry TimeStamp QueryString of FileID’s and expiry timestamp SHA1 hash of Query String Signed Hash String Base64 encoded signed hash string FileID
Proxy.Config • Servers • Supports multiple AT’s • CacheRoot • Where you want your data stored (default) • CacheLimitPolicy • PercentageBasePolicy • FixSizeBasePolicy • ReaderChunkSize • It states the size of the chunks downloaded from AT to Proxy • ApplicationTierReadTimeout • Indicates in ms the amount the Proxy will wait after the first packet is received • LastWriteTimeUpdateWindow • Default – 8hrs Min – 1hr Max – 24 hrs
Cache Cleanup • Cleanup policies • Fixed size limit • Percentage based limit CacheLimit = (AvailableSpace + CurrentCacheSize * CacheLimitPercent)/100 • Amount of space to free up can be configured, as a percentage of CurrentCacheSize • Files will be removed from the cache based on the LastWriteTime
Installation & Administration • Installation Steps • Follow Installation Guide! • Securing Team Foundation Proxy • Enable HTTPS if desired • Common Administration Tasks • Modify cache limit • Retrieve Proxy File Cache Statistics Information • Enable https for Proxy • Stop proxy from caching files from a TFS Server • Configure proxy to cache files for a new TFS Server • Modify Proxy Service Account Password
Proxy Statistics http://localhost:808:/VersionControlProxy/v1.0/ProxyStatistics.asmx
Proxy Best Practices • If large files are going to be downloaded over low bandwidth (< 3Mbps) network, then set executionTimeout to appropriate value in web.config(Default is 1hr - <httpRuntimeexecutionTimeout="3600"/>) • Don’t add an AT to Proxy.Config, if that AT is going to be used only for a short period of time instead directly download the files from AT • Disable the proxy on the clients if the proxy is going to be down for an extended period of time (attempted reconnections are executed every 5 minutes)
Proxy Best Practices • Follow hardware recommendations in TFS install guide • Specifically make sure you get a big disk drive • Create a scheduled task to pull the latest files on a periodic basis to proxy. • Ensures that latest version of files are available resulting in cache hit • Proxy can be used even in high bandwidth environments. • For instance if there are multiple teams using the same AT/DT and each team uses a separate Team Project then each such team can deploy a proxy. This will minimize (say CPU, Memory can be utilized for other tasks) the stress on AT/DT • Monitor Proxy Performance counters and event log (for errors/warnings) on a periodic basis, to get a good picture of how proxy is functioning
Session Summary • Overview of Visual Studio Team System • Overview of Team Foundation Proxy Fundamentals (200 level) • Information on Proxy Internals • Administering your Proxy • Proxy Best Practices
Additional Resources • Proxy Screencasts • http://go.microsoft.com/fwlink/?LinkId=62788 • Search and Post at MSDN Forums • http://forums.microsoft.com • http://forums.microsoft.com/MSDN/default.aspx?ForumGroupID=5&SiteID=1 • TFS Install Guide- • http://www.microsoft.com/downloads/details.aspx?familyid=e54bf6ff-026b-43a4-ade4-a690388f310e&displaylang=en • Visit the Team Foundation blog: • http://blogs.msdn.com/team_foundation • TFS site on MSDN • http://msdn.microsoft.com/vstudio/teamsystem/team/default.aspx • Participate and look at VSTS chats & webcasts • http://msdn.microsoft.com/teamsystem • Refer to the Team System FAQ • http://msdn.microsoft.com/vstudio/teamsystem/support/faqs/foundation_techfaq/
© 2005 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.