SlideShare a Scribd company logo
TRANSITIONING TO SHAREPOINT APP DEVELOPMENT 
Simon Rennocks 
Principal Consultant 
Microsoft Certified Master -SharePoint 
ProSourceSolutions LLC
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
SPEAKER BACKGROUND 
Expertise 
Principal Consultant 
Microsoft Certified Master -SharePoint 
ProSourceSolutions LLC 
18+ Years of Experience 
Email 
srennocks@prosource-corp.com 
Blog 
rennocks.wordpress.com 
Twitter 
@simonrennocks
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
SESSION GOALS 
•Understand why apps will replace full trust code 
•Know how to create an on premise development environment for building apps 
•Be able to create SharePoint apps on premise and in Office 365 
•Know how to publish apps both on premise and to Office 365 
•Follow the best practices for developing updates for apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
AGENDA 
Building Apps 
App Publishing 
Updating Apps 
Moving From Full Trust Code 
Getting Started with Apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
MOVING FROM FULL TRUST CODE
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CODE DIFFERENCES 
Full Trust 
Feature Receivers 
Web Parts 
Application Pages 
Server-Side Code 
Apps 
App Event Receiver 
App Parts 
App Pages 
Remote Server-side Code
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
OPERATIONAL COMPARSION 
Full Trust 
User Only Security 
Elevated Permissions 
Apps 
User & App Security 
Use “App Only” 
Break Inheritance 
Request Permissions 
No Resource Monitoring 
Resource Monitoring
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEPLOYMENT CHANGES 
Full Trust 
To Farm 
Files in Hive 
Assemblies in GAC 
WSP Deployment 
Apps 
To Site Collection 
Everything in Content DB 
Assemblies Remote 
.App Publishing
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
What challenges do full trust solutions pose?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WEB PART REFACTORING 
Use client side code 
Separate out SharePoint code 
Use REST endpoints
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
2010 CHALLENGES 
Server-side Code 
Full Permissions 
Not following Best Practices 
Performance and Errors 
Unhandled Errors & Crashes 
Slow Sites 
Development Cycle 
Long approval times 
Cross Solution Testing
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CROSS PLATFORM DEVELOPMENT 
•Languages and technologies 
•Lower entry bar 
•MVC and MVVP support 
•Expanded object model
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
How are apps different?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
EVOLUTION OF OBJECT MODEL 
SharePoint 2010 
2007 
SharePoint 2013
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WHY APPS SHOULD BE USED 
•Familiar programming model 
•Multiple hosting options 
•Flexible web experience 
•Integrates with Office apps 
•App available to users via 
–Office Store 
–App Catalog
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WHEN TO USE APPS 
•Using SharePoint in Office 365 
–Apps required 
•If On-Premise 
–Meets business requirements 
•In the Cloud and On-Premise 
–Best to use apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WHAT HAVE WE COVERED? 
Comparison 
Full Trust Challenges 
How Apps Can Help
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
GETTING STARTED WITH APPS
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WHAT ARE APPS 
•Lightweight web applications 
–Apps parts hosted in IFrame 
•Web scoped 
–Own isolated app web 
•Tenant “shared” scoped 
–Shared app web across multiple site collections 
•Different authentication options 
–Azure ACS for low trust –on premise or O365 
–Digital certificates for high trust –on premise only
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
TYPES OF APP 
Immersive Full Page 
App Part 
UI Custom Action 
NOT TENANT SCOPED
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
App Web 
SHAREPOINT-HOSTED APP 
1.Isolated app web 
2.SharePoint Access 
3.Cross-domain library 
4.Tenant scope access 
Host Web 
1 
3 
JSOM 
2 
Other Site Collections 
4 
JSOM REST 
REST
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
PROVIDER-HOSTED APP 
1.Client-side object model 
2.App Web optional 
3.Provide tenant isolation 
4.Tenet Scope access 
App Web 
Host Web 
Remote Web 
1 
2 
3 
Other Site Collections 
1 
4 
3 
2 
REST 
SCOM, 
REST, JSOM
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
What’s needed before we can create apps?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP PREREQUISITES 
On Premise 
Office 365
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
ON PREMISE SETUP 
Create Development Farm 
Provision Services 
User Profile 
App Management 
Subscription Service 
Create Isolated Domain 
Configure Settings 
App Domain 
App Prefix
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CREATING CERTIFICATES 
•Create self-signed cert 
•Create folder for certs 
•Export certs to folder 
•Give app pools access 
•Register .cerwith SP 
•Project uses .pfxcert 
•App uses .cercert 
IIS 
Project 
App 
Register Cert 
.cer 
pfx 
Folder
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEVELOPER TOOLS 
•Office 365 developer subscription 
–Or use a site with developer template 
–Develop using “Napa” 
•Visual Studio 
–Professional or higher 
–2012 or 2013 plus latest updates 
•Extensions required 
–Microsoft Office Developer Tools 
–NuGetPackage installer
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP INFRASTRUCTURE OVERVIEW 
Where 
Stage 
Requirement 
SharePointHosted 
Provider Hosted 
Setup 
Provision app farmservices 
 
 
CreateIsolatedapp domain 
 
Optional 
Createcertificates & configure trust 
HighTrust 
Configureaccess to Azure AD ACS 
Low Trust 
Setup 
Development sitecollection 
 
 
VisualStudio 2012 or 2013 
 
 
Create Appcatalog 
 

ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Lets look at how to do this
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEMO 
•Configuring a developer farm to support apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
WHAT HAVE WE LEARNED? 
What are Apps 
App Prerequisites 
On Premise Setup
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
BUILDING APPS
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP PROJECT SETUP 
•SharePoint location 
•Specify hosting model
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
PROVIDER-HOSTED OPTIONS 
•Choose web app type 
•Choose authentication
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
SharePoint-Hosted 
Provider-Hosted 
APP PROJECT STRUCTURE
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CLIENT WEB PART 
Properties passed in query string 
Properties Defined in here 
Reference to web page 
Default app part dimensions
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
JSOM PATTERN 
•Get SharePoint context using app web url 
•Define objects to get 
•Execute to get objects 
•Result sent to asyncevent
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CSOM PATTERN 
•Pass in HttpContextto return SP context 
•Create user context from the SP context 
•Determine what we need 
•Group as much in each Load as possible 
•Execute to get the data 
•Use the data returned
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CROSS DOMAIN 
•Get the app web and host web url’s 
•Load the cross domain library from the host web 
•Specify callback event to access host web objects
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CROSS DOMAIN 
•Get the app web context 
•AppContextSiteused to access host web 
•Specify permissions need in AppManifest
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
HOST WEB PERMISSIONS 
<AppPermissionRequests> 
<AppPermissionRequest 
Scope="http://sharepoint/content/sitecollection/web" 
Right="Manage" 
/> 
</AppPermissionRequests> 
AllowAppOnlyPolicy="true">
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
How do we deploy app components?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP COMPONENTS 
•Type of app assets 
–SharePoint lists, document libraries 
–Images, cssand javascriptfiles 
•Deploy from app 
–When app first accessed 
–Required host web manage rights 
•Deploy using app event receiver 
–Receiver added to remote web 
–Use azure web sites
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
ASSET DEPLOYMENT 
• To app web 
– If isolation required 
– Need to sell app 
• To host web 
– Easier user access 
– Shared app access
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP EVENT RECEIVERS 
•From app project 
–Enable property pane 
–Service endpoint added to AppManifest 
•In web project 
–Receiver service code class 
•Debugging possible 
–Requires azure service bus reference
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Lets create some Apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEMO 
•Create a Provider-hosted app 
–Office 365 
–App event receiver for components 
Alt
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
THE APP BUILT AND PUBLISHED 
Creating an App 
App Components 
Demo App
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP PUBLISHING
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP REGISTRATION –HIGH TRUST 
•Provider-hosted apps 
–Use AppRegNew.aspx 
Sameas Client Id 
Hosting url 
Required only for apps launched from outside of SharePoint 
Not used in high trust apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
HIGH TRUST SETUP 
•Create web site 
–In web.configadd
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
How do we publish low trust apps?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP REGISTRATION –LOW TRUST 
•Provider-hosted apps 
–Use AppRegNew.aspx 
Same as Client Id 
Hosting url 
Required only for apps launched from outside of SharePoint 
Same as Client Secret
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
AZURE WEB SITES 
Add client Id & secret to app settings 
Download Publishing Profile 
Create web site
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
APP DEPLOYMENT –LOW TRUST 
App project 
Client Id and secret 
Publish app 
Add to app catalog 
Web project 
Add publishing profile 
Publish web to azure
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Lets publish our App
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEMO 
•Publish a low trust app to Office 365
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
THE APP IS PUBLISHED 
High Trust Apps 
Low Trust O365 Apps 
Publishing Demo
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
UPDATING APPS
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
UPDATE BETTER THAN REPLACING 
Update due to 
•Required for store apps 
•Data preserved 
Replace will not work 
•No control on what users do with App
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
KEY POINTS 
•Users may not update app 
–One app version 
–Same version after update 
–Update logic relies on version number 
•Rolls back on error 
–All components 
–App data not lost 
–Mostly automatic except for custom logic 
–Errors reported to UI
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
EDGE CASE RISKS 
•Installing too little 
–User using version 1 of app 
–Missed going to version 2 
–Updates to version 3 
–Update logic fails to add version 2 list 
–App fails on displaying version 2 list 
•Installing too much 
–User updates from version 2 to 3 
–Update logic tries to re-add version 2 list 
–Update fails due to existing list
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
How should we update Apps?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Previous updates in version range 
Current update 
<EndRange= 2.0.0.0> 
1.000 -1.999 
For version 1 
APP PROJECT PATTERNS 
•App web project feature 
–Use same version as app 
•Feature upgrade actions 
–Never use “Begin Range” 
–“End Range” exclusive 
•Client web part 
–Always change name 
–Removes old versions 
<EndRange= 3.0.0.0> 
2.000 -2.999 
For version 1 & 2
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
PROVIDER-HOSTED VERSIONING 
Pass In App Version 
Page V 1 
Page V 3 
Page V 3 
App V 1 
App V 1 
App V 3 
?
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
UPDATE LOGIC 
•Same as app feature pattern 
•Add logic to install receiver without checks
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
ROLL BACK ON ERROR
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
TELL SHAREPOINT 
•Result is an SPRemoteEventResultobject
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Finally, lets update an app
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
DEMO 
•Updating our App
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
THE APP IS UPDATED 
The shift to Updating 
How to Update 
Demo
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
SUMMARY 
Building Apps 
App Publishing 
Updating Apps 
Moving From Full Trust Code 
Getting Started with Apps
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
CALL TO ACTION 
•Get an O365 Developer License 
•Join the PnP Yammer Group 
•Visit the PnP GitHub
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
FINAL COMMENT 
•Now we have a tools and the understanding to create apps and move away from full trust code 
•Thank you for listening
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
QUESTIONS? 
srennocks@prosource-corp.com
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Established in 2009 
Offices in Richfield, OH + Atlanta, GA 
Areas of Expertise: 
•Application Development Consulting 
•Cloud Consulting 
•Core Infrastructure Consulting 
•Managed Services 
•Staffing Services 
COMPANY OVERVIEW
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
MICROSOFT PARTNERSHIP 
Awards & Recognition 
•Microsoft 2014 Partner of the Year, U.S. Enterprise Services 
•Microsoft 2013 Partner of the Year, U.S. Enterprise Services, Commercial Sector 
•Microsoft 2012 Partner of the Year, U.S. Enterprise Services, Commercial Sector 
•Microsoft 2011 Partner of the Year, U.S. Enterprise Services
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
OUR VALUES: THE FOUNDATION 
QUALITYWe’re about getting the job done right, developing supportable solutions that perform to our client’s requirements. 
VALUEWorking with us will yield excellent value for our client’s investment. 
EXCELLENCEWe use our best talent and abilities to create practical and usable software and services. 
TRUSTWe partner with our clients to deliver on-time, within budget, with our long-term success a top priority.
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
OUR AREAS OF EXPERTISE 
Where we SHINE and do AMAZING work!
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
We enhance and extend current product functionality or develop new software applications and capabilities. We ensure that your applications support your immediate and future business needs. We also help leverage and integrate into your existing systems and devices, enabling you to take better advantage of your investments. 
APPLICATION DEVELOPMENT
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
We help you leverage your existing investments, infrastructure and skill sets to build the right cloud solution for your business—one that will scale securely and work for you today and in the future. 
CLOUD
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
We bring proven methodologies, tools and processes to enable easier manageability, monitoring, implementations, migrations and updates to key infrastructure technologies. This also includes adoption of cloud solutions when it is appropriate for your business. 
CORE INFRASTRUCTURE
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
We enable you to optimize and reduce the cost of key business systems by managing your Windows ™ infrastructure –servers and software –by providing remote technical support assistance. Our best in class tools and resources provide peace of mind when tackling the challenges of managing your infrastructure, freeing you up to focus on strategic business needs. 
MANAGED SERVICES
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
We pair the right technologist with the right company –whether it’s for a short-term engagement or long-term employment. We access the needs, goals and personalities to make the right fit. 
STAFFING
ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 
Financial Services 
Manufacturing 
Government 
Healthcare 
Services 
INDUSTRIES WE SERVE

More Related Content

PDF
Real World SharePoint Framework and Azure Services
PPTX
Progressive Web Apps and React
PDF
What is Server-side Rendering? How to Render Your React App on the Server-sid...
PDF
Business Applications Integration In The Cloud
PDF
Travelling Light for the Long Haul - Ian Robinson
PPTX
Getting Started with SharePoint 2013 Apps
PDF
Enterprise apps in SharePoint 2013
PPTX
Visbility at the Edge - Deep Insights from Your API
Real World SharePoint Framework and Azure Services
Progressive Web Apps and React
What is Server-side Rendering? How to Render Your React App on the Server-sid...
Business Applications Integration In The Cloud
Travelling Light for the Long Haul - Ian Robinson
Getting Started with SharePoint 2013 Apps
Enterprise apps in SharePoint 2013
Visbility at the Edge - Deep Insights from Your API

What's hot (20)

PDF
Building Canvas Apps with ASP.NET and Azure
PPTX
Supercharge Your SharePoint Framework Webpart with React
PPTX
Jump start your Rapid Application Delivery with WaveMaker
PDF
Progress application server for openedge best practices - PUG Baltic Annual C...
PDF
Application Express - A web development environment for the masses - and for ...
PDF
Visualforce & Force.com Canvas: Unlock your Web App inside of Salesforce.com ...
PPTX
Open Source for Affiliates - Sanjit Atwal and Matt Rogers
PPTX
Mobile APIs: Optimizing APIs for Many Devices
PPTX
Force.com Canvas - a Quick Introduction
PPTX
Practical strategies to innovate faster and meet business goals
KEY
Web API HTTP Pipeline
PPTX
Salesforce Mobile Developer Week Meetup karachi
PPTX
Spring on PAS - Fabio Marinelli
PPTX
Move past bootstrap and build our lightweight responsive framework w.v1.2
PPTX
Microsoft+PHP: Make Web Not War
PPTX
Uncovering the Latest in SharePoint Development
PDF
Making External Web Pages Interact With Visualforce
PPTX
Use office ui fabric react to build beauty with SharePoint
PDF
BlackBerry10: "Built For BlackBerry (BFB)"
PDF
Kendo UI workshop introduction - PUG Baltic Annual Conference 2017
Building Canvas Apps with ASP.NET and Azure
Supercharge Your SharePoint Framework Webpart with React
Jump start your Rapid Application Delivery with WaveMaker
Progress application server for openedge best practices - PUG Baltic Annual C...
Application Express - A web development environment for the masses - and for ...
Visualforce & Force.com Canvas: Unlock your Web App inside of Salesforce.com ...
Open Source for Affiliates - Sanjit Atwal and Matt Rogers
Mobile APIs: Optimizing APIs for Many Devices
Force.com Canvas - a Quick Introduction
Practical strategies to innovate faster and meet business goals
Web API HTTP Pipeline
Salesforce Mobile Developer Week Meetup karachi
Spring on PAS - Fabio Marinelli
Move past bootstrap and build our lightweight responsive framework w.v1.2
Microsoft+PHP: Make Web Not War
Uncovering the Latest in SharePoint Development
Making External Web Pages Interact With Visualforce
Use office ui fabric react to build beauty with SharePoint
BlackBerry10: "Built For BlackBerry (BFB)"
Kendo UI workshop introduction - PUG Baltic Annual Conference 2017
Ad

Viewers also liked (20)

PPTX
From Trashy to Classy: How The SharePoint 2013 App Model Changes Everything
PPTX
SP2013 for Developers - Chris O'Brien
PPTX
Road to the Cloud - Extending your reach with SharePoint and Office 365
PPTX
SharePoint Evolution conference 2013 - Bringing SharePoint Information into O...
PPTX
SharePoint App Store - itunes for you business
PPTX
SPCA2013 - Once you go app you don't go back
PPTX
A Deep-Dive into Real-World SharePoint App Development
PPTX
Votre première App SharePoint pour Office 365 avec Visual Studio !
PPTX
Apps 101 - Moving to the SharePoint 2013 App Model - Presented 7/27/13 at Sha...
PPTX
Building your first app for share point 2013
PPTX
Share point app architecture for the cloud and on premise
PDF
Building a Windows Store App for SharePoint 2013
PDF
SharePoint Summit Vancouver: Reach your audience with a SharePoint mobile app
PPTX
Developer’s Independence Day: Introducing the SharePoint App Model
PDF
O365con14 - the new sharepoint online apps - napa in action
PPTX
SPSNL - Bringing SharePoint information into Office through Office Apps
PPTX
SharePoint 2013 App Provisioning Models
PPTX
Tutorial: Building Apps for SharePoint 2013 Inside and Outside of the Firewal...
PPTX
Introduction to the new SharePoint 2013 App Model
PPTX
7 Key Things for Building a Highly-Scalable SharePoint 2013 App
From Trashy to Classy: How The SharePoint 2013 App Model Changes Everything
SP2013 for Developers - Chris O'Brien
Road to the Cloud - Extending your reach with SharePoint and Office 365
SharePoint Evolution conference 2013 - Bringing SharePoint Information into O...
SharePoint App Store - itunes for you business
SPCA2013 - Once you go app you don't go back
A Deep-Dive into Real-World SharePoint App Development
Votre première App SharePoint pour Office 365 avec Visual Studio !
Apps 101 - Moving to the SharePoint 2013 App Model - Presented 7/27/13 at Sha...
Building your first app for share point 2013
Share point app architecture for the cloud and on premise
Building a Windows Store App for SharePoint 2013
SharePoint Summit Vancouver: Reach your audience with a SharePoint mobile app
Developer’s Independence Day: Introducing the SharePoint App Model
O365con14 - the new sharepoint online apps - napa in action
SPSNL - Bringing SharePoint information into Office through Office Apps
SharePoint 2013 App Provisioning Models
Tutorial: Building Apps for SharePoint 2013 Inside and Outside of the Firewal...
Introduction to the new SharePoint 2013 App Model
7 Key Things for Building a Highly-Scalable SharePoint 2013 App
Ad

Similar to Transitioning to SharePoint App Development (20)

PDF
(Almost) All About Apps for SharePoint 2013
PPTX
Access share point-2013-data-with-provider-hosted-apps
PPTX
App Model For SharePoint 2013
PDF
Building SharePoint 2013 Apps - Architecture, Authentication & Connectivity API
PPTX
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
PPTX
The SharePoint 2013 App Model
PDF
Understanding SharePoint 2013 Code Deployment Models - Apps vs Solutions - Sh...
PPTX
Prepararsi a spostare le proprie applicazioni share point su office 365
PPTX
Developing Apps for SharePoint 2013
PPTX
SP Apps, New Model, New App Store: The Office Store
PPTX
Getting started with SharePoint 2013 online development
PPTX
SharePoint 2013 Apps Introduction
PPTX
Developing Apps for SharePoint Store
PPTX
Sp2013 overview biwug
PPTX
Sp2013 overview
PPTX
Share point unvealed apps in sharepoint 2013
PPTX
Deep dive into SharePoint 2013 hosted apps - Chris OBrien
PPTX
2014 SharePoint Saturday Melbourne Apps or not to Apps
PPTX
SharePoint Development with Visual Studio 2012
PPTX
Heading to the Cloud : Introduction to deploying a Provider-Hosted App in Azure
(Almost) All About Apps for SharePoint 2013
Access share point-2013-data-with-provider-hosted-apps
App Model For SharePoint 2013
Building SharePoint 2013 Apps - Architecture, Authentication & Connectivity API
SharePoint Saturday Silicon Valley - SharePoint Apps - Ryan Schouten
The SharePoint 2013 App Model
Understanding SharePoint 2013 Code Deployment Models - Apps vs Solutions - Sh...
Prepararsi a spostare le proprie applicazioni share point su office 365
Developing Apps for SharePoint 2013
SP Apps, New Model, New App Store: The Office Store
Getting started with SharePoint 2013 online development
SharePoint 2013 Apps Introduction
Developing Apps for SharePoint Store
Sp2013 overview biwug
Sp2013 overview
Share point unvealed apps in sharepoint 2013
Deep dive into SharePoint 2013 hosted apps - Chris OBrien
2014 SharePoint Saturday Melbourne Apps or not to Apps
SharePoint Development with Visual Studio 2012
Heading to the Cloud : Introduction to deploying a Provider-Hosted App in Azure

Recently uploaded (20)

PPTX
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
PPTX
Comunidade Salesforce São Paulo - Desmistificando o Omnistudio (Vlocity)
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
GDG Cloud Iasi [PUBLIC] Florian Blaga - Unveiling the Evolution of Cybersecur...
PDF
AI And Its Effect On The Evolving IT Sector In Australia - Elevate
PDF
Transforming Manufacturing operations through Intelligent Integrations
PPTX
Big Data Technologies - Introduction.pptx
PDF
Sensors and Actuators in IoT Systems using pdf
PDF
Review of recent advances in non-invasive hemoglobin estimation
PPTX
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
PDF
Electronic commerce courselecture one. Pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
HCSP-Presales-Campus Network Planning and Design V1.0 Training Material-Witho...
PDF
madgavkar20181017ppt McKinsey Presentation.pdf
PDF
How Onsite IT Support Drives Business Efficiency, Security, and Growth.pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Chapter 2 Digital Image Fundamentals.pdf
PDF
Empathic Computing: Creating Shared Understanding
PA Analog/Digital System: The Backbone of Modern Surveillance and Communication
Comunidade Salesforce São Paulo - Desmistificando o Omnistudio (Vlocity)
Reach Out and Touch Someone: Haptics and Empathic Computing
GDG Cloud Iasi [PUBLIC] Florian Blaga - Unveiling the Evolution of Cybersecur...
AI And Its Effect On The Evolving IT Sector In Australia - Elevate
Transforming Manufacturing operations through Intelligent Integrations
Big Data Technologies - Introduction.pptx
Sensors and Actuators in IoT Systems using pdf
Review of recent advances in non-invasive hemoglobin estimation
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
Electronic commerce courselecture one. Pdf
Understanding_Digital_Forensics_Presentation.pptx
Spectral efficient network and resource selection model in 5G networks
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
HCSP-Presales-Campus Network Planning and Design V1.0 Training Material-Witho...
madgavkar20181017ppt McKinsey Presentation.pdf
How Onsite IT Support Drives Business Efficiency, Security, and Growth.pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
Chapter 2 Digital Image Fundamentals.pdf
Empathic Computing: Creating Shared Understanding

Transitioning to SharePoint App Development

  • 1. TRANSITIONING TO SHAREPOINT APP DEVELOPMENT Simon Rennocks Principal Consultant Microsoft Certified Master -SharePoint ProSourceSolutions LLC
  • 2. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com SPEAKER BACKGROUND Expertise Principal Consultant Microsoft Certified Master -SharePoint ProSourceSolutions LLC 18+ Years of Experience Email [email protected] Blog rennocks.wordpress.com Twitter @simonrennocks
  • 3. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com SESSION GOALS •Understand why apps will replace full trust code •Know how to create an on premise development environment for building apps •Be able to create SharePoint apps on premise and in Office 365 •Know how to publish apps both on premise and to Office 365 •Follow the best practices for developing updates for apps
  • 4. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com AGENDA Building Apps App Publishing Updating Apps Moving From Full Trust Code Getting Started with Apps
  • 5. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com MOVING FROM FULL TRUST CODE
  • 6. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CODE DIFFERENCES Full Trust Feature Receivers Web Parts Application Pages Server-Side Code Apps App Event Receiver App Parts App Pages Remote Server-side Code
  • 7. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com OPERATIONAL COMPARSION Full Trust User Only Security Elevated Permissions Apps User & App Security Use “App Only” Break Inheritance Request Permissions No Resource Monitoring Resource Monitoring
  • 8. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEPLOYMENT CHANGES Full Trust To Farm Files in Hive Assemblies in GAC WSP Deployment Apps To Site Collection Everything in Content DB Assemblies Remote .App Publishing
  • 9. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com What challenges do full trust solutions pose?
  • 10. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WEB PART REFACTORING Use client side code Separate out SharePoint code Use REST endpoints
  • 11. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com 2010 CHALLENGES Server-side Code Full Permissions Not following Best Practices Performance and Errors Unhandled Errors & Crashes Slow Sites Development Cycle Long approval times Cross Solution Testing
  • 12. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CROSS PLATFORM DEVELOPMENT •Languages and technologies •Lower entry bar •MVC and MVVP support •Expanded object model
  • 13. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com How are apps different?
  • 14. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com EVOLUTION OF OBJECT MODEL SharePoint 2010 2007 SharePoint 2013
  • 15. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WHY APPS SHOULD BE USED •Familiar programming model •Multiple hosting options •Flexible web experience •Integrates with Office apps •App available to users via –Office Store –App Catalog
  • 16. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WHEN TO USE APPS •Using SharePoint in Office 365 –Apps required •If On-Premise –Meets business requirements •In the Cloud and On-Premise –Best to use apps
  • 17. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WHAT HAVE WE COVERED? Comparison Full Trust Challenges How Apps Can Help
  • 18. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com GETTING STARTED WITH APPS
  • 19. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WHAT ARE APPS •Lightweight web applications –Apps parts hosted in IFrame •Web scoped –Own isolated app web •Tenant “shared” scoped –Shared app web across multiple site collections •Different authentication options –Azure ACS for low trust –on premise or O365 –Digital certificates for high trust –on premise only
  • 20. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com TYPES OF APP Immersive Full Page App Part UI Custom Action NOT TENANT SCOPED
  • 21. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com App Web SHAREPOINT-HOSTED APP 1.Isolated app web 2.SharePoint Access 3.Cross-domain library 4.Tenant scope access Host Web 1 3 JSOM 2 Other Site Collections 4 JSOM REST REST
  • 22. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com PROVIDER-HOSTED APP 1.Client-side object model 2.App Web optional 3.Provide tenant isolation 4.Tenet Scope access App Web Host Web Remote Web 1 2 3 Other Site Collections 1 4 3 2 REST SCOM, REST, JSOM
  • 23. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com What’s needed before we can create apps?
  • 24. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP PREREQUISITES On Premise Office 365
  • 25. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com ON PREMISE SETUP Create Development Farm Provision Services User Profile App Management Subscription Service Create Isolated Domain Configure Settings App Domain App Prefix
  • 26. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CREATING CERTIFICATES •Create self-signed cert •Create folder for certs •Export certs to folder •Give app pools access •Register .cerwith SP •Project uses .pfxcert •App uses .cercert IIS Project App Register Cert .cer pfx Folder
  • 27. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEVELOPER TOOLS •Office 365 developer subscription –Or use a site with developer template –Develop using “Napa” •Visual Studio –Professional or higher –2012 or 2013 plus latest updates •Extensions required –Microsoft Office Developer Tools –NuGetPackage installer
  • 28. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP INFRASTRUCTURE OVERVIEW Where Stage Requirement SharePointHosted Provider Hosted Setup Provision app farmservices   CreateIsolatedapp domain  Optional Createcertificates & configure trust HighTrust Configureaccess to Azure AD ACS Low Trust Setup Development sitecollection   VisualStudio 2012 or 2013   Create Appcatalog  
  • 29. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Lets look at how to do this
  • 30. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEMO •Configuring a developer farm to support apps
  • 31. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com WHAT HAVE WE LEARNED? What are Apps App Prerequisites On Premise Setup
  • 32. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com BUILDING APPS
  • 33. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP PROJECT SETUP •SharePoint location •Specify hosting model
  • 34. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com PROVIDER-HOSTED OPTIONS •Choose web app type •Choose authentication
  • 35. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com SharePoint-Hosted Provider-Hosted APP PROJECT STRUCTURE
  • 36. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CLIENT WEB PART Properties passed in query string Properties Defined in here Reference to web page Default app part dimensions
  • 37. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com JSOM PATTERN •Get SharePoint context using app web url •Define objects to get •Execute to get objects •Result sent to asyncevent
  • 38. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CSOM PATTERN •Pass in HttpContextto return SP context •Create user context from the SP context •Determine what we need •Group as much in each Load as possible •Execute to get the data •Use the data returned
  • 39. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CROSS DOMAIN •Get the app web and host web url’s •Load the cross domain library from the host web •Specify callback event to access host web objects
  • 40. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CROSS DOMAIN •Get the app web context •AppContextSiteused to access host web •Specify permissions need in AppManifest
  • 41. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com HOST WEB PERMISSIONS <AppPermissionRequests> <AppPermissionRequest Scope="http://sharepoint/content/sitecollection/web" Right="Manage" /> </AppPermissionRequests> AllowAppOnlyPolicy="true">
  • 42. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com How do we deploy app components?
  • 43. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP COMPONENTS •Type of app assets –SharePoint lists, document libraries –Images, cssand javascriptfiles •Deploy from app –When app first accessed –Required host web manage rights •Deploy using app event receiver –Receiver added to remote web –Use azure web sites
  • 44. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com ASSET DEPLOYMENT • To app web – If isolation required – Need to sell app • To host web – Easier user access – Shared app access
  • 45. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP EVENT RECEIVERS •From app project –Enable property pane –Service endpoint added to AppManifest •In web project –Receiver service code class •Debugging possible –Requires azure service bus reference
  • 46. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Lets create some Apps
  • 47. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEMO •Create a Provider-hosted app –Office 365 –App event receiver for components Alt
  • 48. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com THE APP BUILT AND PUBLISHED Creating an App App Components Demo App
  • 49. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP PUBLISHING
  • 50. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP REGISTRATION –HIGH TRUST •Provider-hosted apps –Use AppRegNew.aspx Sameas Client Id Hosting url Required only for apps launched from outside of SharePoint Not used in high trust apps
  • 51. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com HIGH TRUST SETUP •Create web site –In web.configadd
  • 52. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com How do we publish low trust apps?
  • 53. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP REGISTRATION –LOW TRUST •Provider-hosted apps –Use AppRegNew.aspx Same as Client Id Hosting url Required only for apps launched from outside of SharePoint Same as Client Secret
  • 54. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com AZURE WEB SITES Add client Id & secret to app settings Download Publishing Profile Create web site
  • 55. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com APP DEPLOYMENT –LOW TRUST App project Client Id and secret Publish app Add to app catalog Web project Add publishing profile Publish web to azure
  • 56. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Lets publish our App
  • 57. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEMO •Publish a low trust app to Office 365
  • 58. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com THE APP IS PUBLISHED High Trust Apps Low Trust O365 Apps Publishing Demo
  • 59. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com UPDATING APPS
  • 60. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com UPDATE BETTER THAN REPLACING Update due to •Required for store apps •Data preserved Replace will not work •No control on what users do with App
  • 61. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com KEY POINTS •Users may not update app –One app version –Same version after update –Update logic relies on version number •Rolls back on error –All components –App data not lost –Mostly automatic except for custom logic –Errors reported to UI
  • 62. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com EDGE CASE RISKS •Installing too little –User using version 1 of app –Missed going to version 2 –Updates to version 3 –Update logic fails to add version 2 list –App fails on displaying version 2 list •Installing too much –User updates from version 2 to 3 –Update logic tries to re-add version 2 list –Update fails due to existing list
  • 63. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com How should we update Apps?
  • 64. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Previous updates in version range Current update <EndRange= 2.0.0.0> 1.000 -1.999 For version 1 APP PROJECT PATTERNS •App web project feature –Use same version as app •Feature upgrade actions –Never use “Begin Range” –“End Range” exclusive •Client web part –Always change name –Removes old versions <EndRange= 3.0.0.0> 2.000 -2.999 For version 1 & 2
  • 65. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com PROVIDER-HOSTED VERSIONING Pass In App Version Page V 1 Page V 3 Page V 3 App V 1 App V 1 App V 3 ?
  • 66. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com UPDATE LOGIC •Same as app feature pattern •Add logic to install receiver without checks
  • 67. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com ROLL BACK ON ERROR
  • 68. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com TELL SHAREPOINT •Result is an SPRemoteEventResultobject
  • 69. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Finally, lets update an app
  • 70. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com DEMO •Updating our App
  • 71. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com THE APP IS UPDATED The shift to Updating How to Update Demo
  • 72. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com SUMMARY Building Apps App Publishing Updating Apps Moving From Full Trust Code Getting Started with Apps
  • 73. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com CALL TO ACTION •Get an O365 Developer License •Join the PnP Yammer Group •Visit the PnP GitHub
  • 74. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com FINAL COMMENT •Now we have a tools and the understanding to create apps and move away from full trust code •Thank you for listening
  • 75. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com QUESTIONS? [email protected]
  • 76. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Established in 2009 Offices in Richfield, OH + Atlanta, GA Areas of Expertise: •Application Development Consulting •Cloud Consulting •Core Infrastructure Consulting •Managed Services •Staffing Services COMPANY OVERVIEW
  • 77. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com MICROSOFT PARTNERSHIP Awards & Recognition •Microsoft 2014 Partner of the Year, U.S. Enterprise Services •Microsoft 2013 Partner of the Year, U.S. Enterprise Services, Commercial Sector •Microsoft 2012 Partner of the Year, U.S. Enterprise Services, Commercial Sector •Microsoft 2011 Partner of the Year, U.S. Enterprise Services
  • 78. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com OUR VALUES: THE FOUNDATION QUALITYWe’re about getting the job done right, developing supportable solutions that perform to our client’s requirements. VALUEWorking with us will yield excellent value for our client’s investment. EXCELLENCEWe use our best talent and abilities to create practical and usable software and services. TRUSTWe partner with our clients to deliver on-time, within budget, with our long-term success a top priority.
  • 79. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com OUR AREAS OF EXPERTISE Where we SHINE and do AMAZING work!
  • 80. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com We enhance and extend current product functionality or develop new software applications and capabilities. We ensure that your applications support your immediate and future business needs. We also help leverage and integrate into your existing systems and devices, enabling you to take better advantage of your investments. APPLICATION DEVELOPMENT
  • 81. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com We help you leverage your existing investments, infrastructure and skill sets to build the right cloud solution for your business—one that will scale securely and work for you today and in the future. CLOUD
  • 82. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com We bring proven methodologies, tools and processes to enable easier manageability, monitoring, implementations, migrations and updates to key infrastructure technologies. This also includes adoption of cloud solutions when it is appropriate for your business. CORE INFRASTRUCTURE
  • 83. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com We enable you to optimize and reduce the cost of key business systems by managing your Windows ™ infrastructure –servers and software –by providing remote technical support assistance. Our best in class tools and resources provide peace of mind when tackling the challenges of managing your infrastructure, freeing you up to focus on strategic business needs. MANAGED SERVICES
  • 84. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com We pair the right technologist with the right company –whether it’s for a short-term engagement or long-term employment. We access the needs, goals and personalities to make the right fit. STAFFING
  • 85. ProSource Solutions, LLC. | www.prosourcesolutionsllc.com Financial Services Manufacturing Government Healthcare Services INDUSTRIES WE SERVE