web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Dynamics ax 2012 Service operation "Receive timeout" exceed

(0) ShareShare
ReportReport
Posted on by 805

Hi,

I have a problem with a document service which update operation takes too much time, so the receive timeout exceeded. The service use file system adapter.

Here is the error message:

The query consist of BOMVersion, BOMTable and BOM tables related by BOMId field.

The service has been generated with the standard AX wizard and there is no changes in the code generated by the wizard.

The xml message consist of one BOMVersion record, one BOMTable record and 479 BOM records.

The message takes 17 minutes to be processed. This happens when I increase the receive timeout from 10 minutes (which is the default value) to 30.

I think that the processing time is too much.

Can you anyone tell me what should be the reason. Is it normal or not?

Kind Regards,

ist.

*This post is locked for comments

I have the same question (0)
  • Vincent Lecours Profile Picture
    235 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi!

    When you say you increased the receive timeout, did you do it in your client application, in AX or both?

  • ist Profile Picture
    805 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi Vincent,

    I have no client application. I have xml message generated in some way. This message arrives in message folder. Batch jobs processing this message through invoking service operation. I have increased receive timeout in inbound port binding (button AOS configuration for my inbount port).

    Kind Regards,

    ist

  • Vincent Lecours Profile Picture
    235 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi!

    I would try increasing the following timeouts to something huge like 10 hours (10:00:00) to see if it solves your timeout issue (You will be able to change them back to realistic values after your tests):

    • CloseTimeout
    • OpenTimeout
    • ReceiveTimeout
    • SendTimeout
    • InactivityTimeout

    Also, make sure this is not a permission issue on the owner of the file when AX grabs it from the folder.

  • Martin Dráb Profile Picture
    236,499 Most Valuable Professional on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Did you do any investigation? Did you try to debug the service? Did you look for long-running queries and locks? If so, what did you find?

  • ist Profile Picture
    805 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi Martin,

    We have monitored the SQL Server when the service operation starts.

    Here is the report:

    As you can see the number of locks are 1500 on the BOM table.

    Kind Regards,

    ist.

  • Martin Dráb Profile Picture
    236,499 Most Valuable Professional on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    It doesn't seem to be a problem, if the locks don't block any other transaction. Nevertheless if you wanted to update 500 records and locked 1500, your code may be doing something else then you expect. I would review/debug what the code does, if I was you.

  • ist Profile Picture
    805 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi Martin,

    I have reviwed/debuged the code and I can say that the code was generated from AIF Document service wizard and has not been changed after that from anyone.

    I have recreate the inbound port with default binding settings and one of the problematic messages has been processed correctly. The only problem is that during the proseccing of the message the timeout for respond exceeds which default value is 5 minutes.

    The error now is:

    The request failed with the following error:  This request operation sent to net.tcp://hostName:8201/DynamicsAx/Services/OurService did not receive a reply within the configured timeout (00:05:00).  The time allotted to this operation may have been a portion of a longer timeout.  This may be because the service is still processing the operation or because the service was unable to send a reply message.  Please consider increasing the operation timeout (by casting the channel/proxy to IContextChannel and setting the OperationTimeout property) and ensure that the service is able to connect to the client.


    Kind Regards,

    ist.

  • Vincent Lecours Profile Picture
    235 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Have you tried changing the various timeout values like I posted earlier in the thread?

  • ist Profile Picture
    805 on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Hi Vincent,

    Not yet. I have recreate the service port. I will do that. What about if all timeouts are 10 hours. Perhaps it will solve the problem but how can I find what exactly is the real problem?

    Kind Regards,

    ist.

  • Martin Dráb Profile Picture
    236,499 Most Valuable Professional on at
    RE: Dynamics ax 2012 Service operation "Receive timeout" exceed

    Changing timeouts wouldn't solve the problem: that a relatively simple update already takes seventeen minutes.

    You seem to assume that the code generator reads your mind and generates the code you want, but unfortunately that's not the case. What gets generated automatically is usually used just as a base for adding business logic that the generator can't understand.

    Therefore saying that you didn't change the code doesn't mean it's correct, especially if we talk about such a complex model as BOM.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Tocauer Profile Picture

Martin Tocauer 4

#2
Community Member Profile Picture

Community Member 2

#2
Nayyar Siddiqi Profile Picture

Nayyar Siddiqi 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans