Moustafa Refaat
Login   Search
Skip Navigation Links
Home
Publications
Service Offerings
Downloads and Samples
My Resume
Endorsements
Contact Me
Books
Technical Articles
Software Packages
Scroll up
Scroll down
BizTalk The Practical Course
Mastering The BizTalk Technical Interview
Soduku:Challenging Puzzels
Scroll up
Scroll down
Design Patterns Review
Software Architecture Basics Review
Simplified BizTalk Content Based Routing for a Pass_Throu data
An Extensible Light Xml Rules Engine Component
Secure Messaging Solution
Create a SQL Database Programmatically
BizTalk Unzip Adapter
Implementing Singleton pattern with BizTalk Orchestrations
Developing BizTalk Custom Adapters
The BizTalk ESB Toolkit 2.0 experience Series
Scroll up
Scroll down
Setting the ESB Toolkit on the 64 Bit Machines
How The ESB Works
Sample Custom Resolver
Scroll up
Scroll down
Recent Training
Scroll up
Scroll down

News List

  • Toronto Code Camp Presentation is uploaded
  • BizTalk: The Practical Course is recommended by Micorsoft
  • Canadian Gigs Network (www.CanadianGigs.Net) a job web site focusing on Canadian Jobs
  • BizTalk Technical Interview Preparation
  • GT-DataSafe© Online Backup for Amazon Storage Services 3.0 is released
  • Soduku Challenging Puzzles
  • BizTalk: The Practical Course
  • Mastering The BizTalk Technical Interview is Published.

Technical Articles

  • SharePoint List Simplified Configuration Store
  • WCF and xsd:choice how to implement!
  • WCF: Refactoring a Plain old XML web service to a WCF Service
  • Setting the ESB Toolkit on the 64 Bit Machines
  • The BizTalk ESB Toolkit 2.0 experience Series
Skip Navigation Links
> Blog entries about: EAI
WCF and xsd:choice how to implement!
For some reason Microsoft decided that WCF serialization is not going to support the xsd:choice. The .Net XML serialization does support xsd:choice which is important. Now, if you had a schema that used xsd:Choice and used XSD tool to generate classes for it will generate code similar to:
///<remarks/>
    [System.Xml.Serialization.XmlElementAttribute("Option1", typeof(typeOption11), Form=System.Xml.Schema.XmlSchemaForm.Unqualified)]
    [System.Xml.Serialization.XmlElementAttribute("Option2", typeof(typeOption2), Form=System.Xml.Schema.XmlSchemaForm.Unqualified)]
    [System.Xml.Serialization.XmlElementAttribute("Option3", typeof(typeOption3), Form=System.Xml.Schema.XmlSchemaForm.Unqualified)]
    public object Item {
        get {
            return this.itemField;
        }
        set {
            this.itemField = value;
        }
Well that is look neat does not it? Now if you exposed this same generated code through WCF, the WSDL would generate item as Object on the client side and the consumer would not get any information from the WSDL about typeOption1, typeOption2, nor typeOption3. That is a real pain for the developer on the consumer side!. So one workaround that I had to device for a solution I was developing is to create another class like the following
public partial class Optionss {
 
    [System.Xml.Serialization.XmlElementAttribute("Option1", typeof(typeOption1), Form=System.Xml.Schema.XmlSchemaForm.Unqualified,IsNullable = true)]
    public typeOption1 Option1 = null;
    [System.Xml.Serialization.XmlElementAttribute("Optoin2", typeof(typeOption2), Form=System.Xml.Schema.XmlSchemaForm.Unqualified,IsNullable = true)]
    public typeOption2 Option2 = null;
    [System.Xml.Serialization.XmlElementAttribute("Option3", typeof(typeOption3), Form=System.Xml.Schema.XmlSchemaForm.Unqualified,IsNullable = true)]
    public typeOption3 Option3 = null;
 
}
And chenage the item above to be similar to
    public Optionss Item {
        get {
            return this.itemField;
        }
        set {
            this.itemField = value;
        }
 
Now the options are going to appear to the consumer, however the data you receive is going to be for a different schema so I wrote code that would serialize the received request then “fix” the XML to be corresponding to the actual schema with xsd:choice.  Not quite neat  workaround but it works.
{06/08/2010 2:21 PM} {0 comments}  {Tags: EAI, WCF, Web Developmenet}
The BizTalk ESB Toolkit 2.0 experience Series
In this series of blogs I will explain and discuss my experience with the MS ESB Tool kit for BizTalk 2009.  The BizTalk ESB Toolkit 2.0 is a collection of tools and libraries that extend BizTalk Server capabilities of supporting a loosely coupled and dynamic messaging architecture.  The two most valuable features of the toolkit are:
·        The Itinerary capabilities which allows you to implement a simple chain of actions on a message path (these actions can be running BizTalk maps, BizTalk Orchestration, or custom .Net code).
·        The Management portal sample  which allows you to view suspended messages and control other aspects of BizTalk and the ESB
The following figure for Microsoft shows the components of the BizTalk ESB Toolkit 2.0
 
Read more..
{08/05/2010 10:58 AM} {0 comments}  {Tags: Architecture, BizTalk, EAI, ESB Toolkit}
An Extensible Light Xml Rules Engine Component
 The Extensible light XML rules engine component allows the easy configuration of rules in XML, definition of the interpretations of rules and the actions to be taken by client code. Though the component idea is simple its extensibility and completeness makes it worth of reuse. The component is developed in C# and .Net framework.  Read more..
{10/01/2009 1:25 PM} {0 comments}  {Tags: Architecture, EAI, Exception Management, Security, Busienss Rules}
Software Architecture Basics Review
Software architecture involves the integration of software development methodologies and models, which distinguishes it from particular analysis and design methodologies. The structure of complex software solutions departs from the description of the problem, adding to the complexity of software development. Software architecture is a body of methods and techniques that helps us to manage the complexities of software development.
Software architecture presents a view of a software system as components and connectors. Components encapsulate some coherent set of functionality. Connectors realize the runtime interaction between components. The system design achieves certain qualities based on its composition from components and connectors. Software architecture design is not entirely different from existing software design methodologies. Rather it complements them with additional views of a system that have not been traditionally handled by methodologies like object-oriented design.  read more ... http://www.moustafarefaat.com/MoustafaPWS/softarcreview.aspx
 
{09/11/2005 11:02 AM} {0 comments}  {Tags: Architecture, EAI}
Design for Integration
I have designed many enterprise integration applications, Most of the challenges that I face stem from the fact that the application was designed without consideration for making the application capable of supporting integration.

Integration has consistently ranked as a top concern of IT executives for the last several years. But integration is a multi-faceted problem, so this challenge is looking at integration specifically from the perspective of the application architecture.

An organization can have the entire integration infrastructure in the world, including various networks, EAI middleware, integration server products, messaging systems, etc. However, the rubber meets the road when it comes time to connect that integration infrastructure to your application. If application architecture is closed and offers no way of interfacing with any of that integration infrastructure, then you have an application that you cannot integrate with.

So the question is, how can you ensure your application architecture is integration capable so it is possible for it to be integrated with other systems?
 
But why do designers design closed applications in the first place?
  • This problem often shows up simply because it isn’t a requirement when a new application is built. Naturally a new application might depend on other existing applications and so needs to call out into them, but typically a new application does not initially have some other application that is dependent on the new one and needs to call into it. So because it isn’t a requirement, the architecture design does not include support for it.
  • However, in large organizations there really are only a small percentage of applications that go through their entire lifecycle without at some point needing to be integrated with other applications. So this requirement always seems to come up sometime after your new application is deployed. So you could at that point modify the architecture of your application to support being integrated with, but often that is unlikely to happen because the new requirement is coming from a need in another application, and there is no budget or permission at that time to significantly modify your application to support the needs of the other application.
  •  The classic solutions in these cases are to try integrating either through screen scraping or data integration, but both techniques are awkward, expensive, and difficult to maintain and so customers normally want to avoid those approaches if possible.
 
You can solve the Integration problem:
  • Ensure that there is an explicit business tier with a cleanly separated API.
  • Ensuring the business tier is exposed by some technology that can be accessed by external systems is necessary.
  • Include an interception mechanism that can raise business events after certain things occur. Sometimes external systems might need to know when things are occurring in your system, and providing business events makes it possible to support that without requiring that external systems to poll your system through the business API.
  • Use a pub/sub mechanism with the business events. This way, systems can be added or removed which respond to the business events without your application needing to know. If they were calling into your business API, the performance impacts might be enough that you need to be aware of that usage, but a business event doesn’t affect your system based on how it is used.
{09/05/2005 5:23 AM} {0 comments}  {Tags: Architecture, EAI}

Copyright © Moustafa Refaat 2004 - 2009. All Rights Reserved.