Extending ESB Guidance

%u00b7         Blogical.Adapter.SQL – Download

%u00b7         Blogical.Adapter.SMTP – Download

%u00b7         Blogical.Resolver.LDAP – Download

%u00b7         Blogical.Resolver.SQL – Download

Adapter Provider Framework
After a resolver executes, the dynamic resolution service checks whether the result is an endpoint (not a transformation). If it is an endpoint, the service instantiates the adapter manager, which validates and fixes the transport type and the outbound transport location.
The adapter manager uses the suffix stated in the transport location (eg FTP://) to determine the appropriate adapter provider. An adapter provider is a custom assembly that must implement the IAdapterProvider interface. The adapter provider uses the properties of the Resolution structure within the Dictionary instance generated by the resolver to set all the protocol-specific properties of the message that enable the BizTalk run-time engine to perform dynamic resolution.

The Resolver Framework
The itinerary describes a composition of services to be executed, such as transformation, routing and dynamic end-point resolution. Each of which works with a set of resolvers, that will provide the necessary input for that service or endpoint. Which resolver to be used is described by a moniker Eg UDDI://.
A resolver takes the resolver connection string, validates it, and uses the result to query and populate a Dictionary object that Adapter Providers and Services can use.

SQL Adapter provider

The integrated SQL adapter, which ships with BizTalk Server, is designed for sharing data between BizTalk Server and Microsoft SQL Server databases. The Blogical.Adapter.SQL adapter provider reads the Resolver.EndpointConfig property from the chosen resolver and sets the necessary context properties for SQL adapter.

Resolver configuration sample:

<Resolvers serviceId="DynamicTest0">
&lt;![CDATA[STATIC:\\TransportLocation=SQL://;EndpointConfig=
IntegratedSecurity=SSPI&amp;
PersistSecurityInfo=False&amp;
InitialCatalog=EsbAdmin&amp;
DataSource=localhost&amp;
DocumentTargetNameSpace=http://SQLSendProject1=&amp;
ResponseDocumentRootElementName=PersonResponse;]]&gt;</Resolvers>

 

Machine.Config settings:

<add key="SQL"
         value="Blogical.Adapter.SQL,
         Version=1.0.0.0, Culture=neutral,
         PublicKeyToken=c2c8b2b87f54180a" />

 

Supported Resolvers: STATIC, BRE

 

SMTP Adapter provider
BizTalk Server can send messages to other applications by creating an e-mail message and delivering it to a specified e-mail address. One often mentioned problem, when using the SMTP adapter, is that the To address property makes up the actual send port uri and is there for not be dynamically set if you’d like to send (route) different messages to different users. This issue can be solved by using a dynamic send port and set the SMTP properties at runtime.  The Blogical.Adapter.SMTP adapter takes on the very same approach and reads the Resolver.TransportLocation and the Resolver.EndPointConfig from the chosen resolver and sets the necessary context properties.

 

Resolver configuration sample:

<Resolvers serviceId="DynamicTest0">
&lt;![CDATA[STATIC:\\TransportLocation=SMTP://someone@bts2006.com;
EndpointConfig=SMTPHOST=MySmtpHost&amp;
FROM=noreplyn@bts2006.com&amp;
SUBJECT=A Subject]]&gt;
</Resolvers>

 

Machine.Config settings:

<add key="SMTP"
         value="Blogical.Adapter.SMTP,
         Version=1.0.0.0, Culture=neutral,
         PublicKeyToken=c2c8b2b87f54180a" />

Supported Resolvers: STATIC, BRE, Blogical.Resolver.LDAP 

LDAP Resolver

The Blogical.Resolver.LDAP resolver makes an Active Directory lookup and populates the Resolution object with Mail address, SMTP server name, From address and Subject.

This Resolver only works with the SMTP Adapter Provider

Itinerary usage:

SQL Resolver

If you’d like to use a SQL database as a repository for your services and endpoints, the Blogical.Resolver.SQL might be what you’re looking for. In this sample I’ve created a table that maches the resolution object. The resolver expects a query where returning a single row, for example:

SELECT * FROM tblResolution WHERE id='CAAE0F7E-417C-4F18-9958-8EECB6F93CAE'

The Resolver will populate the Resolution dictionary with every column/value pair.

Itinerary usage:

<Resolvers serviceId="DynamicTest0">
&lt;![CDATA[SQL:\\DataSource=localhost;
InitialCatalog=EsbExceptionDb;
IntegratedSecurity=SSPI;
Query=select * FROM tblResolution where id='CAAE0F7E-417C-4F18-9958-8EECB6F93CAE']]&gt;
</Resolvers>

 

ESB Guidance…part 6