optimizing public facing sharepoint sites
DESCRIPTION
Session about how to optimize public-facing sites built on SharePoint publishing infrastructure. Session is based on real-life experiences and provides valuable information to all SharePoint developers who build sites using SharePoint publishing infrastructure. It was special session for SPUG.fi community meeting.TRANSCRIPT
![Page 1: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/1.jpg)
Optimizing public facing SharePoint sites
Gunnar PeipmanIIS/ASP.NET MVP
http://weblogs.asp.net/gunnarpeipman/[email protected]
![Page 2: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/2.jpg)
About me
Name: Gunnar PeipmanFrom: Tallinn, EstoniaMVP: ASP.NET MVP for 4 yearsJob: developer, architect and
consultantCommunity: ENETA, speaker,
bloggerHobbies: new technology,
heavy metal, beers, national cuisines, travelling
Happy boyfriend, father, step father and owner of funny white rabbit
![Page 3: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/3.jpg)
Agenda
Characteristics of public facing sitesWhy SharePoint Publishing Infrastructure?Caching filesOutput cacheUsing CDN-s
![Page 4: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/4.jpg)
Session objectives
After this session you should understand:performance problems of public facing
siteshow caching works in SharePointhow to plan and configure cachinghow to measure cache
![Page 5: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/5.jpg)
Characteristics
Accessible by anonymous usersHarder to estimate server loadMostly one-way communication
(this is what MS thinks)Different needs (design, SEO)Different publishing process
![Page 6: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/6.jpg)
SharePoint Publishing Infrastructure
Targeted to public web sites and corporate in-house portals
Perfect fit for corporate information publishing
Publishing workflowsDifferent optimization options
![Page 7: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/7.jpg)
Caching files
![Page 8: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/8.jpg)
Request to page
Every file referencemeans new request
Most files are kept inSharePoint libraries
Professional designmeans hundreds offiles
Plus dynamically loaded files
![Page 9: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/9.jpg)
Same time in server...
![Page 10: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/10.jpg)
What is BLOB cache?
Files from doc libraries are cached to front-end servers
Perfect fit if per page load many requests are made to server
Perfect fit also for large filesSupport for e-tagsYou save:
◦Some database connections and queries◦Loading files to database server memory◦Moving files from db server to web server◦Some traffic
![Page 11: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/11.jpg)
How to optimize
Keep blobs on separate physical diskEvery front-end server must have its own
blobs folder or diskIf disk crashes or you delete files from
blob cache you must reset blob cacheBlob cache may slow down your site for a
moment when files are copied to diskWhen measuring start from second
request
![Page 12: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/12.jpg)
Output cache
![Page 13: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/13.jpg)
Caching pages
Built on ASP.NET cachingOutput cache is served from memoryPossible to define cache profilesProfiles can be assigned to page layoutsCode-based policiesPossible to define non-cached areas
(called also donut hole caching)
![Page 14: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/14.jpg)
Don’t over-cache!
Again: Output cache uses server memory!
Morning:
Noon:
Afternoon:
Evening:
![Page 15: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/15.jpg)
How to measure cache?
Use ASP.NET and SharePoint performance counters
Make sure counters are not updated too often – it puts markable load on server
Measuring must be long enough to see how cache is actually used
No app-pool recycle or iisresetIf ~85% of requests are served from
cache you are okay
![Page 16: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/16.jpg)
Output cacheData from real-life scenario
![Page 17: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/17.jpg)
About measuring process
Performance counters on productionInterval 15 secondsCounters:
◦Total number of objects added◦Total object discards◦Cache hit count◦Cache hit ratio
Duration: 12h (work hours fully covered)No interruptions
![Page 18: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/18.jpg)
Results
![Page 19: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/19.jpg)
Content Delivery Networks (CDN)
![Page 20: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/20.jpg)
CDN servers
![Page 21: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/21.jpg)
Using CDN-s
Files are hosted on other serversUsers get files from closest serversMany popular JS libs are available in
Google and MS CDN serversYou can build your own CDN using
Windows Azure servicesPoint of trouble: wider internet outage
![Page 22: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/22.jpg)
Q&A
![Page 23: Optimizing public facing SharePoint sites](https://reader037.vdocuments.mx/reader037/viewer/2022110302/54922cdeb47959f2248b586f/html5/thumbnails/23.jpg)
Thank you!