Tuesday, July 12, 2011
#
I was checking the Windows Azure Appfabric June CTP; I was looking at the Azure Service Bus queues and topics. I noticed something interesting to me and hope we can take advantage of these new capabilities in applications like RFID. Working on BizTalk RFID or any RFID project for that matter, you would have noticed using duplicate tag elimination events during tag processing. For any one new to RFID, when RFID device reads tags it can read the same tag information more than once at a given interval. To avoid the duplicate tag reads we have Duplicate tag removal event in each process. Also using the Service Bus gives bridges the device to on premise applications in async way with greater reliability. So if looked at the Service Bus Queue’s and Topic’s, you can see properties Microsoft.ServiceBus.Messaging -> QueueDescription: DuplicateDetectionHistoryTimeWindow & RequiresDuplicateDetection
Queue accepts duplicate messages: Sent multiple duplicate messages and accepted by the queue.
Queue w/o duplicate messages: Sent multiple duplicate messages and rejected by the queue and the last duplicate message received in last 1 second.
I would to do a write up on my next blog about the duplicate detection and filters on Service Bus Topics…
Tuesday, July 05, 2011
#
Who should attend this webinar? If you are a .NET Developer/Architect working on enterprise applications, you MUST attend this webinar...
Tuesday, June 28, 2011
#
When we migrate some BizTalk apps from BizTalk 2006 R2 to BizTalk 2010, and we ran into issue when a .net component called inside the orchestration. In the .net component we are trying to retrieve some promoted property and we also checked in the BizTalk group hub to validate it was promoted, no issues there. Only when we try to access the data into the .net component we had issue. We just moved all the assembly what we had in BizTalk 2006 R2 to BizTalk 2010, didn’t recompile anything in BizTalk 2010 environment. But looking further there is couple of new namespace added to the Microsoft.XLANGs… in BizTalk 2010 compared to BizTalk 2006 R2 caused the issue. So all we did to fix the issue is recompile the project in 2010 environment and it worked fine. So it looks like some backward compatibility issue.
public static void Load(XLANGMessage msg)
{
try
{
// get the process id from context.
object ctxVal = msg.GetPropertyValue(typeof(ProcessID));
…
}
BizTalk 2010:
Error Message in the event viewer:
The service instance will remain suspended until administratively resumed or terminated.
If resumed the instance will continue from its last persisted state and may re-throw the same unexpected exception.
InstanceId: 441d73d3-2e84-49d2-b6bd-7218065b5e1d
Shape name: Bulk Load
ShapeId: bb959e56-9221-48be-a80f-24051196617d
Exception thrown from: segment 1, progress 65
Inner exception: A property cannot be associated with the type 'Tellago.Common.Schemas.ProcessId'.
Exception type: InvalidPropertyTypeException
Source: Microsoft.XLANGs.Engine
Target Site: Microsoft.XLANGs.RuntimeTypes.MessagePropertyDefinition _getMessagePropertyDefinition(System.Type)
The following is a stack trace that identifies the location where the exception occured
at Microsoft.XLANGs.Core.XMessage._getMessagePropertyDefinition(Type propType)
at Microsoft.XLANGs.Core.XMessage.GetContentProperty(Type propType)
at Microsoft.XLANGs.Core.XMessage.GetPropertyValue(Type propType)
at Microsoft.BizTalk.XLANGs.BTXEngine.BTXMessage.GetPropertyValue(Type propType)
at Microsoft.XLANGs.Core.MessageWrapperForUserCode.GetPropertyValue(Type propType)
at Tellago.Common.Components.Load(XLANGMessage msg)
at Tellago.SuspensionProcess.segment1(StopConditions stopOn)
at Microsoft.XLANGs.Core.SegmentScheduler.RunASegment(Segment s, StopConditions stopCond, Exception& exp)
Saturday, June 25, 2011
#
In one of our prod server we recently ran into issue when we went and update the web.config and try to browse the service. We started seeing the service was not responding and getting the following warning in the application log. Our service is WCF service, BizTalk orchestration exposed as service. We have other prod server where we never ran into this issue, so what’s different with this server. After going thru lot of forum and came up on some Microsoft service pack and hot fix which related to FCN. But I don’t want to apply any patch on this server then we need to do on all the other servers too. So solution is simple, I dropped the existing website, created a new site with different name with updated web.config browse the service. Then dropped that site and recreate the original web site and it worked fine without any issue.
Event Viewer:
Event Type: Warning
Event Source: ASP.NET 2.0.50727.0
Event Category: Web Event
Event ID: 1309
Date: 6/6/2011
Time: 5:41:42 PM
User: N/A
Computer: PRODP02
Description:
Event code: 3005
Event message: An unhandled exception has occurred.
Event time: 6/6/2011 5:41:42 PM
Event time (UTC): 6/6/2011 9:41:42 PM
Event ID: a71769f42b304355a58c482bfec267f2
Event sequence: 3
Event occurrence: 1
Event detail code: 0
Application information:
Application domain: /LM/W3SVC/518296899/ROOT/PortArrivals-2-129518698821558995
Trust level: Full
Application Virtual Path: /TESTSVC
Application Path: D:\inetpub\wwwroot\RFID\TESTSVC\
Machine name: PRODP02
Process information:
Process ID: 8752
Process name: w3wp.exe
Account name: domain\BizTalk_Svc_Hostlso
Exception information:
Exception type: ThreadAbortException
Exception message: Thread was being aborted.
Request information:
Request URL: http://localhost:81/TESTSVC/TESTSVCS.svc
Request path: /TESTSVC/TESTSVCS.svc
User host address: 127.0.0.1
User:
Is authenticated: False
Authentication Type:
Thread account name: domain\BizTalk_Svc_Hostlso
Thread information:
Thread ID: 22
Thread account name: domain\BizTalk_Svc_Hostlso
Is impersonating: False
Stack trace: at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
at System.Web.HttpApplication.ApplicationStepManager.ResumeSteps(Exception error)
at System.Web.HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
at
System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
<Description>Handling an exception.</Description>
<AppDomain>/LM/W3SVC/518296899/ROOT/TESTSVC-6-129518741899334691</AppDomain>
<Exception>
<ExceptionType>System.Threading.ThreadAbortException, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</ExceptionType>
<Message>Thread was being aborted.</Message>
<StackTrace>
at System.Threading.Monitor.Enter(Object obj)
at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath)
at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.WorkItem.Invoke2()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.WorkItem.Invoke()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.ProcessCallbacks()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.CompletionCallback(Object state)
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
at System.ServiceModel.Diagnostics.Utility.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)
</StackTrace>
<ExceptionString>System.Threading.ThreadAbortException: Thread was being aborted.
at System.Threading.Monitor.Enter(Object obj)
at System.ServiceModel.ServiceHostingEnvironment.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath)
at System.ServiceModel.ServiceHostingEnvironment.EnsureServiceAvailableFast(String relativeVirtualPath)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.WorkItem.Invoke2()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.WorkItem.Invoke()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.ProcessCallbacks()
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.CompletionCallback(Object state)
at System.ServiceModel.Channels.IOThreadScheduler.CriticalHelper.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
at System.ServiceModel.Diagnostics.Utility.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)</ExceptionString>
Friday, May 13, 2011
#
Working on prod issue for one of our customer using BizTalk 2006 R2 RFID, we started running into a strange issue where we are reading the vehicle and driver information. We started seeing all of our drivers tags are getting rejected after the 1st successfully read but all the Vehicle tag get processed without any issues. Just for your info each driver keep driving new vehicle each time so that’s clue for you. So on further investigation we found duplicate elimination event works fine for Vehicle tag but start rejecting driver tag after the 1st read, driver comes back after 15mins. So digging into the Duplicate elimination Interval – Event Handler. In BizTalk 2006 you have only one parameter – “Duplicate Elimination Interval”. So if you dig into the code you would see it take the device tag time and compare against the RFID server time. So in our case RFID Server time was different than Reader time by an hour. So making the Reader time and Server time fixed the issue. But there is a better solution using the BizTalk 2010 duplicate elimination event handler, so if you are using and want to make better I would recommend use it.
BizTalk 2006:
Parameter:
1. Duplicate Elimination Interval
// elapsed time is the time between now and the last time this tag was seen
int tagTS = (int) entry.VendorSpecificData[TIMESTAMPKEY];
elapsedTime = currentTS - tagTS;
// If the elapsed time is greater than the dup check interval, we can accept this tag.
// Set the max time stamp to current and increment the tag count
if (elapsedTime > dupCheckInterval)
{
Accepted …
}
Else
{
Rejected
}
BizTalk 2010:
In BizTalk 2010 you have other parameters to configure by which you can avoid running into this issue:
Parameters:
1. Duplicate Elimination Interval
2. Duplicate Elimination Criterion
a. Tag Identifier
b. Tag Identifier and Device
c. Tag Identifier and Device and Source
d. Tag Identifier and Logical Device
3. Time Reference
a. Tag Time
b. Local System Time
So make sure to set the time same on Reader and BizTalk RFID Server. Hope this helps you…
Thursday, April 14, 2011
#
This post is extension to BRE Data Services how to expose the On-Premise REST based service thru Azure appfabric service bus to your partners outside your enterprise securely. We at Tellago have created numerous REST based service for monitoring and managing for BizTalk Server, BRE and RFID Data services etc. Want if your enterprise wants to leverage the service to be accessible outside your enterprise in secured manner by external parties or mobile apps. So by using Appfabric Service Bus you’re not only creating external accessible endpoint for your service but also any other client within the same network can directly access the service without going thru the cloud as shown below.
Windows Azure Service Bus (Source: Microsoft.com)
If you using BizTalk Server, download the BRE Data Services. Configure as in the installation docs for BRE data service. So now you have your REST based data service ready now, which you want to expose the service to be accessible from outside your enterprise.
REST Service - Local Host:
So I hope at this point your already have installed the Windows Azure Appfabric SDK on your machine and also created Windows Azure AppFabric service namespace, and obtained a shared secret key. Combination of service namespace and shared secret provides way to authenticate the application accessing the service thru the Service Bus.
Go to the Web.config under the “Tellago.BRE.REST.ServiceHost” project and replace everything within the <system.serviceModel> as shown below and change the place holderYOURNAMESPACEwith your Azure Appfabric namespace and also change the ownerand [YOURKEY] with your issuer Name and issuerSecret. You should be all set to test the service now. I am setting my client authentication type to none as shown in “relayClientAuthenticationType="None"”. Also I am using SharedSecret credentials to bind the service to the cloud (Azure Appfabric service bus). So we basically uses two type of security one to bind the service and service bus and another between service and client. In our case we set the second one to None.
Web.config
<?xmlversion="1.0" encoding="utf-8" ?>
<configuration>
<system.serviceModel>
<bindings>
<!-- Application Binding -->
<webHttpRelayBinding>
<bindingname="default">
<securityrelayClientAuthenticationType="None" />
</binding>
</webHttpRelayBinding>
</bindings>
<services>
<!-- Application Service -->
<servicename="Tellago.BRE.REST.Services.BREManagementService"
behaviorConfiguration="default">
<endpointname="RelayEndpoint"
contract="System.Data.Services.IRequestHandler"
binding="webHttpRelayBinding"
bindingConfiguration="default"
behaviorConfiguration="sharedSecretClientCredentials"
address="https://YOURNAMESPACE.servicebus.windows.net/BREDataServices/BREMananagementService.svc" />
</service>
</services>
<behaviors>
<endpointBehaviors>
<behaviorname="sharedSecretClientCredentials">
<transportClientEndpointBehaviorcredentialType="SharedSecret">
<clientCredentials>
<sharedSecretissuerName="owner"issuerSecret="[YOURKEY]" />
</clientCredentials>
</transportClientEndpointBehavior>
<serviceRegistrySettingsdiscoveryMode="Public" />
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behaviorname="default">
<serviceDebughttpHelpPageEnabled="false"httpsHelpPageEnabled="false" />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
</configuration>
REST Service thru Service Bus:
It’s cool we are able to access the service outside the enterprise with just changing few lines in the config without going thru any hassle of network team just kidding :).
Hope you find this helpful and take advantage of this as first step towards the cloud based approach.
Saturday, March 26, 2011
#
We are glad to release the BizTalk RFID Data Services as part of our open source contribution here at Tellago. Let me get into some details on what’s BizTalk RFID data service and who can take advantage of it. BizTalk RFID data service is all about exposing BizTalk RFID artifacts as Restful service interface which can be easily accessed by different application within the enterprise and outside such as mobile applications. So anyone who wants to monitor the BizTalk RFID can take advantage of it. It’s easy and lightweight and it works against BizTalk RFID 2006 R2/2009/2010. It should be really handy service for support folks and business interested in monitoring. I have to thank my colleague Uri for helping me getting this out.
The BizTalk RFID data service allows you to query the RFID resources such as Process, Devices, Device Groups and Device Providers. In addition to monitoring you can also use the service to Start and Stop Process and Devices. The following are some examples based on the features available in this release.
Querying all RFID components
Querying all RFID Process:
Querying all Devices:
Querying all Device Groups:
Querying all Device Providers:
Navigating the hierarchy
Querying a specific resource:
Querying all subgroups for a specific Group:
Querying all Devices for a specific Subgroup:
Filtering:
Mapping between RFID Data Service and RFID Manager:
JSON format
Accept: application/json
With the BizTalk RFID Data Services, we also provide the functionality of executing a particular device or process update via HTTP as show below.
For RFID process:
For RFID Devices:
Also you can use IUpdatable Interface of WCF Data Services.
Updating objects
Start Process
var policyObj = Context.RFProcesss.Where(a => a.Name.Equals("TellagoRFIDDemoProcess")).FirstOrDefault();
if (policyObj != null)
{
policyObj.Status = "Start";
Context.UpdateObject(policyObj);
DataServiceResponse obj = Context.SaveChanges(SaveChangesOptions.Batch);
}
Start Devices
var policyObj = Context.Devices.Where(a => a.Name.Equals("DEVICEDEMO1")).FirstOrDefault();
if (policyObj != null)
{
policyObj.Status = "Enable";
Context.UpdateObject(policyObj);
DataServiceResponse obj = Context.SaveChanges(SaveChangesOptions.Batch);
}
Installation:
The installation of the BizTalk RFID Data Services:
· Open the Tellago.BizTalk.RFID.REST solution using VS 2008 or VS 2010
· Right click on project “BizTalkRFIDDataServices”->properties
· Go to “Web” tab and select “Use Local IIS Web Server” as shown below and click “Create Virtual directory”
· 
• Change the app pool in IIS and appPool account running the website should have been part of the BizTalk RFID User group.
• Right click the BTSRFIDManagementService.svc and browse.
Hope you have find this post helpful...
Tuesday, February 15, 2011
#
A session on SO-Aware is presented at Microsoft TechReady event this week check here for more details : http://tellagostudios.com/blog/so-aware-highlighted-microsoft-techready

Check here for more details on SO-Aware and how to leverage within your enterprise if you’re using BizTalk Server, WCF Services and services build on Azure. It provides lot of capability such as:
o Centralized service repository
o Centralized configuration management
o Service testing
o Monitoring
o Transparent integration with technologies such as Visual Studio, BizTalk Server, Windows Server & Azure AppFabric among many others
o SO-Aware Test Workbench provides developers with a visually rich environment to model and control the execution of load and functional tests in a SOA infrastructure. This tool includes the first native WCF load testing engine allowing developers to transparently load test applications built on Microsoft's service oriented technologies such as WCF, BizTalk Server or the Windows Server or Azure AppFabric.
Wednesday, November 25, 2009
#
Wednesday, November 18, 2009
#
When an itinerary is created using the itinerary designer you can deploy the Itinerary in different ways. Listed some of them and also I created a app which is basically derived from ESBImportUtil to do the deployment :
- ESBImportUtil.exe
You can use ESBImportUtil.exe utility located at C:\Program Files\Microsoft BizTalk ESB Toolkit 2.0\Bin.
Ex: ESBImportUtil.exe /f: onewayitinerary.xml /c: deployed /o
- Power Shell Script
Check out the Itinerary sample in the C:\projects\microsoft.practices.esb\Source\Samples\Itinerary\Install\Scripts\Itinerary_install.ps1
- Itinerary Deployment tool
Itinerary deployment tool basically provides similar functionality of ESBImportUtil, instead of deploying from command line now you have this app to deploy Itineraries and also planning to enhance later for modifying Itinerary configuration during deployment and also modify existing itinerary settings.
First step is to export your itinerary using Itinerary designer as xml. Choose the Itinerary xml to import in the Itinerary Deployment tool and click deploy. Import will automatically check whether the itinerary already exists in the Itinerary database or not. It will have option to overwrite the existing itinerary or not. You can overwrite an existing itinerary.
Check for the Source code and document: BizTalk ESB Importer
Thursday, November 05, 2009
#
I ran into an FTP issue in our prod, we were using BizTalk FTP adapter to get data from our partners. Basically BizTalk FTP adapter is able to connect to the ftp site and able to get the list and after that it “QUIT” without retrieving the file. There is no error in the ftp log or Application log. So BizTalk FTP adapter checks for the SYSTEM type and determines the listing to retrieve the files. If it’s a UNIX system and the file is listed as windows file listing as shown below from the log. You will run into same issue. So when changed the listing to UNIX it worked.
Here is the ftp log:
> SYST
< 215 UNIX Type: L8 Version: SUNOS
> PWD
< 257 "/" is current directory.
> TYPE A
< 200 Type set to A.
> PORT XX,XX,XX,XXX,XX,XX
< 200 PORT command successful.
> LIST ORD*
< 150 Opening ASCII mode clear data connection for file list.
< ORDaef4f2b (Windows Listings)
< 226 Transfer complete.
> QUIT
< 221-You have transferred 0 bytes in 0 files.
After we changed the file listing on the ftp server, BizTalk FTP adapter was able to pick and process the files.
-rw-rw-r-- 1 2066 ftp 234868 Nov 02 2009 ORDaef4f2b (Unix Listings)
Hope this helps…
Monday, October 12, 2009
#
BizTalk Server 2006 R2 service pack 1 BETA is available now; product team is looking for the community feedback on the BETA. List of fixes as part of this release: http://support.microsoft.com/default.aspx/kb/974563
New Features in BizTalk Server 2006 R2 Service Pack 1: http://msdn.microsoft.com/en-us/library/ee532481(BTS.20).aspx
You can download from connect: https://connect.microsoft.com/
Friday, May 01, 2009
#
BizTalk Server 2009 is available from 1st May:
http://blogs.msdn.com/biztalk_server_team_blog/archive/2009/04/28/microsoft-announces-general-availability-of-biztalk-server-2009.aspx
Some of the key features of BTS 2009:
Support for the latest platforms from Microsoft including server, Hyper-V, database and development environment(VS 2008.Net).
Enhanced developer productivity and new ALM(application life cycle management) experience for development teams.
New capabilities for implementing agile SOA integration solutions across heterogeneous technologies and Line of Business systems with enhaced LOB adpaters.
New RFID capabilities allows flexible implementation of end-to-end supply chain management and tracking solutions.
Links to new virtual labs using BTS 2009:
http://msdn.microsoft.com/en-us/virtuallabs/aa740373.aspx
Tuesday, April 14, 2009
#
The latest release of BizTalk adapter 3.0 for mySAP Suite using WCF offers 4 operations for receiving and sending message to SAP. You can receive/send messages as IDOC (Flat file data) or Xml message. Which makes easier for deploying SAP schemas in BizTalk Mgmt DB, then the earlier version where we need to take care of the one receive pipeline to accommodate all the inbound message to BizTalk from SAP. So if you need to migrate from earlier version to the latest version of adapter is easy and it’s well documented in the help file. Also the latest release offers the changes in the following:
1. Design time – Configuring the ports and meta data retrieval
2. Meta data retrieval - Using Consume Adapter Service
3. Schema file and Namespace change
4. Data type changes –Option by setting the EnableSafeTyping to true or false
5. Multiple operations for sending and receiving idoc’s in flat file (IDOC) or Xml format.
Will post more in details…
Sunday, March 22, 2009
#
Check out the 2009 Microsoft SOA & BPM Conference presentation on Microsoft ESB guidance 2.0, Oslo, BAM, REST with WCF, Customers case studies etc...
1. Keynotes, Lunch Sessions and Customer Case Studies
2. Technical Offerings Track
3. Best Practices Track