none
WCF-Oracle Adapater in a load-balanced environment not respecting the pollinginterval RRS feed

  • Question

  • I have created a WCF-Oracle adapter to poll an oracle table.  In my development environment which is a single server installation the polling interval that I have specified of 40seconds is respected and the port fires up every 40 seconds as expected.  For some reason when this same port is deployed into our system acceptance testing environment which is load balanced (2 biztalk server) the receive location is no longer respecting the polling interval and seems to fire up at random intervals. 

    Does the adapter behave different in a load balanced environment? 

    Is there anyway to get the adapter to respect the pollingInterval in a load-balanced environment?

    Config settings of the port are as follows:

    OracleConnectionPool->ConnectionLifetime = 50

    OracleConnectionPool->DecrPoolSize = 1

    OracleConnectionPool->IncrPoolSize =1

    OracleConnectionPool->MaxPoolSize = 10

    OracleConnectionPool->MinPoolSize = 1

    OracleConnectionPool->UseOracleConnectionPool = true

    PollingReceive->PollDataAvailableStatement = select count(SequenceNumber) from cadmah.mwm_sap_receive where rtrim(upper(origin)) = 'CS' and haspolled <> 1 and rownum = 1  and poll_priority = 2

    PollingReceive->PollingInterval = 40

    PollingReceive->PollingStatement =  SELECT agency, jobordernumber, parentjobordernumber, externalnumber1, sapnotification, origin, jobpriority, action, cadaction, statuscode, state, statusdatetime, handlingunit, createdate, wipdate, sequencenumber, haspolled, lastmodifiedbyuserid, lastmodifiedbydate, jobtasktype, jobworkcode, worktype, REFERENCEID FROM cadmah.mwm_sap_receive WHERE sequencenumber IN ( SELECT column_value FROM TABLE(CAST(cadmah.sap_cs_polljob(10,'CS', 2) AS cadmah.SAP_POLL_T)))

    PollingReceive->PollWhileDataFound = False

    Thanks Chad

     

     

    Wednesday, April 13, 2011 3:12 PM

Answers

  • Do you mean your polling statement gets executed at random intervals? It might happen that the poll interval may become slightly more than 40 seconds as it tries to acquire a connection.

    Also, when using multiple receive locations (load balanced scenario), ALL the receive locations poll every 40 seconds. So if you have 5 instances of the receive locations each with polling interval = 40, then you'll see that each recelive location polls every 40 seconds.


    -- Please mark as answered if this answers your question.
    Friday, April 15, 2011 3:44 AM

All replies

  • Do you mean your polling statement gets executed at random intervals? It might happen that the poll interval may become slightly more than 40 seconds as it tries to acquire a connection.

    Also, when using multiple receive locations (load balanced scenario), ALL the receive locations poll every 40 seconds. So if you have 5 instances of the receive locations each with polling interval = 40, then you'll see that each recelive location polls every 40 seconds.


    -- Please mark as answered if this answers your question.
    Friday, April 15, 2011 3:44 AM
  • Thanks for the response.  The polling I'm sure isn't random but I can't seem to find a pattern.  We end up with this sort of situation.

    Instance 1 starts and locks a record.

    Instance 2 should now wait 40 second for instance 1 to complete and release the record. Before it starts processing. 

    But this isn't the case instance 2 seems to be fire before the 40 seconds has elapsed and cause a record locked error.

    With the ports configured with a polling interval of 40 seconds and the ports existing on both servers we expected the ports to be in sync with one another and each fire at for example 00:01:00 and again at 00:01:40 and so on but this doesn't seem to be the behaviour.  The ports on each machine seem to be firing out of sync with each other.

    Hope that clears things up. 

    Thursday, April 28, 2011 5:13 PM