Getting started developing for share point

Post on 27-Jan-2015

107 views 2 download

Tags:

description

Start developing for SharePoint by avoiding common pitfalls.

transcript

Getting Started Developing For

SharePointGetting Started Developing For

SharePoint Online

10 Common Pitfalls – Getting it Right by Doing it Wrong

#SPRUNNERS

@rbethleh

About me

roelhans.bethlehem@rapidcircle.com

1. Assuming SharePoint Online and SharePoint 2013 are the same thing• Assumptions isthe mother of all screwups• There is no book for this….• You are only a tenant

Model On-Premises SharePoint Online Remark

Full trust Yes No

Sandbox Solution Yes Yes Deprecated for runtime code

Client Side Object Model Yes Yes Provider Hosted apps / Azure Hosted apps

Javascript Object Model Yes Yes SharePoint Hosted Apps

REST API Yes Yes

Countermeasures

• Get a SharePoint Online tenant• Get the SharePoint Development Tools• Limited support in VS Studio 2010• Get more tools from Apps for Office and SharePoint Dev Center• http://msdn.microsoft.com/en-us/office/apps/fp123627.aspx

• Start in Visual Studio with sandbox solution• Read Software Boundaries for SharePoint Online• http://office.microsoft.com/en-us/office365-sharepoint-online-enterprise-

help/sharepoint-online-software-boundaries-and-limits-HA102694293.aspx

2. Not having DTAP for SharePoint Online• Why do you not do the same as you would in a normal project?• Okay for first version, do you really want to fiddle in the live

environment?

Countermeasures

• Start on your own box for development• If you cannot run SharePoint 2013 on your own laptop; use Azure VMs or

CloudShare • You have direct access to the logs for troubleshooting on-premises

• Create T, A and P in Office 365• Go to: http://office.microsoft.com/en-001/business/• Free 30 day trial• Make sure you choose the right subscription!• Create sitecollection per build strategy

3. No automation of deployment

• Microsoft gave us 700+ cmdlets for SharePoint On-Premises, we got 27 for SharePoint Online• So how do we automate deployment in 4 different environment, one

being on premises

Countermeasures

• Create a build script• You can roll your own cmdlets• Sponlinecmdlets.codeplex.com

4. Forgetting about content

• What is a SharePoint site without content?• So why not put it in the build• Variant of: not enough automation

Countermeasures

• If you want demo content: http://www.microsoftofficedemos.com/• Great for demos and practice• If you want your own content:• Automate with Powershell as much as you can, we are in the business of

automation

5. Disregarding Sandbox Solutions

• So Sandbox Solutions are deprecated, really?• Caused quite a lot of talk in my team

Countermeasures

• See: SharePoint Sandbox isn't Dead...UserCode is• http://blogs.msdn.com/b/richard_dizeregas_blog/archive/

2013/08/01/sharepoint-sandbox-isn-t-dead-usercode-is.aspx• Keep using declarative model • Examples: contenttypes, sitecolumns, listtemplates, modules that deploy css,

javascript, render templates

• Stay away from Sandbox Solution that runs code unless you have a very good reason• Examples: feature receivers, webparts

6. Everything is an app

• Do you drink the Kool Aid?

Countermeasures

• Use scriptparts; its a webpart that contains just script• Use SharePoint hosted apps for simple UI orientated webparts if you

can• Azure Apps or Provider Hosted apps mean you now have two

problems (eh clouds)• Debugging apps can be superhard due to security model and browser

restrictions (cross domain policy)

7. Javascript? What is that? Isn’t that Java?• Your skills on the server side won’t get you anywhere in SharePoint

Online

Countermeasures

• Read Douglas Crockford: JavaScript the good parts• Practice Practice Practice

8. Trusting Search behaves the same as On-Premises• Well Search was kind of half finished• Keep looking for Contigious Indexing, Content By Search Webpart and

missing refiners (People Search)

Countermeasures

• Sorry you are out of luck here – waiting game• Use lists in Appweb to store data as in a cache so you do not need to

make roundtrips

9. Social is expected

• So Yammer versus SharePoint Newsfeeds

Countermeasures

• If you drink the KoolAid: Get a cup of Yammer• Its in the microsoftofficedemos.com• If you do not have Yammer or do not want to use it, you can still go

for Newsfeeds

10. My Site customization

• No stapling• Personal managed path

Countermeasures

• Shared can be branded just like any site• Everything under personal cannot • No feature stapling as this requires access to the filesystem / you are

only a tenant

Practice, Test, Practice

Assumption is the mother…