BizTalk 2009 SQL WCF Adapter Losing Messages? AKA TypedPolling Not Working

Can anybody help me with this amazingly frustrating issue? Firstly, the basiscs. I'm using BizTalk 2009 Standard Edition hosted on Windows Server 2008 
Standard (64 bit). The BizTalk databases are stored on a seperate server, running SQL Server 2008 on Windows Server 2008 Enterprise (64 bit).
I have configured a WCF SQL adapter to poll (using TypedPolling) a SQL 2008 database which in turn activates a relatively simple orchestration. The problem
is that the orchestration does not get executed at the specified polling intervals. I have several other similar polling adapters in my application that work
as expected. Generally it will run correctly once or twice after enabling/disabling the receive location or restarting the host instance. But after that it
is completely erratic. If I have it set to run every hour (3600 secs), it might complete succssfully once or twice a day at seemingly random times. On other
days it might run seven or eight times during a day.
I've spent heaps of time reading blogs and changing various settings on my receive location and have really run out of ideas. I've profiled SQL Server and it
seems that the WCF SQL adapter does hit the database at each polling period as specified, using both the polledDataAvailableStatement and the
pollingStatement. Data is always returned by these queries (a small amount - around 30 records), but they just don't seem to get to the message box. No
errors are ever reported in the Event Log.
I use a stored procedure for determining if data is available and for returning data. They are both effectively the same statement, one returns a count
whilst the other returns the data. The queries are using cross server joins as you can see below. Although I do no updates, it seems that I have to run the
receive location with AmbientTransactions turned on. Turning them off just results in a SQL Timeout exception. I don't understand why this is and would be
grateful if someone could explain.
Data Available (contained in a stored proc):
SELECT  COUNT(*)
    FROM    [LMNZLSQL002\AX].[LMNZ_AX_LIVE].[dbo].[CRM_CUSTTRANS_ITG] WITH (NOLOCK)
    WHERE    (TRANSTYPE = 8 OR TRANSTYPE = 13)  
    AND SETTLEAMOUNTCUR > 0
    AND CUSTFEEINVOICETRANSACTION30005 IS NOT NULL
    AND CUSTFEEINVOICETRANSACTION30005 <> ''      
    AND CUSTFEEINVOICETRANSACTION30005 IN
        SELECT F.FeeId
        FROM [dbo].[Fees] F WITH (NOLOCK)      
        WHERE F.FeeStatus = 3        --Unpaid
        AND F.Payer IS NOT NULL
Select Data (contained in a stored proc):
SELECT  ACCOUNTNUM, CUSTFEEINVOICETRANSACTION30005, AMOUNTCUR, SETTLEAMOUNTCUR
    FROM    [LMNZLSQL002\AX].[LMNZ_AX_LIVE].[dbo].[CRM_CUSTTRANS_ITG] WITH (NOLOCK)
    WHERE    (TRANSTYPE = 8 OR TRANSTYPE = 13)  
    AND SETTLEAMOUNTCUR > 0
    AND CUSTFEEINVOICETRANSACTION30005 IS NOT NULL
    AND CUSTFEEINVOICETRANSACTION30005 <> ''      
    AND CUSTFEEINVOICETRANSACTION30005 IN
        SELECT F.FeeId
        FROM [dbo].[Fees] F WITH (NOLOCK)
        WHERE F.FeeStatus = 3        --Unpaid
        AND F.Payer IS NOT NULL
    ORDER BY ACCOUNTNUM,CUSTFEEINVOICETRANSACTION30005
At one time I suspected that the issue may be related to database locking. So, as you can see, I've added NOLOCK locking hints to rule this out. I'm also
using a Service Behaviour (SqlAdapterInboundTransactionBehaviour) declaring a transaction level of ReadUncommitted. Obviousy I'd like to move away from the
possibility of dirty reads. Also, I've checked the SQL activity monitors when I expect the process to run and can see no locks holding it up. Also, I can
freely execute the stored procedures from SQL Management Studio at these times.
I'm not too experienced at monitoring BizTalk, but I wondered if some kind of throttling was occuring. So I've moved the receive location (and the
orchestration that doesn't always get initiated) to its own host instance and have done some monitoring via the performance counters in perfmon. I haven't
spotted any thottling going on, but maybe I wasn't looking at the correct counters (mainly used the Message Agent items).
Here's a summary of the receive location properties:
Transport: WCF-Custom
Receive Handler: AXPaymentsToFeesEngine (this host instance only hosts this receive location and the orchestration it should be activating).
Receive pipeline: XmlReceive
General tab:
EndpointAddress: mssql://lmnzlsql003/CRM/FeesEngine?InboundId=PaidInAXUnpaidInFeesEngine
Endpoint Identity - all default values
Binding Tab:
Binding Type: sqlBinding
allowIdentityInsert: False
batchSize: 20
chunkSize: 4194304  
enableBizTalkCompatibilityMode: True
enablePerformanceCounters: False
encrypt: False
inboundOperationType: TypedPolling
maxConnectionPoolSize: 100
notificationStatement: Not specified
notifyListenersOnStart: True
polledDataAvailableStatement: EXEC [dbo].[bts_PollForAXFeePaymentsNotPresentInFeesEngine_IsDataAvailable]
polledIntervalInSeconds: 3600
pollingStatement: EXEC [dbo].[bts_GetFeesMarkedUnpaidThatHaveBeenPaidInAX]
pollWhileDataFound: False
UseAmbientTransaction: True
useDatabaseNameInXsdNamespace: False
workstationId: Not specified
xmlStoredProcedureRootNodeName: Not specified
xmlStoredProcedureRootNodeNamespace: Not specified
All timeouts: 5 mins.
Behaviour Tab
ServiceBehaviour - sqlAdapterInboundTransactionBehaviour, ReadUncommitted, timeout mins
Other Tab:
Credentials: None
Preserve message order: False
Mesages Tab:
Inbound BizTalk message body: Body
Error handling: All disabled
Thanks in advance,
Mark

Thanks everyone for your input on this. None of the suggestions actually seemed to solve our specific issue, and we ended up raising a support call with Microsoft. They got us to use some tracing tools that are not publically available and it turns out that
there was a problem with the underlying WCF commnications channel, which was not visible via the usual windows event logs. They suggested a solution that, although very counter-intuitive, seems to have resolved our problem; set the ReceiveTimeout property
of the receive adapter to <!-- /* Font Definitions */ @font-face {font-family:SimSun; panose-1:2 1 6 0 3 1 1 1 1 1; mso-font-alt:宋体; mso-font-charset:134; mso-generic-font-family:auto; mso-font-pitch:variable; mso-font-signature:3 680460288 22 0 262145
0;} @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4; mso-font-alt:"Calisto MT"; mso-font-charset:0; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:-1610611985 1107304683 0 0 159 0;} @font-face
{font-family:Calibri; panose-1:2 15 5 2 2 2 4 3 2 4; mso-font-alt:"Arial Rounded MT Bold"; mso-font-charset:0; mso-generic-font-family:swiss; mso-font-pitch:variable; mso-font-signature:-1610611985 1073750139 0 0 159 0;} @font-face {font-family:"\@SimSun";
panose-1:2 1 6 0 3 1 1 1 1 1; mso-font-charset:134; mso-generic-font-family:auto; mso-font-pitch:variable; mso-font-signature:3 680460288 22 0 262145 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-unhide:no; mso-style-qformat:yes;
mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman","serif"; mso-fareast-font-family:SimSun; mso-fareast-language:ZH-CN;} .MsoChpDefault {mso-style-type:export-only;
mso-default-props:yes; font-size:10.0pt; mso-ansi-font-size:10.0pt; mso-bidi-font-size:10.0pt;} @page WordSection1 {size:612.0pt 792.0pt; margin:72.0pt 72.0pt 72.0pt 72.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.WordSection1
{page:WordSection1;} -->
24.20:31:23.6470000 and restart the service host.
Here's the underlying exception:
<!-- /* Font Definitions */ @font-face {font-family:SimSun; panose-1:2 1 6 0 3 1 1 1 1 1; mso-font-alt:宋体; mso-font-charset:134; mso-generic-font-family:auto; mso-font-pitch:variable; mso-font-signature:3 680460288 22 0 262145 0;} @font-face {font-family:"Cambria
Math"; panose-1:2 4 5 3 5 4 6 3 2 4; mso-font-alt:"Calisto MT"; mso-font-charset:0; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:-1610611985 1107304683 0 0 159 0;} @font-face {font-family:Calibri; panose-1:2 15
5 2 2 2 4 3 2 4; mso-font-alt:"Arial Rounded MT Bold"; mso-font-charset:0; mso-generic-font-family:swiss; mso-font-pitch:variable; mso-font-signature:-1610611985 1073750139 0 0 159 0;} @font-face {font-family:"\@SimSun"; panose-1:2 1 6
0 3 1 1 1 1 1; mso-font-charset:134; mso-generic-font-family:auto; mso-font-pitch:variable; mso-font-signature:3 680460288 22 0 262145 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-unhide:no; mso-style-qformat:yes; mso-style-parent:"";
margin:0cm; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman","serif"; mso-fareast-font-family:SimSun; mso-fareast-language:ZH-CN;} .MsoChpDefault {mso-style-type:export-only; mso-default-props:yes;
font-size:10.0pt; mso-ansi-font-size:10.0pt; mso-bidi-font-size:10.0pt;} @page WordSection1 {size:612.0pt 792.0pt; margin:72.0pt 72.0pt 72.0pt 72.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.WordSection1 {page:WordSection1;}
-->
[0]1E2C.21C4::07/07/2010-4:52:25.804 [CSharp]:[Wcf] BtsErrorHandler.HandleError called with Exception: System.ServiceModel.CommunicationObjectAbortedException:
The communication object, System.ServiceModel.Channels.ServiceChannel, cannot be used for communication because it has been Aborted.
   at System.ServiceModel.Channels.CommunicationObject.ThrowIfDisposedOrImmutable()
   at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   at System.ServiceModel.Channels.CommunicationObject.Open()
   at System.ServiceModel.Dispatcher.ChannelHandler.InitializeServiceChannel(ServiceChannel channel)
   at System.ServiceModel.Dispatcher.ChannelHandler.GetSessionChannel(Message message, EndpointDispatcher& endpoint, Boolean& addressMatched)
   at System.ServiceModel.Dispatcher.ChannelHandler.EnsureChannelAndEndpoint(RequestContext request)
   at System.ServiceModel.Dispatcher.ChannelHandler.TryRetrievingInstanceContext(RequestContext request).

Similar Messages

  • Biztalk 2009 with WCF adapter running on 64 bit

    Hi experts,
    I'm running a wcf adapter 64 bit send handler/host on biztalk 2009. Will it work? or does it require the adapter to be configured on 32 bit?

    The WCF bindings are supported in 64-bit Host Instances.

  • Problem with SQL WCF Adapter

    Hi All,
    This is my first time attempting to use the SQL WCF adapter with BizTalk, so I installed it after installing the SDK, everything seems fine, when I go to the project ==> Add generated items ==> Add Adapter MetaData
    I can now see the option for the WCF-SQL adapter in addition to the SQL option. however when I select it and try to continue I get this error
    unable to display adapter user interface
    Could not load file or assembly microsoft.servicemodel.channels.tools.biztalkextension, version 3.0.0.0
    and that it could not find the file
    What should I do? Thanks in advance

    If you want to use WCF SQL Adapter you have to generate metadata by add generated items -> Consume adapter services and then select the WCF Custom adapter and select SQL binding. If you want to use the non-WCF adapter then you can select add adapter metadata which you are doing currently.
    The assembly which you have mentioned is in the following path.
    {Installation Folder}\Tools\Microsoft.ServiceModel.Channels.Tools.BizTalkExtension.dll
    Check that the assembly is installed correctly. This is the Consume Adapter Service BizTalk Project Add-In for Visual studio. You can check and verify the installation assemblies from this link http://download.microsoft.com/download/9/0/d/90d3fc09-de48-4d83-8147-e8a08275c255/Readme.htm
    If it still doesn't work re-install the WCF LOB adapter SDK again.
    Abdul Rafay - MVP & MCTS BizTalk Server
    blog: http://abdulrafaysbiztalk.wordpress.com/
    Please mark this as answer if it helps.

  • Text messages ringtones are not working in the Storm Two

    Device:  Storm Two running OS version 5.0.0.713 on the Verizon Wireless network.
    Recently, I upgraded from a Storm One to a Storm Two because of a multitude of issues with the Storm One; not enough memory, constant lock-ups; dropped calls, etc.  On the Storm One I had customer ringtones for contacts; so when a contact calls me the phone will sound a specific ringtone for that contact; the same for text messages from that contact. Now that I have the Storm Two the text message tones for the contacts are not working. In fact, even when I select a ringtone for text messages for a contact the phone will ring the generic ringtone that comes with the phone. If I go into the sound profile and change the generic ringtone to one of my own and the contact sends me a text/sms message the phone will ring the ringtone that I selected in the profile that is being used at the time. This is not the way it worked on the Storm One.  On the Storm One; if I have a specific ringtone for the contact and that contact sends me a text message it will sound the text messages tone for that contact. These ringtones have worked for previous devices including my Treo and Palm devices. The ringtone files worked well in the previous Storm One.
    So to make a long story short; I want to know why my text message ringtones are not working as designed/setup-up. If a contact calls me the phone will sound the ringtone for that contact; but if that same contact text me it will not ring the ringtone for the contact. This is annoying and I am at my wits end trying to find out why this is not working.
    Vernon

    Hi Jain....
    Field separator is for separating the fields.That means it will effect every field in the node.
    But end separator is not like that.It will apply at the end ofall fields of a node.It will effect node not a field.
    according to ur scenario if u use data.endseparator 'nl',output will come like this
    2008/0701$101
    2008/0701$102
    2008/0701$103
    2008/0702$105
    if u want new line for every field try to insert a separate node for second field.That means
    MT_DATATYPE:
    Data -
    1:UnBounded
    . .OrderDate----
    1:1
       <Data2>                   1:1
    . ....OrderNo -
    1:1
    now give data.endseparator  'nl'
                data2.endseparator 'nl'
    if possible try like this....
    Sreedhar Goud L

  • Why is my text messaging app is not working at all, is a blank screen? Help!!!

    My text messaging app is not working at all is a blank screen when I open it! Help!!!

    Abdussalam.A,
    you mentioned that Terminal does not work at all for your MacBook Pro. What currently happens when you run Terminal? In what way does it not work?

  • I am using Windows 7 64-bit. After installing Photoshop Elements 13 and trying to run it I always get the message: Photoshop does not work anymore. And it doesn't.

    I am using Windows 7 64-bit. After installing Photoshop Elements 13 and trying to run it I always get the message: Photoshop does not work anymore. And it doesn't.

    Hi Hardy Tasso,
    Are you seeing this problem since first launch of PSE13 after installation or recently?
    Please try:
    Keep Ctrl + Alt + Shift keys pressed while launching PSE13 Editor and click OK on the dialog that comes next.
    Thanks,
    Anwesha

  • Every time I open a pdf file which includes a javascript, a dialogue box pops up. I have a question why 'Do not show this message again' is not working even I checked on the checkbox. It should block the dialogue next time when I open the same pdf file bu

    Every time I open a pdf file which includes a javascript, a dialogue box pops up. I have a question why 'Do not show this message again' is not working even I checked on the checkbox. It should block the dialogue next time when I open the same pdf file but not working. What is the matter and how can I deal with it?

    I am trying it on Adobe Acrobat Reader 9.2.1. Tried to fix Hex code, and also tried 'edit-preference-trust manager'. I focusing on Adobe registries but still couldn't fix the problem.

  • My text messaging app is not working PLEASE HELP!!!

    My text messaging app is not working at all is a blank screen when I open it! Help!!!

    No its a well known bug with iphones caused by their over complication of things and their complacency that their users will buy the phones on looks alone irrespective of its basic functionality.
    Suggestion 1 - The most common suggested solution seems to be: iMessage needs switched off on all your devices and switched back on after a rest. I found that this did NOT work.
    Suggestion 2 - Having a Wi Fi Signal seems to confuse iMessage to send an SMS as a text or as an iMessage. Turn off WiFi on your phone and manually send as text message. Slow, I lnow!!
    Suggestion 3 - Move away from any wifi source ie out of range.
    Suggestion 4 - Send an email, or a letter. Its more personal!!
    20 Minutes later - still not sent 2 short texts.
    Apple are very complacent and disdainful of their user community. Not what Id expect but this is a global corporation with the same business ethics as an Oil company or a car company. Profit not function.

  • HT201412 Message tones is not working sometimes

    1.My iPhone 5 message tones is not working sometimes suddenly, have to restart device or eventhought sometimes is not working too after restart my device. I have to reset my iPhone n restore again .
    2.Restore with iOS is not as good as last time coz I can't get back all my iOS photo stream photos n all the photo in my albums too. This is ***** n takes few days also not complete download all of my photos.
    3.some of my iPhone apps will suddenly not respond or will log out to home screen suddenly . Have to open the apps few times only its working as normal .

    Hi,
    I have nothing found regarding your issue. But maybe a look at SAP note 638058 will give you a hint.
    Regards,
    Klaus

  • Message.saver is not working under 10.6 - anybody know of an alternative?

    Message.saver 1.5.2 (http://www.apple.com/downloads/macosx/icons_screensavers/message.html ) is not working under 10.6. It is a screensaver that allows you to put a text on the screen as the saver kicks in. IMHO a excellent piece of software that worked fine under 10.5 but not under 10.6.
    Does anybody know if there is something like it? and that works under 10.6?
    Thanks.

    Hi
    i have the same messages on 10.6.4 and with the sonic xx170:
    28.06.10 11:39:04 racoon[489] IKE Packet: transmit success. (Phase2 Retransmit).
    28.06.10 11:39:07 racoon[489] IKE Packet: transmit success. (Phase2 Retransmit).
    28.06.10 11:39:08 racoon[489] IKE Packet: receive success. (Information message).
    28.06.10 11:39:10 pppd[488] IPSec connection failed
    28.06.10 11:39:10 racoon[489] IKE Packet: transmit success. (Information message).
    28.06.10 11:39:10 racoon[489] IKEv1 Information-Notice: transmit success. (Delete ISAKMP-SA).
    any ideas?
    waiting on 10.6.5, 10.6.6 ....?
    regards, Arthur

  • Everytime i close firefox, i get an error message about quicktime not working. 6 times.

    browsing normally, close firefox, i get an error message about quicktime not working. i click ok. then another comes up. i click ok. 6 times total this error message comes up, every time i close firefox. really annoying.

    If there are problems with updating or with the permissions then best is to download the full version and trash the currently installed version to do a clean install of the new version.
    *Trash the current Firefox application (open the Applications folder in the Finder and drag the Firefox application to the Trash) to do a clean (re)install
    *Install the new version that you have downloaded
    * http://kb.mozillazine.org/Installing_Firefox#Mac_OS_X
    Your personal data is stored elsewhere in the Firefox profile folder, so you won't lose your bookmarks and other personal data when you uninstall and (re)install Firefox.
    *http://kb.mozillazine.org/Profile_folder_-_Firefox
    You can also try to repair the disk permissions:
    *http://thexlab.com/faqs/repairprocess.html

  • Yahoo mail message editor is not working in Firefox 3.6.9

    Hi
    Yahoo! main message editor is not working in latest firefox release 3.6.9
    I am unable to type any text in message body.

    Try changing privacy.clearonshutdown.history to false

  • My message sounds are not working, and my game sounds... But my video sounds are. Not sure what to do?

    My message sounds are not working, or my game sounds...but my video is?

    Never mind. I fixed it. Silent switch was stuck

  • I have an phone 4s from cricket and when i text non iphone users such as android or and other phone brand they receive my text message but when they reply i wont get there message. send imessages is working its just my text message that is not working.

    i have an phone 4s from cricket and when i text non iphone users such as android or and other phone brand they receive my text message but when they reply i wont get there message. send imessages is working its just my text message that is not working.

    You use Restore to get the latest firmware build, not the Update button. You can only use the Update button, if there is an iOS update, say iOS 5.1.
    this link talks about updating to 9A406 to fix the "No Service" issue with iPhone 4S:
    http://iphone-and-i.blogspot.com/2011/12/fixing-iphone-4s-signal-problem.html

  • BizTalk Server 2013 SFTP Adapter with private key - Did not poll any files

    Hello, 
    We have a requirement to connect SFTP secure site with the private key and polling files.   Initially I have
    tested BizTalk Server 2013 SFTP Adapter receiver Port using  Bitvise SSH SFTP Server tool and it was working perfectly in our local network environment( with public private key authentication).
    However when we connected to Client SFTP server with private key authentication, It successfully connected to SFTP Server but
    did not poll any files from SFTP Site.  I added only one file to SFTP Server ( 145 kb file) for testing purpose.
    However BizTalk Server 2013 SFTP Send Adapter is working well with the same configuration.
    I could not find any errors in Event viewer also.  I can download\upload file using WinSCP tool .
    So I downloaded nSoftware SFTP Adapter trial version and deployed on server. nSoftware SFTP adapter  is also working find
    without any issues for Client SFTP Site.
     This is the configuration on SFTP Receive Adapter
    This is how SFTP Server download folder permission configured. I have got this details using WinSCP tool. 
    <o:p></o:p>
    Appreciate your help on this.<o:p></o:p>
    Thanks<o:p></o:p>
    PrabathD<o:p></o:p>

    BizTalk Adapter for SFTP is where the polling logic is implemented. It is not part of the SFTP Client logic. any SFTP Client is for User Interaction and you do what you want/when you want.
    The BizTalk Receive however is for purposes of automation and the adapter polls the receive location using the credentials every polling interval to check for the files matching the filter. When it find a file, it will read and publish to message box or
    submit to pipeline for processing. Your setting the polling interval to 0 (ZERO) might actually be disabling the polling.
    Set your poll interval to a non-zero value and check the behavior.
    Regards.

Maybe you are looking for