Transcript
Page 1: Next Generation LOB (Line of Business) Applications

Next Generation

Line of Business (LOB) Applications

Simon Guest

Senior Director, Technical Strategy

Microsoft Corporation

Page 2: Next Generation LOB (Line of Business) Applications

IntroductionMy First LOB Application

Page 3: Next Generation LOB (Line of Business) Applications

IntroductionMy First LOB Application

Back to 1994

Page 4: Next Generation LOB (Line of Business) Applications

IntroductionMy First LOB Application

My First LOB Application

Page 5: Next Generation LOB (Line of Business) Applications

IntroductionMy First LOB Application

Page 6: Next Generation LOB (Line of Business) Applications

IntroductionMy First LOB Application

What would happen if I tried to write

this today?

Page 7: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Page 8: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Wikipedia: A line-of-business application is one of the

set of critical computer applications that are vital to

running an enterprise

Page 9: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

The following 5 characteristics:

Page 10: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Interactive: LOB Applications are interactive by nature.

Data is entered, and results/reports are returned.

Page 11: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Composable: LOB applications tend to have one or

more parts that compose the user interface. These parts

may interact with each other as needed.

Page 12: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Data Driven: LOB applications are data intensive. Many

live “close” to the database, and access frequently.

Page 13: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Integrated: LOB applications often integrate with other

systems. These can be a variety of data feeds, either

within or outside the organization.

Page 14: Next Generation LOB (Line of Business) Applications

IntroductionDefining a LOB Application

Extensible: LOB applications are extensible by nature.

They often support add-ons or plug-ins used to tailor an

application or make deployment easier.

Page 15: Next Generation LOB (Line of Business) Applications

Session ObjectivesWhat are you going to get from this session?

Page 16: Next Generation LOB (Line of Business) Applications

Session ObjectivesWhat are you going to get from this session?

Explore each characteristic to help

you apply to your own application

Give you the details of what’s new

in each of these areas

Show through demos how we are

supporting these new features

Page 17: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Page 18: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

“How do I get this TAB order working?”

Back to 1994

Page 19: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Better forms, many controls, better

output, great reporting solutions, voice

command, etc.

Since then...

Page 20: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

What am I excited about now?

NUI (Natural User Input),

specifically touch

How about now?

Page 21: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Is touch going to replace the mouse

and keyboard?

Page 22: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Touch augments the Windows

experience. Every input method has it’s

pros and cons – no input method is

ideal for everything.

Page 23: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Are we really seeing devices that

support touch?

Page 24: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Device Availability

HP TouchSmart IQ504 PC(Intel Core 2 Duo T5750)

DELL Latitude XT2(Intel Core 2 Duo SU9400)

Page 25: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Is touch supported in Windows 7?

Page 26: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Gesture GestureAction Action Single

TouchMulti

Touch

Press and Tap Press on target, tap with other finger Yes

Zoom Two fingers apart/together Yes

Rotate Two fingers in opposing direction Yes

Two Finger Tap Tap two fingers Yes

Press and Hold Wait for blue ring and release Yes Yes

Flicks Quick drag gestures Yes Yes

Page 27: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

What you get for freePanning and Zooming, Right Click Gestures

Page 28: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Minimal Incremental WorkUse WM_GESTURE Win32 API to trap gesture

notifications, handle pan, zoom, and rotate

Page 29: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Best ExperienceUse WM_TOUCH Win32 API to handle raw touch data,

manipulation, and inertia processors

Page 30: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Does this relate to “Surface”?

Page 31: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Windows 7(Multi-Touch API)

NativeWin32

Application

Managed WrapperAnd Interop WPF 3.5 SP1

Windows FormsApplication

WPFApplication

SurfaceHardware

WPF 3.5

Surface SDKMulti-Touch Controls

SurfaceApplication

Page 32: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

NativeWin32

Application

Managed WrapperAnd Interop

WPF 4.0Multi-Touch Controls

Windows FormsApplication

WPFApplication

Surface SDKSpecific Controls

SurfaceApplication

Windows 7(Multi-Touch API)

SurfaceHardware

Page 33: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

How about other input mechanisms?

Page 34: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Many other sensors exist today – but

can be difficult…

Page 35: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

e.g. to use a GPS, your application has

to be device specific

Page 36: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

How is this supported?

Page 37: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Windows 7 Sensor and Location

Platform

Page 38: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Sensor Type Sensor Placement Typical Use

GPS Built into, or attached to, computer Location and orientation

Accelerometer Built into computer or attached to computer Motion and orientation

Proximity Built in or nearby to the computer Presence and spatial awareness

Light Built in, nearby, or remote Ambient light conditions

RFID Built into the computer or attached to person Identification of physical items

Compass Attached to person Orientation

Camera Built into the computer or attached Recording, object identification, facial recognition

Microphone Built into the computer or attached Ambient noise conditions

Temperature Built into the computer or remote Indoor/Outdoor Ambient Temperature, cooking temperature

Moisture Remote Detection of water leaks, garden sprinkler systems

Motion Detector Built into the computer or remote Security systems, presense

Traffic Remote, usually public Travel time predictions

Weather station Remote, usually public Weather conditions and predictions

Page 39: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Single API call to answer questions –

e.g. “Where am I?”

Page 40: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

How does this work?

Page 41: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Your Application

Sensor Class Extension

UMDF Sensor Driver

Sensor API

Location API

Sensor Class Extension

UMDF Sensor Driver

Page 42: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

That covers input, but how about

“getting stuff out”?

Page 43: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Vendor Examples of Controls Offered Link

Actipro WPF Studio Ribbon, Bar Code, Wizard, DateTime, Calendar, Transition, Color Selection, Transition Effects Library

http://www.actiprosoftware.com

Blendables Zoombox, ElementSnapshot, Carousel, ChromelessWindow, DragAndDrop, Pie Chart, OS Check, Timeline Panel

http://www.blendables.com

ComponentOne Schedule, Month Calendar, Chart, Grid http://www.componentone.com

DevComponents Office UI, Window Management http://devcomponents.com

Divelements Office UI, Window Management http://divelements.com/

Infragistics Carousel, DataPresenter, Grid, Masked Edit, DateTimeEdit, CurrencyEdit, NumericEdit, CheckEdit, TextEdit, ThemePacks, Chart

http://www.infragistics.com

Mindscape PropertyGrid, TextBoxes, DropDownPickers http://www.mindscape.com.nz

NeoDynamic BarCode http://www.neodynamic.com

Orbifold Diagraming tool http://www.orbifold.com

SoftwareFx Charting http://www.softwarefx.com

SyncFusion Docking, Office UI, GroupBar, Charting http://www.syncfusion.com

Telerik RADControls Suite (Calendar, Carousels, Gauges, etc.) http://www.telerik.com

Xceed Datagrid http://www.xceed.com

Page 44: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Name Type Link

iTextSharp Generate PDF files on the fly http://csharp-source.net/open-source/pdf-libraries/itextsharp

Report.NET PDF document creation from ADO.NET data source http://csharp-source.net/open-source/pdf-libraries/report.net

PDF Sharp PDF creation including GDI+ like drawing routines http://csharp-source.net/open-source/pdf-libraries/pdfsharp

SharpPDF PDF creation for .NET 1.1 http://csharp-source.net/open-source/pdf-libraries/sharppdf

PDFjet Dynamic PDF generation from Java or .NET http://csharp-source.net/open-source/pdf-libraries/pdfjet-open-source-edition

ASP.NET FO PDF Similar to ASP.NET Server Controls, written in C# http://csharp-source.net/open-source/pdf-libraries/asp.net-fo-pdf

PDF Clown C# 2.0 library for reading, writing PDF files http://csharp-source.net/open-source/pdf-libraries/pdf-clown

Page 45: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

But, what if I want to create Office

documents?

Page 46: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

“Old way” is to use the

Application Object Model

Page 47: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

…but:

Need local copy of Office installed on server…Does not scale…

Try running automation on 100s of documents…Dialog boxes “stop” automation…

Have to reboot application on server every X hours…

Page 48: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Open XML SDK 2.0

Page 49: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

How does the Open XML SDK work?

Page 50: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

MyDoc.docx

Users see a single file

Developers see azip file with XML parts

File Container

Document properties

Comments

WordML/SpreadsheetML/etc.

Custom Defined XML

Images, video, sounds

Styles

Charts

Page 51: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Demo - Using OpenXML SDK to read/write Word Documents

Page 52: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Talking about speeding things up…

How about the processor?

Page 53: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Intel Developer Forum, Spring 2004 - Pat Gelsinger

Pow

er D

ensi

ty (

W/c

m2)

1

10

100

1,000

10,000

‘70 ‘80 ‘90 ‘00 ‘10

8008

8080

8086

286

386

486

Hot Plate

Nuclear Reactor

Rocket Nozzle

Sun’s Surface

Page 54: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Isn’t developing parallel applications

difficult?

Page 55: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Getting easier, especially with

.NET 4.0 and Visual Studio 2010

Page 56: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Operating System

Threads

Thread Pool(Task Scheduler and Resource Manager)

Concurrency Runtime

Task Parallel Library

PLINQ

Parallel Debugger

ProfilerConcurrency

Analysis

Page 57: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

PLINQData Partitioning, Operator Types, Merging

Task Parallel LibraryLoop replacements, Imperative Task Parallelism, Scheduling

Concurrency RuntimeThread-safe Collections, Synchronization Types, Coordination Types

Page 58: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

Demo - Running the Open SDK across multiple cores

Page 59: Next Generation LOB (Line of Business) Applications

InteractiveEntering data and getting results

What do we take away from this

section?

Page 60: Next Generation LOB (Line of Business) Applications

InteractiveTakeaways

NUI is, and will, enhance LOB

applications

Getting results and reports is

becoming easier

Taking advantage of multi-core is

within reach

Page 61: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Page 62: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

With my old application, testing was

“giving the application to the user”

Back to 1994

Page 63: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Increased focus on test driven

development (TDD) and unit testing

Since then...

Page 64: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

What am I excited about now?

A renewed effort on making UIs more

composable and testable

How about now?

Page 65: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Hasn’t it been difficult to test the UI?

Page 66: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Patterns, such as MVC, help address

these concerns

Page 67: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

But what should I use?

MVC, MVP, PM, MVVM?

Page 68: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

MVC - Designed to separate concerns

for request/response type UIs

Page 69: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Model

View

ControllerPlease add a new customer…

Add a new customer to the model

Triggers update of the view

ControllerReloadsView

MVC (Model View Controller)

Page 70: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

MVC is a great pattern for Web

Applications

Page 71: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ModelAdd a new customer

to the model

View

Reads number of customers

ControllerReloadsView

MVC (Model View Controller)

ControllerPlease add a new customer…

http://localhost/customer/add (POST)

“Done - you now have 20 customers”

Page 72: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ASP.NET MVC

Does not use ViewState or Server Based Forms

Extendable Front Controller pattern

Project Support for TDD

Page 73: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ASP.NET Web Forms

ViewState to persist state across many components

Page Controller Pattern

Less complex, but more difficult to test

Page 74: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Windows applications are less about

request/response, and more interactive

Page 75: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ModelPresenterView

Request FromView

MVP (Model View Presenter)

Please add a new customer…

PresenterUpdatesModel

ModelConfirmsChange

PresenterUpdates

View

Page 76: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Modified version of MVP (Fowler) to

handle data binding and code behind

Page 77: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

PM (PresentationModel)

ViewPlease add a new customer…

PresentationModel

Request FromView

Model

PresenterUpdatesModel

ModelConfirmsChange

DataBinding

Page 78: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

MVP and PM are patterns that can be

used with Windows Forms, WPF, and

Silverlight

Page 79: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

PM (PresentationModel)

PresentationModel

Request FromView

Model

PresenterUpdatesModel

ModelConfirmsChange

DataBinding

ViewPlease add a new customer…

Fill out fields and click on “Add” button

Data Driven field for # of customersnow in system

Page 80: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

However, XAML also supports any item

to be data bound to any other item in

either direction

Page 81: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ObjectXAML

Events in XAML bound to objects (vs. having code behind)

e.g. button binds to object.add()

Objects bind to XAML visual elements

e.g. object.customername binds to XAML Editbox

Page 82: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

ModelViewModelViewPlease add a new customer…

DataBinding

MVVM (Model View ViewModel)

ViewModelUpdatesModel

ModelConfirmsChange

Page 83: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

MVVM can be realized in WPF and

Silverlight through PRISM

Page 84: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Host

ShellPresenterRegion

Shell

Modules

View ViewModel

Model

ModuleShared Styles / Themes

Styles / Themes

Valid

atio

n

Page 85: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

You mention WPF and Silverlight?

What’s new when it comes to LOB

applications?

Page 86: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

WPF 4.0

Windows 7 Support MultiTouch, Taskbar, DWrite

Fundamentals Full trust XBAP, text rendering, data binding for DynamicObject,

WPF Ribbon controls

Design ExperienceImproved in Visual Studio and lessons learned from implementing

Visual Studio in WPF

Page 87: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

Silverlight 3.0

RIA Productivity

Improved controls, SEO enhancements, accessibility

Out of Browser

Both Win and Mac, isolated storage, auto update

Design Tooling

Expression Blend, SketchFlow, TFS integration, sample

data

Page 88: Next Generation LOB (Line of Business) Applications

ComposableDesigning and composing the user interface

What do we take away from this

section?

Page 89: Next Generation LOB (Line of Business) Applications

ComposableTakeaways

Put some time in learning MVC, MVP,

PM, MVVM

MVVM can be implemented in

Silverlight and WPF using PRISM

New features such as Silverlight

OOB for LOB applications

Page 90: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Page 91: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Accessing data was Direct SQL into a

Dbase/Paradox DB

Back to 1994

Page 92: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

A million different ORMs, DALs, DTOs,

and other ways to access data

Since then...

Page 93: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

What am I excited about now?

Data Access becoming a more integral

part of the application

How about now?

Page 94: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

What do you mean “integral”?

Page 95: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

LinqToSQL (a.k.a. L2S)

Page 96: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Objects(Classes) Database

GenerateIEnumerable

ClassesUsing

Designer

TakeExistingSchema

Page 97: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

DataClasses1DataContext ctx = new DataClasses1DataContext();

var customerNames = from c in ctx.Customersselect c.ContactName;

foreach (string name in customerNames){…}

Page 98: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

DataClasses1DataContext ctx = new DataClasses1DataContext();

var customerNames = from c in ctx.Customerswhere c.ContactName.StartsWith(“A”)select c.ContactName;

foreach (string name in customerNames){…}

Page 99: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

DataClasses1DataContext ctx = new DataClasses1DataContext();

var customerNames = from c in ctx.Customerswhere c.ContactName.StartsWith(“A”)orderby c.ContactNameselect c.ContactName;

foreach (string name in customerNames){…}

Page 100: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

DataClasses1DataContext ctx = new DataClasses1DataContext();

var customerNames = (from c in ctx.Customerswhere c.ContactName.StartsWith(“A”)orderby c.ContactNameselect c.ContactName).Take(5);

foreach (string name in customerNames){…}

Page 101: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Entity Framework

(introduced in .NET 3.5 SP1)

Page 102: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Model(EDMX) Database

Objects(Classes)

GenerateModelFrom

Database

GenerateObjectsFromModel

TakeExistingSchema

Database First Entity Creation

Page 103: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Wasn’t there some

“constructive feedback” on EF?

Page 104: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

What did we hear?

Persistence Ignorance

N-Tier

Developer Friction

Page 105: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

New for EF 4.0

Automatic Pluralization

Based on API

T4 Template Generation

Instead of CodeDom

3 Ways of Thinking of ORM

Database first, model first, code only

Page 106: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Objects(Classes)

GenerateObjectsFromModel

Database First Entity Creation

Model(EDMX)

GenerateModelFrom

Database

Database

TakeExistingSchema

Start Here!

Page 107: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Objects(Classes)

GenerateObjectsFromModel

Database

GenerateSchemaFromModel

Model First Entity Creation

Model(EDMX)

CreateModelUsing

Designer

Start Here!

Page 108: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Model(EDMX)

CreateModelFrom

Objects

Database

GenerateSchemaFromModel

Code Only Entity Creation

Objects(Classes)

WriteObjects

Start Here!

Page 109: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Demo - Code First Approach in EF 4.0

Page 110: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

I understand, but how do I pass that

data across tiers?

Page 111: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

ADO.NET Data Services

(formerly known as Astoria)

Page 112: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Model

REST endpoint exposed over model

ADO.NET Data Services

ATOM/JSON consumer Your Application …

Database

Page 113: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Great for exposing data models to a

variety of clients

Page 114: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

I’m fed up of writing plumbing code.

What’s new here?

Page 115: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

.NET RIA Services

Page 116: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Goal: To boost productivity for

developers looking to build RIA

applications

Page 117: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Model

.NET RIA Services

Expose Data Across Tier

Your Silverlight Application

Database

Consume Data Across Tier

Is this the most productiveuse of your time?

Page 118: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Single solution to remove effort to

write an n-tier application.

Object lifecycle, data validation,

authentication.

Page 119: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

Demo - .NET RIA Services

Page 120: Next Generation LOB (Line of Business) Applications

Data DrivenObject relational mapping and exposing across tiers

What do we take away from this

section?

Page 121: Next Generation LOB (Line of Business) Applications

Data DrivenTakeaways

Is your LOB application truly data

driven? Is data access integral?

How are you exposing data across

an n-tier application?

What frameworks exist that help

abstract the “plumbing” for this?

Page 122: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Page 123: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

“Integration” was an RS-232 serial port

to a MPR, into a VMS system!

Back to 1994

Page 124: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

…and no need to consider external

access!

Back to 1994

Page 125: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

RMI, CORBA, DCOM, .NET Remoting,

Web Services, BizTalk Adapters, ESBs,

Sharepoint’s BDC

Since then...

Page 126: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

What am I excited about now?

Everything coming together in WCF 4.0

How about now?

Page 127: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Wait a minute! WCF is so

complicated!

What’s new that will make life easier?

Page 128: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Default Endpoints

Page 129: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

ServiceHost host = new ServiceHost(typeof(MyService), new Uri(“http://localhost:8080/myservice”));host.AddDefaultEndpoints();host.Open();

Page 130: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Easier Hosting in ASP.NET

Page 131: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

[ServiceContract()]public class Service1{

[OperationContract()]public string SayHello(string name){

return String.Format("Hello {0}", name);}

}

Page 132: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Discovery

Page 133: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

<service name=“HelloService”><endpoint binding=“wsHttpBinding” contract=“IHello”/><endpoint name=“udpDiscovery”

kind=“udpDiscoveryEndpoint”/></service>

Page 134: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

DiscoveryClient client = new DiscoveryClient(“udpDiscoveryEndpoint”);FindCriteria crtieria = new FindCriteria(typeof(IHello));FindResponse response = client.Find(criteria);

Page 135: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Service Announcements

Page 136: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

<serviceDiscovery><announcementEndpoints>

<endpoint kind=“udpAnnouncementEndpoint”/></announcementEndpoints>

</serviceDiscovery>

Page 137: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

AnnouncementService service = new AnnouncementService();service.OnlineAnnouncementRecieved += OnOnlineEvent;service.OfflineAnnouncementRecieved += OnOfflineEvent;

static void OnOnlineEvent(object sender, AnnouncementEventArgs e)

{…}

Page 138: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Managed Discovery

Page 139: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

DiscoveryProxyService

Service

Register Announcement

Service

Client

Probe Proxy Service(FindCriteria)

Call Service

Page 140: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Content Based Routing

Fault Tolerant Routing

Improved REST Support

Better Integrated between WF and WCF

Page 141: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Sounds great. How do I use WCF outside

the walls of the organization?

Page 142: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

.NET Service Bus

Page 143: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client Server

Company 1 Company 2Telco provided WAN

FTPClient

FTPServer

Page 144: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client Server

Company 1 Company 2Telco provided WAN

FTPClient

FTPServer

Internet

Page 145: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client Server

Company 1 Company 2Telco provided WAN

Browser

Internet

ExtranetSite

DMZ

Page 146: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Database

Client

Company 1

Company 2

Web Site

Page 147: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Client

Company 1

Company 2

Firewall

Firewall

Proxy?

DatabaseWeb Site

Page 148: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Client

Company 1

Company 2

Firewall

Firewall

NAT?

65.55.33.204

192.168.14.100

DatabaseWeb Site

Page 149: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Client

Company 1

Company 2

Firewall

Firewall192.168.14.100

OK, so I’ll do a HTTP poll every minute

65.55.33.204

DatabaseWeb Site

Page 150: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Client

Company 1

Company 2

Firewall

Firewall192.168.14.100

…and how about other protocols other than HTTP?

65.55.33.204

DatabaseWeb Site

Page 151: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

How does the .NET Service Bus help?

Page 152: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Outbound bi-directional socketKept alive in background

.NET Service Bus

sb://.../myqueue

Client

Company 1

Company 2

Firewall

Page 153: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Client

Outbound bi-directional socketKept alive in background

.NET Service Bus

sb://.../myqueue

Client

Company 1

Company 2

Firewall

FirewallOutbound one-way socket

Message routedaccordingly

Page 154: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

Demo - Using .NET Service Bus

Page 155: Next Generation LOB (Line of Business) Applications

IntegratedGetting my application to talk nicely with others

What do we take away from this

section?

Page 156: Next Generation LOB (Line of Business) Applications

IntegratedTakeaways

WCF 4.0 provides an easier “on

ramp” compared to previous versions

Discovery and Service

Announcements in WCF

.NET Service Bus will open up new

application types

Page 157: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Page 158: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Adding functionality to my application

required a re-install.

Back to 1994

Page 159: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

…and deploying was a weekend’s worth

of overtime.

Back to 1994

Page 160: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

DI (Dependency Injection)

and IoC (Inversion of Control), different

ways to get bits to the box

Since then...

Page 161: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

What am I excited about now?

MEF and improvements to ClickOnce

How about now?

Page 162: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

What is MEF?

Page 163: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

MEF – Managed Extensibility

Framework

Page 164: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Catalog

CatalogExportProviderCustomExportProvider MutableExportProvider

Composition Container

Part PartPart

ExportsImports

ExportsImports

ExportsImports

Page 165: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

What’s this look like in my app?

Page 166: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

public interface IMessageSender{

void Send(string message); }

Declare the interface for your extension

Page 167: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

[Export(typeof(IMessageSender))] public class EmailSender : IMessageSender{

public void Send(string message) {

Console.WriteLine(message); }

}

Add the Export attribute to your add-in

Page 168: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

private void Compose() {

var catalog = new AssemblyCatalog(Assembly.GetExecutingAssembly()); var container = new CompositionContainer(catalog); container.ComposeParts(this);

}

Create the container in your host application

Page 169: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

[Import]public IMessageSender MessageSender { get; set; }

Import the parts you are going to use

Page 170: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Extensibility is easier, but isn’t

application deployment still painful?

Page 171: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

.NET Framework Size and Reboots

Page 172: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

.NET 4 Client: 28 MB X86 Client Profile, 48MB X86/X64 Full Profile

Size on media combined x86/x64 package

0

50

100

150

200

250

"2.0" "3.0" "3.5" "3.5SP1" "4.0 Full" "4.0 Client"

Size

in M

egab

ytes

Page 173: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Brandable Experience

Page 175: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Improved ClickOnce Experience

Page 176: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Click Once Improvements

–Command-line arguments for CO deployed apps

– File associations for CO deployed apps

–Background Updates for CO apps

Page 177: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

Demo - Updating a ClickOnce Application

Page 178: Next Generation LOB (Line of Business) Applications

ExtensibilityExtending and deploying my application

What do we take away from this

section?

Page 179: Next Generation LOB (Line of Business) Applications

ExtensibilityTakeaways

MEF enables you to think about

extensibility from day one

Client requirements are becoming

less, and ClickOnce improving

Challenge the notion that

deployment is still hard

Page 180: Next Generation LOB (Line of Business) Applications

Call to ActionWhat’s next?

Page 181: Next Generation LOB (Line of Business) Applications

Call to ActionWhat’s next?

Look at your LOB applications using

the 5 characteristics

Don’t be afraid to challenge some

of your assumptions/decisions

Be excited about the potential

coming in the next wave!

Page 182: Next Generation LOB (Line of Business) Applications

[email protected]://simonguest.com

© 2009 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market

conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation.

MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.


Top Related