How do you do mates? It’s a good fine day to talk about how to improve the development of creating Sitefinity Content Management System sites. But now there is a lot of talk about the performance improvements and checks for both development and production. Maybe some of the tricks and techniques may not work for people but can be taken into consideration while improving production or development. I would be very much appreciated in anyone let me know if there are others that are helpful.
First and the foremost thing to do is to update the latest version of Sitefinity. The application initialization and performance of the latest version is superior to the older one. It is wise to update to the latest one and rather to work on with the older version to get into the cycle of errors.
But the truth is that the Sitefinity Content Management System is built upon ASP.NET and some of the performance issues lie with ASP.NET rather than Sitefinity itself. But as everyone knows Sitefinity is a large application with over 120 binary files in the bin directory and 100’s of configuration setting that needs to be loaded whenever the application is started
Let’s see into some of the areas where we can improve for “Sitefinity Development”
System HardwareTo improve the development experience, it is recommended to have better and faster hardware. It is vital to make sure o run on an SSD drive, to have some fast memory modules, (DDR3/DDR4) and a top-line multi-core processor (Intel i7 processor).
Anti-VirusThere are few anti-virus programs that slow down the process of the development of an application. When a file is changed, added or removed, the anti-virus makes sure to scan it to check if it is a virus or not (It often happens and every developer knows it). It is best to remove Anti-Virus scanning on the local source control folder and the ASP.NET Temporary files folder.
Disable Inline EditingOften in the developing process, the programmer looks at the site as an admin account. If there is inline editing enabled, then the resources required for this need to load. Go to Setting--> Advanced--> Pages--> Enable in-line editing and set it to false.
Global.ascxWhen a global.ascx is being added to a project, often the default method is also left empty even though it is not being used. When an application runs, IIS checks if these methods exist and if they do then it is added to the processing pipeline and which results in another extra process in the processing. There is another issue that an empty method can throw an application error when dealing with CDN resources. So it is for the best to remove it or if possible combine functions to reduce the extra method loading.
Also consider using Request Start and End Methods which fire for every request, including a request for images and static files. It will also save a lot of pointless processing if these codes are to be moved to a better place.
Remove Unused Config and Sitefinity ModulesSitefinity Content Management System does a great job of providing a list of modules that can be removed. But, if a site which was created on an earlier version of Sitefinity then things may have changed. It is compulsory to check the current web.config modules and other settings against the web.config generated by a new installation of Sitefinity to ensure not to load any obsolete modules. If the Sharepoint or Marketo integrators are not in use, then uninstall them from the site. Have a look into the other modules which are not in use and remove them. This will help improve startup times.
Filter Queries by View PermissionThe default setting was true at the first release of Sitefinity. But the downside to this is that it caused a lot of performance problems. The need to check all permission was too heavy and was turned off. If an older version of Sitefinity is used, then it should be disabled.
runAllManagedModulesForAllRequestsIn the web.config file, we can find the attribute runAllManagedModulesForAllRequests o the element. It shouldn’t change it as a lot non ASP.NET needs to run through these modules. But if we have all file-based static resources in a particular folder then we can add a web.config file to this folder and set it to false. This will save us from a lot of overhead.
And Just for CompletenessMake sure of debug="true" is only present in development. Never set it to true in production.
Don't build excess projectsIf you’re in the middle of development you probably do not need to be compiling excess projects that have little to do with what you are working on. Use the Configuration Manager and create different build profiles to help speed up the build time by avoiding projects that are not currently being required.
Remove Extra View Engine Look-upsBy default, the Web Form and Razor Views Engines are loaded and 28 locations are searched. You can reduce this lookup by removing the WebForms View Engine and the .vbhtml file lookups.
Feather DevelopmentIf there is the use of a class library for Feather widgets, a programmer can also embed their Views there too. But this means recompiling and restarting the application every time to make an HTML syntax change. To help speed up the process, place the Views in the Resource Packages folder first.
Dynamic Compression Before CacheBy default, Sitefinity has this attribute on the element set to false. But setting it to true is considered a better approach.
But why is it set to false to start with? Setting it to true can cause errors when the response is modified on its return. The ASP.NET Web Forms Cache Substitution causes such an error. The Sitefinity (Web Forms) Login Status widget uses cache substitution and will throw an error if this attribute is set to true. If you are not using this widget and not using Cache Substitution in your code, then set this value to true for better performance.
Application ErrorsAny errors thrown in an application are resource-heavy, blocking events. They cause performance issues. There will always be some errors thrown but make sure to ensure there is nothing in the application. If there are, investigate and fix them. If it is not the code but Sitefinity's, then log a fault.
Response.Redirect()A common practice for developers is to use the Response. Redirect method to push requests to other pages and there is nothing wrong with that. But the most common approach is to use Response.Redirect(URL). The issue here is that this causes the page life cycle to abort its thread and this causes an application error. It's all hidden and handled by ASP.NET but there is a better, safer, cleaner and more performant option.
With this code, we are allowing the page life cycle and the thread to complete and end in a safe manner, without throwing a hidden application error.
Cache profilesIn each cache profile, there are three Boolean options. Two of them, Vary by User Agent and Vary by Host both determine if a different version of the page should be cached for different browser versions and host headers. The user agent string is often changed depending on the operating system it is on so it can almost get a one user, one cached page scenario. Not very efficient.
The third is Wait for page Output cache to fill. What happens here is that if a page is accessed by 10 requests at the same time and there is no cached version of the page then the first request will process the page and put it in the cache while the other nine requests wait until they can access it from the cache. The alternative is that all 10 requests run and process the page causing more resource overhead (it’s a better option).
Reindex Your DatabaseThe database can become fragmented over time and this will slow overall performance. Look to rebuild the indexes on a regular basis.
Performance Tips from SitefinityYou should ensure you have read the suggestions from Sitefinity.
SVG Images SVG files are effectively a mark-up language and the advantage of it is that they scale, unlike traditional images. Really good for icon files.
Site WarmupSite Warmup module effectively looks at all the pages and goes through rendering and placing them in the output cache. No need for that first user request. By default, it is off, just needs to be enabled.
Why Doesn't Sitefinity Content Management System do all this Stuff by Default?It would be great if the Sitefinity team just implemented all these improvements but the issue for them will always come down to backward compatibility. The last thing they want is for people to update their site with the latest release and it doesn’t work because people have coded against a previous implementation. This will only generate a lot of support tickets and grumpy posts. It has often happened with the older Sitefinity projects. So, it is best to re-code and take advantage of the Sitefinity’s features.
What programmers would like to see more of from the Sitefinity team these days is a table of features and functionality that is due to be decommissioned. The less old technology that Sitefinity has to support and test the faster they can then push out improvements.
A small suggestion to Company owners that they must encourage themselves to have a budget for maintenance which includes upgrades for both Sitefinity releases and code.
We have some of the best Sitefinity developers in India, if you need more information on Sitefinity CMS Development or performance improvement initiatives on existing Sitefinity portals, do reach out to us on – email@example.com
What Oditek offers
Refer our Skills page:
We had a tough deadline to launch our .Net based application that processes a lot of data, and got very frustrated with our development agency we hired. Fortunately we got Oditek, and they took over seamlessly the product development, launched the app & continued feature development. Just awesome!
They were very attentive to our needs as clients and went out of the way to make sure our projects were taken care of. They were always able to get projects done in the specifications we requested. They are passionate about getting things done; I would definitely recommend them to lead any IT projects.
OdiTek has been very impressive in delivering a C++ based network security product migration from Linux to Windows. Honestly, we didn’t expect the speed and competencies to get the migration project delivered absolutely on time as the existing product was complex. Technically team is very experienced.
I worked with OdiTek on few high profile banking application projects. They did a fantastic job with web applications & manual testing on the VAS apps for two leading banks of UK that included rigorous UAT phases. I recommend them for any application development where security matters.
OdiTek is our extended team who works on our key software projects. They are dependable, good in collaboration and technically very much to the level what we expect a global team should be. They had transformed our web applications, CRM and added mobility to existing business platforms here.
It's been more than 4 years now that we are working with OdiTek on our cloud based web product development. It's been amazing working together, they are very competent on designing scalable, high performance apps. Their technical support is outstanding to say the least, even at odd hours.
I am a fan of Team OdiTek since 2014 and have worked on many product development projects together. Specially worth mentioning their deliveries on VAS Banking web application development & manual testing services for Smarta, UK. They are highly skilled & a professional team to work with.
OdiTek has been working on our Integrated Web-scale Mobile Platform i.e. Optimal Health since 2014. They are very professional and takes care of the requirements meticulously. They are technically very sound and sincere in ensuring quality & performance. Wonderful working with them!
You can trust the team, with minimum supervision you get the work done. They are honest, professional & committed to schedule & quality. I had been successfully running 3 business applications designed, developed and maintained by Oditek developers. It’s been a pleasure working with them.
OdiTek has been working in custom software development, including services for test automation. Many of them have worked with me in 2009-10 when I was R&D Manager in NetHawk India. They have great enthusiasm & a passion to excel in bringing customer success. Their work has been very impressive.
It's amazing to see these guys are turning their experience into a global delivery excellence at OdiTek. I am sure their past large scale product development experience will be handy to product companies. I would always recommend Oditek for software development, especially performance-driven solutions.