1 / 24

patterns & practices Enterprise Library

patterns & practices Enterprise Library. Brian Button bbutton@agilestl.com Consultant/Developer patterns & practices. Speaker Introduction. Principal Consultant at Agile Solutions Group St. Louis-based Train, mentor, develop, lead teams in agile software development

bryce
Download Presentation

patterns & practices Enterprise Library

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. patterns & practicesEnterprise Library Brian Buttonbbutton@agilestl.comConsultant/Developerpatterns & practices

  2. Speaker Introduction • Principal Consultant at Agile Solutions Group • St. Louis-based • Train, mentor, develop, lead teams in agile software development • Consulted in Microsoft patterns & practices since October, 2003 • Smart Client Offline Application Block • Enterprise Library • My badge is orange, not blue • These opinions are mine and mine alone • I do not speak for MS or patterns & practices

  3. Welcome to an Exclusive Club!

  4. Short History

  5. patterns & practices Patterns Application Blocks Reference Architectures Atomic solutions to recurring problems Sub-system-level guidance for common services System-level guidance for common customer scenarios Guides Guidance on architectural principles and cross-cutting issues such as security and performance

  6. Application Blocks defined • Reusable, extensible, modifiable • Common mechanism • Logging • Caching • Configuration management… • Reusable fragment of app architecture • User interface process management • Smart disconnected client • Service aggregation…

  7. Application Blocks are great, but… • In general feedback has been extremely positive, but there is room for improvement: • Make blocks consistent • Make blocks work well together • Minimize dependencies • On other blocks • On infrastructure • Make it easier to configure blocks • Make evaluation and understanding of blocks easier • Make using blocks easier

  8. Introducing “Enterprise Library” • Library of reusable software assets to address common enterprise development challenges • Part of the patterns & practices guidance library • Strong focus on consistency, extensibility, ease of use and integration • v1 produced in partnership with Avanade, leveraging experience from customer engagements and incorporating aspects of their ACA.NET application framework

  9. Included Application Blocks • Caching • Data • Exception Handling • Logging • Security • Cryptography (symmetric only) • Common configuration and tooling

  10. Let’s build an example app • Simple data access to Northwind • Add a bit of logging • And some exception handling

  11. Enterprise Library v1 Architecture Exception Handling Caching Data Access Logging & Instrumentation Security Crypto Config Tooling Config Run-Time

  12. Block Code Block Code Block Code Pluggable Providers Block Configuration Code Block Architecture Block Configuration Design Code Unit Tests

  13. What comes in the box? • There is no box • Released as guidance • Source code format only • “As-is”, like rest of p&p guidance • You get • All source • All unit tests • Documentation • Quick starts

  14. Caching Application Block • Provides a flexible and extensible caching mechanism that can be used at all layers of an application • Supports backing stores that persist cache data into a database or isolated storage, so the data can survive app restarts • Can be used in ASP.NET apps, although the ASP.NET cache is preferred for simple scenarios • Supports similar scenarios to the original caching block, but with a revised architecture to make it more thread- and exception-safe

  15. Data Access Application Block • Provides simplified access to the most common data access operations • Aim was to keep much of the simplicity of the original DAAB blocks, but to provide additional features requested by customers • Notable new features: • Support for multiple database types through a factory (SQL Server, Oracle and DB2 out of the box). This provides consistent and portable code (caveats apply!) • Connection strings are stored and managed in external configuration

  16. Exception Handling Application Block • Facilitates consistent exception handling behavior at logical boundaries of an application • Allows the creation of “exception policies” which dictate which actions should be taken for specific exception types at the logical boundary • Example: All security exceptions arising from the business layer need to be logged, and the messages sanitized before being propagated to the caller • Actions are extensible; we provide Logging, Wrapping one exception with another, and Replacing one exception with an other • Block has little in common with the existing EMAB which was primarily used to log exceptions

  17. Logging & Instrumentation Application Block • Allows applications to log business and operations data to various destinations, which are externally configurable • Replaces the Enterprise Instrumentation Framework and the existing Logging Application Block • Configuration specifies which messages go where, and how they are formatted • Formatters and sinks are extensible. We provide sinks for Event Log, Database, Text File, MSMQ, E-mail, WMI and Windows Event Tracing

  18. Security Application Block • Provides a simple API and pluggable implementations of core security primitive operations • Covers 5 security areas: Authentication, Authorization, Roles, Profile and Security Caching • Each module supports extensible plug-in providers. In general we supply plug-ins for common Microsoft infrastructure (AD, AzMan) as well as a light-weight database implementation • Developers can build their own plug-ins to interface with existing security solutions

  19. Cryptography Application Block • Provides a simplified approach to implementing common cryptography scenarios • Includes modules for symmetric cryptography and hashing • Each module supports pluggable algorithms and key stores • Supports all .NET crypto algorithms out of the box, or developers can implement their own • Algorithms and keys can be managed through the configuration tool

  20. Configuration Application Block • Allows applications to easily read and write configuration data from configurable storage locations • Used by all blocks in Enterprise Library, can also be used by customer blocks, frameworks and applications • Includes two parts: • Configuration Runtime, which applications use at runtime to access configuration data • Configuration Designtime, which provides nodes that are used by the configuration tool to give a simple design-time experience • Configuration can be encrypted and individual elements can be masked in the tool

  21. Lots of places to go learn more… • Webcasts • Several overview webcasts plus one webcast per block • http://www.pnplive.com • Hands on Labs • Labs focused on learning to use each block • http://www.pnplive.com/hands_on_labs.htm • Podcasts • Listen to the Enterprise Library developers talk about the culture, experiences, and history of EL V1. • http://www.ronjacobs.com/podcast/default.htm

  22. Even more places… • Patterns & Practices • Download and install Enterprise Library • http://msdn.microsoft.com/practices • Enterprise Library GotDotNet Workspace • http://practices.gotdotnet.com/projects/entlib

  23. Learn from the authors Enterprise Library team blogs: • Brian Button http://oneagilecoder.agilestl.com • Scott Densmore http://blogs.msdn.com/scottdensmore • Peter Provost http://peterprovost.org • Jim Newkirk http://blogs.msdn.com/jamesnewkirk • Tom Hollander http://blogs.msdn.com/tomholl • Hisham Baz http://blog.hishambaz.com • Tim Shakarian http://dotnetjunkies/WebLog/tshak

  24. What’s coming? • Enterprise Library June 2005 • Bug fixes, a few new features, changes to compile on Whidbey • June 30, 2005 or so • Enterprise Library for .NET 2.0 • Same feature set implemented on Whidbey • A little while after Whidbey ships • Enterprise Library V?.? • Solving the next batch of problems • A year or more after Whidbey ships

More Related