{"id":12331,"date":"2016-08-01T13:36:00","date_gmt":"2016-08-01T13:36:00","guid":{"rendered":"https:\/\/viewmyprojects.com\/winwirewp\/?p=12331"},"modified":"2023-11-30T09:01:20","modified_gmt":"2023-11-30T09:01:20","slug":"sharepoint-code-analysis-framework-spcaf","status":"publish","type":"post","link":"https:\/\/viewmyprojects.com\/winwirewp\/blog\/sharepoint-code-analysis-framework-spcaf\/","title":{"rendered":"Introducing SharePoint Code Analysis Framework (SPCAF)"},"content":{"rendered":"\n<p><strong>SharePoint Code Analysis Framework (SPCAF)<\/strong><\/p>\n\n\n\n<p>Even the best developers can commit blunders; moreover, it\u2019s crucial if you are confident that your coding is flawless. This is no different when developing SharePoint apps. Of course, comprehensive development guidelines are a good way to start, but that also require manual verification and fixes. Wouldn\u2019t life be so much easier if this process could be automated?<\/p>\n\n\n\n<p>Visual Studio has partially responded to this requirement by creating tools which analyze code using code analysis tools. However, while pretty good for general development, Visual Studio doesn\u2019t emphasize on SharePoint specific development guidelines.<\/p>\n\n\n\n<p>To code better, SPCAF (SharePoint Code Analysis Framework) provides the most comprehensive code analysis suite for SharePoint.<\/p>\n\n\n\n<p class=\"blog-detail-list\">\u2022 SharePoint solutions (.WSP) for SharePoint 2010\/2013\/2016<br>\u2022 SharePoint apps for SharePoint 2013\/2016\/Online<\/p>\n\n\n\n<p><em>Program Analysis is the analysis of computer software that is performed without actually executing programs. In most cases, the analysis is performed on some version of the Source Code, and in the other cases, some form of the Object Code. The term is usually applied to the analysis performed by an Automated Tool.<br><\/em>-Wikipedia<\/p>\n\n\n\n<p>Do you trust the code in your SharePoint solutions and apps?<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"621\" height=\"339\" src=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/four.webp\" alt=\"\" class=\"wp-image-18768\" srcset=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/four.webp 621w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/four-300x164.webp 300w\" sizes=\"auto, (max-width: 621px) 100vw, 621px\" \/><\/figure><\/div>\n\n\n<p><strong>How to do Code Analysis for SharePoint?<\/strong><\/p>\n\n\n\n<p>SPCAF analyzes the code and answers the questions.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"698\" height=\"183\" src=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/five.webp\" alt=\"\" class=\"wp-image-18769\" srcset=\"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/five.webp 698w, https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/five-300x79.webp 300w\" sizes=\"auto, (max-width: 698px) 100vw, 698px\" \/><\/figure><\/div>\n\n\n<p class=\"blog-detail-list\"><strong>Features:<br><\/strong><br>\u2022 Analyzes WSPs and Apps<br>SPCAF can analyze code for all SharePoint versions which are using WSP packages or apps<br>\u2022 Visual Studio Integration<br>SPCAF is fully integrated into Visual Studio and can be easily started by the developer during the day-to-day development tasks<br>\u2022 Client Application<br>SPCAF provides a client application which can be used to analyze WSPs and Apps when Source Code is not available<br>\u2022 Reports &amp; Dashboards<br>A high-level view of the analysis results is provided in a dashboard in the SPCAF client application<br>\u2022 Configurable Rulesets<br>SPCAF comes with several built in rulesets which can be used directly or as a starting point for own rulesets<br>\u2022 Team Build Support<br>SPCAF can be integrated into the MS TFS Team Build which helps architects or QA managers to ensure that every SharePoint project is continuously analyzed.<\/p>\n\n\n\n<p><strong>Who can use SPCAF?<\/strong><\/p>\n\n\n\n<p class=\"blog-detail-list\"><strong>The Architect:<br><\/strong><br>\u2022 Ensure proper design of solutions<br>\u2022 Enforce coding guidelines and naming conventions<br>\u2022 Detect unwanted artifacts or development ways early<br>\u2022 Ensure that the solution is adhering to architecture<\/p>\n\n\n\n<p class=\"blog-detail-list\"><strong>The Developer<br><\/strong><br>\u2022 Find errors in code fast and early in development process<br>\u2022 Follow best practices and avoid common pitfalls<br>\u2022 Implement company guidelines, coding conventions and policies<\/p>\n\n\n\n<p class=\"blog-detail-list\"><strong>The Quality Manager<br><\/strong><br>\u2022 Ensure compliance of custom solutions to internal policies and standards<br>\u2022 Protect the environment from potential security issues<br>\u2022 Ensure quality standards in software development<br>The Administrator<br>\u2022 Protect the SharePoint environment from potential problems<br>\u2022 Ensure supportability and performance of the environment<br>\u2022 In case of problems find the causing SharePoint package faster and reliable<\/p>\n\n\n\n<p><strong>SPCAF \u2013 Benefits &amp; Limitations<br><\/strong><br><strong>Benefits<\/strong><\/p>\n\n\n\n<p class=\"blog-detail-list\">\u2022 Every member knows what happens in the project.<br>\u2022 Bugs are found faster.<br>\u2022 Optimization methods\/ tricks\/ productive programs spread faster.<br>\u2022 Programmer as a specialist \u201cevolve\u201d faster.<br>\u2022 Automatic implementation of best practices.<br>\u2022 Better structured code.<br>\u2022 Enforcing company\/industrial coding standards.<\/p>\n\n\n\n<p class=\"blog-detail-list\"><strong>Limitations<br><\/strong><br>\u2022 It\u2019s a desktop based application, results\/reports cannot be centralized or published in the tool.<br>\u2022 Require Server license to integrate with TFS.<\/p>\n\n\n\n<p>To sum up, this tool is a must have for all SharePoint projects if you are serious about the quality of your SharePoint code, at farm and app level, then you need to include this in your SDLC processes, at a developer level, during CI builds, and as a QA gate.<\/p>\n\n\n\n<p><strong>Here are a few things that we learned about SharePoint Framework code analysis:<\/strong><\/p>\n\n\n\n<p class=\"blog-detail-list\">\u2022 Cost: It\u2019s an Open Source.<br>\u2022 Domains: This tool can be used for various domains. WinWire has used SPCAF for BSFI, Retail, Manufacturing and Healthcare industry.<br>\u2022 Versions: SPCAF support for various SharePoint Versions (MOSS 2007, SharePoint 2010, SharePoint 2013, SharePoint 2016 and Office 365 \u2013 SharePoint Online (E1, E3 and E5))<br>\u2022 Deployment Options: Support for various solution deployment solution options -Farm Solution, Sandbox and App Model.<br>\u2022 Challenges: We have faced a few challenges in Third Party Components and Farm solutions \u2013 Crashing.<br>\u2022 Flexibility: We can detect quickly critical coding errors<br>\u2022 Analysis Report: Zero Error\/Bugs \u2013 We have shared code analysis report along with WSP files. Some customer will not consider .WSP file without SPCAF report.<br>\u2022 Less Configuration: We do not spend more time for framework configuration.<br>\u2022 Server: No Downtime \u2013 We used analysis framework during business hours. It\u2019s not really to use only onnon- business hours.<br>\u2022 Code Quality: Helps to ensure the code quality before delivery to the customer or deploying to Production Environment.<br>\u2022 Integration: Easily to Integrate with Visual Studio \u2013 There is not any version conflict or functions compatibility issue.<br>\u2022 Performance: We used for Performance Code Analysis- Most of the customer needs this report from each stages.<br>\u2022 File Format: We can create report in different file formats (,xlsx, pdf).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>SharePoint Code Analysis Framework (SPCAF) Even the best developers can commit blunders; moreover, it\u2019s crucial if you are confident that your coding is flawless. This is no different when developing SharePoint apps. Of course, comprehensive development guidelines are a good way to start, but that also require manual verification and fixes. Wouldn\u2019t life be so&hellip; <a class=\"more-link\" href=\"https:\/\/viewmyprojects.com\/winwirewp\/blog\/sharepoint-code-analysis-framework-spcaf\/\">Continue reading <span class=\"screen-reader-text\">Introducing SharePoint Code Analysis Framework (SPCAF)<\/span><\/a><\/p>\n","protected":false},"author":86,"featured_media":16740,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_eb_attr":"","_uag_custom_page_level_css":"","footnotes":""},"categories":[1,67,59],"tags":[],"class_list":["post-12331","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","category-digital-collaboration-blogs","category-blogs","entry"],"acf":[],"featured_image_src":"https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp","author_info":{"display_name":"Sudarsan","author_link":"https:\/\/viewmyprojects.com\/winwirewp\/author\/sudarsan\/"},"views":3810,"uagb_featured_image_src":{"full":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp",800,440,false],"thumbnail":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF-150x150.webp",150,150,true],"medium":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF-300x165.webp",300,165,true],"medium_large":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF-768x422.webp",750,412,true],"large":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp",750,413,false],"1536x1536":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp",800,440,false],"2048x2048":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp",800,440,false],"post-thumbnail":["https:\/\/viewmyprojects.com\/winwirewp\/wp-content\/uploads\/2023\/11\/SPCAF.webp",800,440,false]},"uagb_author_info":{"display_name":"Sudarsan","author_link":"https:\/\/viewmyprojects.com\/winwirewp\/author\/sudarsan\/"},"uagb_comment_info":0,"uagb_excerpt":"SharePoint Code Analysis Framework (SPCAF) Even the best developers can commit blunders; moreover, it\u2019s crucial if you are confident that your coding is flawless. This is no different when developing SharePoint apps. Of course, comprehensive development guidelines are a good way to start, but that also require manual verification and fixes. Wouldn\u2019t life be so&hellip;&hellip;","_links":{"self":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12331","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/users\/86"}],"replies":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/comments?post=12331"}],"version-history":[{"count":2,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12331\/revisions"}],"predecessor-version":[{"id":18798,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/posts\/12331\/revisions\/18798"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/media\/16740"}],"wp:attachment":[{"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/media?parent=12331"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/categories?post=12331"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/viewmyprojects.com\/winwirewp\/wp-json\/wp\/v2\/tags?post=12331"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}