Duet: An Enterprise S+S Offering From Microsoft And SAP

Architecture, Duet, SAP December 12th, 2007

The Strategic Architect Forum (SAF) conference was hosted at the Microsoft Conference Center in Redmond over three days during November 2007. All the keynotes and informational sessions are available for download at the SAF recorded sessions site.

Be sure to check out the Duet: An Enterprise S+S Offering From Microsoft And SAP session”:

Duet: An Enterprise S+S Offering From Microsoft And SAP
Chris Keyser (Microsoft)
Burra Gopal (Microsoft)
Adi Kavaler (SAP)

[Video] . [Slides] . [Transcript]

Other topics include:

  • Changing the World with Software and Services
  • Project Astoria: Data Services for the Web
  • Anatomy of An S+S Application
  • Unified Communications: Breaking VoIP Barriers
  • Composite Application Architectures Using the 2007 Office System
  • A Data-driven Approach To Distributed, Concurrent Software
  • A Look Into Microsoft Research
  • Claims-Based Identity Layer For The “New Internet”
  • The Reality Of The Cloud And The Future Of The Datacenter
  • Mining Lightning For The Cloud
  • User Experience for Architects
  • Windows Live Platform: Making Better End User Experiences
  • Dynamic IT
  • Amazon.com’s Simple Storage Service, Elastic Compute Cloud, and Simple Queue Service
  • Lessons Learned from the Web’s Edge: MySpace
  • Leading Geeks: How to Manage and Lead People Who Deliver Technology
  • Tags: , ,

    Duet Behind the Scenes: Bounded Items

    Duet, Microsoft, SAP July 18th, 2007

    Binding to Outlook item (Mail, Task, Contact, etc.) is one of the main features that differentiates Duet’s user experience from other OBA products such as Snap-Ins, Extensio etc. What exactly are bounded items? and how is binding implemented?

    What are Bounded Items?

    A bounded item is a simple Outlook item, which can be an email, appointment, contact etc. with an attached schema that defines it as a specific presentation object (presentation objects discussed in the previous post) and carries the business data related to that object. We call this a payload.

    The payload is an encrypted XML containing the presentation object reference and business data mentioned above and attached to the Outlook item as a custom property.

    For example, a payload attached to a contact item that represents a CRM customer would probably contain data such as the customer’s ID, company he works at, etc.

    Before we examine how this payload is built, maintained and displayed to the user we first have to take a step back and understand how its schema defined. Or to be more accurate, how we define a presentation object.

    Bound Item Definitions

    If you remember the metadata illustration from the first post, one of the key parts in a presentation object’s metadata definition is its Data Definitions as displayed in the illustration:

     image

    A presentation item’s Data Definitions contain the following information:

    1. Presentation object name- A unique resource name identifying this presentation object type
    2. Outlook definitions -Specifies the Outlook item type this objects relates to and its default folder location.
    3. Synchronization behavior - Type of synchronization used to synchronize to the backend.
    4. Business Data Schema - A schema for the business data this object carries with it
    5. Data Mapping to\from Outlook Properties - A set of mappings that define how the Outlook item’s default fields (Such as Subject, Location, Start\End Time) map to\from values in the item’s business data.

    If we look at a definition for a CRM Customer object again, its name would be something like "urn:sap:duet:crm:customer" and its business data would probably contain name and contact information (address, phone numbers). This data would be mapped to the relevant Outlook fields (phone numbers to Contact item phone properties, address to the Contact item address property etc.) so that when the user edits the object the changes will be propagated back to the business data payload (and eventually to the backend).

    This data definition, termed Bound Item Definition looks like this:

    <BoundItemDefinition Name="urn:sap:duet:crm:customer" xmlns="http://schemas.microsoft.com/OBA/2005/BoundItemDefinition">
      <Outlook DefaultFolder="CRM Contacts" MessageClass="IPM.Contact" />
      <Synchronization>
        <Behavior>Always</Behavior>
      </Synchronization>
      <Properties>
        <Property Name="Crm.Customer.FirstName" Type="String">
          <Behavior>OutlookToXml</Behavior>
          <Outlook Name="FirstName" />
          <Xml XPath="/ns0:CRMContact/Name" Namespaces="ns0='urn:sap:duet:crm:customer'" />
        </Property> <Property Name="Crm.Customer.LastName" Type="String">
          <Behavior>OutlookToXml</Behavior>
          <Outlook Name="LastName" />
          <Xml XPath="/ns0:CRMContact/ns0:LastName" Namespaces="ns0='urn:sap:duet:crm:customer'" />
        </Property>
        ...
      </Properties>
      <XmlTemplate>
        <s0:CRMContact xmlns:s0="urn:sap:duet:crm:customer">
          <s0:FirstName>String</s0:FirstName> <s0:LastName>String</s0:LastName> <s0:FileAsName>String</s0:FileAsName> <s0:Comapany>String</s0:Comapany> <s0:JobTitle>String</s0:JobTitle>  ...
        </s0:CRMContact>
      </XmlTemplate>
    </BoundItemDefinition>

    Binding an Item

    The process of binding an item is where we take a regular Outlook item and mark it has a presentation object. Basically we’re taking a regular Outlook item and marking it as a presentation object. The item’s behavior and schema for the business data attached to it are according to the presentation object’s data definitions. When binding an item the Duet platform adds 3 custom properties to the item:

    1. BoundItemId - A unique ID to represent this bounded item.
    2. BoundItemType - The type of presentation object that the item represents
    3. BoundData - The business data the item carries (payload).

    In our example, a bounded IPM.Contact object representing a customer would have urn:sap:duet:crm:customerIn as its BoundItemType and the following XML as its BoundData:

    <s0:CRMContact xmlns:s0="urn:sap:duet:crm:customer">
      <s0:FirstName>Eran</s0:FirstName>
      <s0:LastName>Kampf</s0:LastName>
      <s0:FileAsName>Kampf, Eran</s0:FileAsName>
      <s0:Comapany>SAP Labs Israel</s0:Comapany>
      ...
    </s0:CRMContact>

    The values in the BoundData are populated according to the data mapping rules specified in the bound item definition for our customer object.

    Security Considerations

    The BoundData can contain confidential information. Once retrieved from the backend systems we would like to limit access to it specifically to the user who got the information. Otherwise, sensitive information which is part of the user’s item can leek if, for example the user forwards the item to someone or if an IT administrator (or anyone else who has access to the user’s mailbox) looks at the item.

    We use DPAPI to encrypt the BoundData using the current user’s credentials so that only the Duet user who received the data can decrypt it. This way, even if someone else gets hold of the BoundData value he has no way to decipher it…

    This also means that when forwarding a Duet item the receiving side will not have Duet information available and will see the item as a regular unbounded Outlook item. I’ll discuss how forwarding of bounded items is performed in a future post dedicated to forwarding…

    kick it on DotNetKicks.com

    Tags: , , , , , , ,

    Duet Behind the Scenes: Metadata Driven Solutions

    Duet, SAP July 2nd, 2007

    The Duet applications are built using metadata definitions that are interpreted during runtime and drive the different application’s workflow and UI.
    How is Duet’s metadata defined and used? What are the advantages of this model? image

    Presentation Objects

    The Duet metadata defines business objects and how they interact with the user and the backend system. I like to refer to such objects as “presentations objects” because unlike the backend Business Objects that make sense to backend developers these are objects that make sense to the user.
    For example, information about a person’s salary, compensation and HR information may be represented as several different business objects on the backend (or on several backend systems, maybe even from different vendors). The end-user, looking at a contact information on his Outlook doesn’t have to know about all the different backend and business objects that were used to aggregate the information on his screen.

    Therefore, the Duet metadata defines such presentation objects - the information they carry, how this information is aggregated to and from the backend system(s)and how they interact with the user in his Office environment. So, from an abstract point of view, an application’s metadata structure is somewhat similar to this:

    image

    DuetML

    All the UI components in Duet are defined by a markup language - DuetML. Each UI component displayed to the user is actually represented by an XML defining the UI and a .NET assembly codebehind defining the logic behind the UI. Basically this mechanism is a lot like WPF’s XAML but with several key differences:

    1. DuetML is based on top of WinForms and has very limited UI capabilities specifically designed for Duet’s UI screens
    2. XAML gets compiled (to BAML) during design time while DuetML is interpreted during runtime.
      This gives us a lot of customization & translation capabilities on the server where we process the DuetMLs before sending them to the user (I will probably have to dedicate a whole post specifically to discuss business customization and localization)

    In fact, DuetML’s schema was designed to closely resembles XAML to allow transition to XAML in the future…

    So, Why Use Metadata?

    Simplified solution development. The metadata-based architecture makes it possible to develop declarative business solutions. Because solutions are defined in metadata, developers can build simple, powerful solutions with little or no coding using pre-made common solution building blocks. Advanced developers can use .NET further customize their applications and add new features.

    Centralized deployment. In order to run Duet solutions all the clients need is the Duet runtime which is a generic add-in that runs inside the Office applications and can load and interpret the metadata fetched from the server. The different solutions are deployed on a central server and do not require additional installations on the client.

    Enhanced customization capabilities. Declarative approach also allows enhanced customization capabilities as customizing the application simply means editing its metadata. Duet’s ACE (Application Configuration Environment) goes a step further by allowing providing a configuration environment that allows the business administrator to apply such changes without requiring knowledge about the metadata and code behind a solution.

    Automatic generation and modeling. A declarative approach for defining solution is the basis for enabling modeling and automatic generation of solutions. Imagine that you could quickly select some objects from the backend, define the matching object in Outlook and the data you wish to see and a solution will automatically be generated for you? And imagine you could customize such a solution using a visual programming tool such as Visual Composer (Microsoft Popfly, Yahoo Pipes style of development for you non SAPers)

    Tags: , , , , , , ,

    Duet Behind the Scenes

    Duet, SAP May 4th, 2006

    And now, the Duettm architecture as you’ve never seen it before (drawn by an unknown artist):

    Duet Architecture

    Artistic isn’t it?

    On the next few weeks I’ll try to create a series of posts regarding the design and architecture of Duettm .
    In the meantime, some quick facts from behind the scenes:

    • The Duettm client is built using the .NET 2.0 framework and an enhanced version of Microsoft Information Bridge Framework (IBF).
    • The first version of Duettm concentrates on scenarios in the Outlook environment.
    • Duettm is a joint effort with Microsoft and SAP and was developed by teams at 6 different worldwide locations.

    If you have any technical question or specific areas you would like to hear about in future posts feel free to let me know…

    Tags: , , , , , ,