louis maresca software development engineer microsoft corporation gp15

28
Understanding Web Services for Microsoft Dynamics GP Louis Maresca Software Development Engineer Microsoft Corporation GP15

Upload: carla-hunn

Post on 31-Mar-2015

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Understanding Web Services for Microsoft Dynamics GP

Louis MarescaSoftware Development EngineerMicrosoft Corporation

GP15

Page 2: Louis Maresca Software Development Engineer Microsoft Corporation GP15

What is This Session All About?“Explore the basics of Web Services for

Microsoft Dynamics GP as we review when and how to leverage this technology. “

“We'll demonstrate how to fully utilize Web Services and you'll walk away with insight and knowledge into how this technology translates into greater opportunities for your organization. “

Page 3: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Have You Used It?

How many of you are coders? (implementers?)How many are you are PM’s?Who has used Web Services (in general)?Who has used GP Web Services before?

Page 4: Louis Maresca Software Development Engineer Microsoft Corporation GP15

GP15: Agenda

What is GP Web Services?How to use Web Services?

Some Code… ahhh!ExamplesBest Practices

Page 5: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Terminology

WSDL: Web Service Description LanguageSOAP: Simple Object Access ProtocolProxy: Service Proxy ObjectASMX: Web Service PageDecoupledLoosely Typed – Strongly Typed

Page 6: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Dynamics GP Services Growth2005-2006

2007-2008

2009

Created – 200 Operations

100 Additional Operations

GP 11…Even more!

SOURCE: FORRESTER

Page 7: Louis Maresca Software Development Engineer Microsoft Corporation GP15

What is GP Web Services?

Do you understand the GP Data Model?

Tables|Fields|Relations?WS is a way to talk to GP with out having to understand the BackEnd.Lets Hide\Encapsulate all the complex stuff and talk to something descriptive

(human readable!!)

Page 8: Louis Maresca Software Development Engineer Microsoft Corporation GP15

GP Web Services

Workflow

Business Portal

BDC / Search

GP Web Services-Installs to IIS server, and to SQL server. -Consoles can be installed on any machine that can talk to IIS.-Dependency is on

- eConnect: It needs access to API through COM+, and stored procedures.

- IIS- ADAM/Azman for security

Workflow-Installs to MOSS/IIS Server -Dependency on GP Web Services and Windows Workflow

GP BDC – Search (Office 12)

-Installs to MOSS/IIS Server and to SQL server-Dependency is on

- GP Web Services

Business Portal-Installs to IIS and SQL server-Dependency is on

- GP Web Services- eConnect- MBF- MOSS- WSS

CRM Integration-Dependency is on: GP Web Services

PortalsCRM

Integration

Dynamics Mobility Server

Page 9: Louis Maresca Software Development Engineer Microsoft Corporation GP15

It's an Onion! LAYERS!

Web Service Layer

SecurityBusiness Logic Layer

Data Access Layer

Page 10: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Web Service Layer

What can the service do?Contract

300+ OperationsStandard Naming Convention

Get’BusinessObject’ByListGet’BusinessObject’ByKeyCreate’BusinessObject’Delete’BusinessObject’Void’BusinessObject’

Strongly typedDescriptive ‘things’ that are returned (objects) rather than TEXT (xml)

Returns

Customer

Page 11: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Inheritance Diagram

BusinessObject

Employee Customer Item Project

GLTransaction

SalesTransaction PurchaseOrder

Page 12: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Inheritance Model Cont…AddressBase(BusinessObject)

Address(AddressBase)

ServiceEquipmentAddress

ServiceAddress

International

Address

ReturnMa…ReturnReturnMa…Ship

ServiceCallShipToAddress

BusinessAddress

(InternationalAdd..)

ExtendedBsinessAddressConstituentAddre

ss

CustomerAddress

Page 13: Louis Maresca Software Development Engineer Microsoft Corporation GP15

How Does It Work?

IISRequest

Response

ServiceProxy Request

Service WSDL(Description)

CustomerFOO

Get Me A Customer by it’s ID

(GetCustomerByKey)

Page 14: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Business Logic Layer

SQL

Security Subsystem

Policy Subsystem

Exception Subsystem

Create/Update/Delete

Get / GetList

IIS Service

Page 15: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Dynamics GP Security

Role BasedWhat Operations belong to that Role?What Tasks Belong to those operations?(e.g., Sales Person)What do can you see?

Security Subsystem

Page 16: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Customized Data Based on Roles

You are a SalesPerson and you are assigned to a set of customersGetList (basedonCustomerId) returns only the customers you are assigned

Page 17: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Dynamics GP Policies

What is a Policy?Internal Policies

e.g., Force Credit Limit(s)External Policies

e.g., Create a customer with a default Class ID

Role BasedEach role can have a different set of policies.

Page 18: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Exception SubSystem

There is an error…Is it safe to send back the details?!

Not necessarily!We return a “error”, but to see all of the data, information behind the issue, you can retrieve it from the Exception ServiceExpose Exception Method

Page 19: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Data Access Layer

We talk to the Back Office For you…Business Logic/ Validation is done against the data, and performed automaticallyThis is the “magic” layer for you…

Page 20: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Using GP Web Services…

1) Create a Proxy, or use the shipped one

2) Generate a Context3) Decide, from the Proxy, What Web

Operation you are calling4) Build up your operation call using

strongly typed objects in the interface

Page 21: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Proxy-Up The Service…

DynamicsGP clientProxy = new DynamicsGP()That’s IT!Is this slow for you?

Why is it slow sometimes?!!!!![Best Practice]

What happens underneath?Do you really want to know?

Thinning the contract…

Page 22: Louis Maresca Software Development Engineer Microsoft Corporation GP15

ASMX Can Be Customized!

How?!Create a new ASMX, point it to our assemblyThat’s it!Want a demo?

Page 23: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Context Type

PropertiesOrganization KeyCultureNameCurrencyRole KeyWorkOnBehalfOfa

Page 24: Louis Maresca Software Development Engineer Microsoft Corporation GP15

What Operation Do You Like?

The Service Contract exposes various CRUD operations that include additional GP Specific operations

Get_ : Retrieves individual DocumentsGetList_ : Returns a Collection of objectsCreate_ : Creates new documentUpdate_ : Updates an existing documentDelete_ : Deletes an existing documentVoid_ : Voids an existing transactions

300+ Web Operations

Page 25: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Service Demo…Let me see this!

Quick…

Page 26: Louis Maresca Software Development Engineer Microsoft Corporation GP15

Please Complete an Evaluation FormYour feedback is important!

Two ways to access online evaluation formsCommNet and evaluation stations located throughout the New Orleans Morial Convention CenterFrom any wired or wireless connection to www.msconvergence.com/home.aspx

For more information please refer to your Conference GuideNote: For every attendee who completes an evaluation, Convergence will

donate $1 to the Boys & Girls Club of Southeast Louisiana

Be eligible to win great daily prizes and the

grand prize – a $5,000 Travel Voucher!

Page 27: Louis Maresca Software Development Engineer Microsoft Corporation GP15

© 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.

Page 28: Louis Maresca Software Development Engineer Microsoft Corporation GP15