Building Sandboxed Solutions

1,425 views

Published on

Webcast da Copa de Talentos Microsoft sobre Sandboxed Solutions.

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,425
On SlideShare
0
From Embeds
0
Number of Embeds
6
Actions
Shares
0
Downloads
0
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide
  • Today we're going to cover one small part of what you need to know to be a SharePoint developer. The whole series, the rest of the nine Web casts that will be coming in the following weeks, will cover other aspects of the SharePoint world, and things that you should know to be able to develop in SharePoint. What we're going to talk about today is the Web Parts infrastructure in SharePoint, how it relates to the Web part infrastructure in ASP.NET 2.0. We'll build a Web part very quickly and easily. It will take about two minutes. We'll deploy that Web part. We'll talk about security in Web Parts, what's good access security, what does that mean, how does that impact the solutions you're going to build. We'll talk a little bit about how you can expose Web part properties, how you can get configuration information into your Web part. We'll talk about connecting Web Parts to one another so that you can take smaller Web Parts and connect them into more meaningful solutions. And we'll talk about user controls and how they fit into the Web part framework.
  • Building Sandboxed Solutions

    1. 1. Aguarde em instantes o webcast será realizado.<br />Verifique se seu áudio está funcionando.<br />
    2. 2. Building Sandboxed Solutions<br />Marcel Medina<br />Desenvolvedor SharePoint<br />Microsoft Trainer<br />Wagner Amorim<br />Desenvolvedor SharePoint<br />Done IT<br />
    3. 3. Agenda<br />Apresentação<br />Palestrante e Moderador<br />Objetivo do WebCast<br />Introdução<br />Desenvolvimento e Deploy<br />Arquitetura<br />Perguntas e Respostas<br />
    4. 4. Apresentação<br />Marcel Medina<br />SharePoint Developer @ Practiv (NZ)<br />http://sharepoint4developers.spaces.live.com<br />http://sharepoint4developersnz.spaces.live.com<br />http://www.canalsharepoint.com.br/marcelmedina<br />Tem atuadoativamentenacomunidade SharePoint com a publicação de artigos e comomoderador no CanalSharePoint.<br />Possui as seguintesCertificações Microsoft:<br />MCT (2008 / 2009 / 2010)<br />MCPD (Enterprise Application Developer);<br />MCTS (Windows SharePoint Services 3.0 Application Development); <br />MCTS (.Net Framework 2.0 Distributed Applications);<br />MCTS (.Net Framework 2.0 Web Applications);<br />MCTS (.Net Framework 2.0 Windows Applications);<br />MCSD (For Microsoft .NET);<br />MCAD (For Microsoft .NET);<br />MCDBA (Microsoft SQL Server 2000).<br />
    5. 5. Apresentação<br />Wagner Amorim<br />Done IT<br />www.canalsharepoint.com.br<br />www.doneit.com.br<br />waamorim.spaces.live.com<br />MCPD Web Developer<br />MCTS (Windows SharePoint Services 3.0, Microsoft Office SharePoint Server 2007 - configuração e desenvolvimento); <br />Líder da Comunidade Canal Sharepoint com vários artigos publicados nos sites www.linhadecodigo.com.br e www.canalsharepoint.com.br<br />Tem atuado fortemente nos fóruns Microsoft TechNet e MSDN voltados para a tecnologia SharePoint.<br />
    6. 6. Objetivo<br />Este webcast terá como objetivo uma abordagem introdutória sobre Sandboxed Solutions para desenvolvedores, contemplando conceitos, desenvolvimento e deploy de Sandboxed Solutions no Sharepoint 2010.<br />
    7. 7. Cenário Sharepoint 2007<br />Desenvolvedores<br />Desenvolvedores criam soluções customizadas.<br />Administradores podem apenas garantir que as soluções sejam executadas utilizando CAS policies, o que é difícil controlar o que está sendo feito no código.<br />Causas de problemas no Sharepoint: código customizado.<br />Administradores<br />Site Collection Admin<br />
    8. 8. Cenário Sharepoint 2010<br />Desenvolvedores<br />Desenvolvedores criam soluções customizadas.<br />Site Collection Admins fazem o deploy, ativam e implementam as customizações.<br />Administradores possuem mais recursos para monitorarem as soluções nos site collections.<br />Administradores<br />Site Collection Admin<br />
    9. 9. Sandboxed Solutions<br />São executadas em um processo separado do w3wp, que o caracterizacomo sandbox.<br />Utilização de um subset das classes do Microsoft.SharePoint<br />Limitação de funcionalidadespelo Code Access Security policy.<br />Deploy realizado pelo Administrador do Site Collection<br />São armazenados na Solution Gallery<br />
    10. 10. Uma Sandboxed Solution <br />
    11. 11. Restrições do subset Microsoft.Sharepoint<br />Microsoft.SharePoint<br /><ul><li>SPSecurity object
    12. 12. SPWorkItem e SPWorkItemCollection objects
    13. 13. SPAlertCollection.Addmethod
    14. 14. SPAlertTemplateCollection.Add method
    15. 15. SPUserSolution e SPUserSolutionCollection objects
    16. 16. SPTransformUtilities</li></ul>Microsoft.SharePoint.Utilities<br /><ul><li>SPUtility.SendEmail method
    17. 17. SPUtility.GetNTFullNameandEmailFromLogin method</li></ul>Microsoft.SharePoint.WebPartPages<br /><ul><li>SPWebPartManager object
    18. 18. SPWebPartConnection object
    19. 19. WebPartZone object
    20. 20. WebPartPage object
    21. 21. ToolPane object
    22. 22. ToolPart object</li></li></ul><li>Code Access Security Policy<br />SharePointPermission.ObjectModel<br />SecurityPermission.Execution<br />AspNetHostingPermission.Level = Minimal<br /><trustLevel name="WSS_Sandbox" policyFile="..configwss_usercode.config" /><br />Nãosãopermitidos:<br /><ul><li>Network access (internet, web service, WCF, REST)
    23. 23. Hard drive access
    24. 24. Registry access
    25. 25. Deploy no GAC</li></li></ul><li>Soluções Suportadas<br />List definitions<br />List instances<br />Onet.xml<br />WebTemplate Feature element instead of Webtemp.xml<br />Content Types/Fields<br />Navigation<br />Module/files<br />Feature callouts<br />Web Parts derived from WebPart<br />Event receivers<br />SPItemEventReceiver<br />SPListEventReceiver<br />SPWebEventReceiver<br />Custom Actions<br />Workflows<br />
    26. 26. SoluçõesNãoSuportadas<br />Custom Action groups<br />HideCustomAction element<br />Content Type Binding<br />Web Application-scoped Features<br />Farm-scoped Features<br />Timer Jobs<br />Visual Web Parts<br />
    27. 27. Desenvolvendo uma Sandboxed Solution <br />
    28. 28. Arquitetura<br />FRONT END<br />BACK END<br />Host Service (SPUCHostService.exe)<br />Execution Wrapper(Inside Application Pool)<br />Worker Process<br />(SPUCWorkerProcess.exe)<br />IIS(W3WP.EXE)<br />Proxy Process<br />(SPUCWorkerProcessProxy.exe)<br />Untrusted Code<br />Subset Object Model<br />Full Object Model<br />
    29. 29. Arquitetura<br />FRONT END<br />BACK END<br />Host Service (SPUCHostService.exe)<br />Execution Wrapper(Inside Application Pool)<br />Worker Process<br />(SPUCWorkerProcess.exe)<br />IIS(W3WP.EXE)<br />Proxy Process<br />(SPUCWorkerProcessProxy.exe)<br />Untrusted Code<br />Subset Object Model<br />Subset-Model Request<br />Full Object Model<br />
    30. 30. Arquitetura<br />FRONT END<br />BACK END<br />Host Service (SPUCHostService.exe)<br />Execution Wrapper(Inside Application Pool)<br />Worker Process<br />(SPUCWorkerProcess.exe)<br />IIS(W3WP.EXE)<br />Proxy Process<br />(SPUCWorkerProcessProxy.exe)<br />Untrusted Code<br />Subset Object Model<br />Full-Model Request<br />Full Object Model<br />
    31. 31. Arquitetura<br />FRONT END<br />BACK END<br />Host Service (SPUCHostService.exe)<br />Execution Wrapper(Inside Application Pool)<br />Worker Process<br />(SPUCWorkerProcess.exe)<br />IIS(W3WP.EXE)<br /> while(true)<br /> {<br /> //Solução com problemas<br /> }<br />Proxy Process<br />(SPUCWorkerProcessProxy.exe)<br />Untrusted Code<br />Subset Object Model<br />Resource Wasting Call<br />Full Object Model<br />
    32. 32. Simulandouma Solution com problemas<br />
    33. 33. Benefícios<br />Segurança e estabilidade<br />As soluçõessãoexecutadasem um serviçoseparado e sãoexecutadas no contexto do Site Collection.<br />Monitoramentomaisefetivo.<br />Agilidade no deploy de soluções<br />Eliminação de processos de aprovação de código e deploy poradministradores.<br />
    34. 34. Referências<br /><ul><li>Sandboxed Solutions Architecture</li></ul>http://msdn.microsoft.com/en-us/library/ee539417(office.14).aspx<br /><ul><li>Developing, Deploying, and Monitoring Sandboxed Solutions in SharePoint 2010</li></ul>http://msdn.microsoft.com/en-us/magazine/ee335711.aspx<br /><ul><li>Criando Validadores para Sandboxed Solutions</li></ul>http://sharepoint4developers.spaces.live.com/blog/cns!419BF2880E221BB9!536.entry<br /><ul><li>Configurando Pontos no Sandbox</li></ul>http://sharepoint4developers.spaces.live.com/blog/cns!419BF2880E221BB9!518.entry<br />
    35. 35. P&R<br />Marcel Medina<br />http://sharepoint4developers.spaces.live.com<br />http://sharepoint4developersnz.spaces.live.com<br />

    ×