Forum Discussion

Steve_PP's avatar
Steve_PP
Experienced User
4 years ago

API fragility

Hi

 

Around 16 July the API seemed to start running at about 50% of normal speed and is now typically crashing before it gets through our normal workload that used to take about 15min. It hasn't succeeded for several days - the API typically crashes after a few minutes.

 

Separately, during the uploading of ~400 invoices yesterday it crashed 12 times before the job was finally completed.

 

Are API performance issues currently being addressed?

 

Error 500 is most common, followed by 504:

 

The remote server returned an error: (500) Internal Server Error.

The remote server returned an error: (504) Gateway Timeout.

 

I've noticed performance vary over time but it has never been this bad. Out of interest, over the last 2 years we have witnessed over 3000 errors (either 500 or 504)

 

Thanks

Steve

  • Mike_James's avatar
    Mike_James
    Ultimate Cover User

    Hi Steve_PP , this has been an ongoing issue for many months, for us since late last year, and various steps have been taken by MYOB to address it, which did help a lot. There are details on the API blog.

     

    Developers like us have been obliged to add retry routines in all our calls, and this usually works within 1 or 2 retries.

    • Steve_PP's avatar
      Steve_PP
      Experienced User

      Thanks Mike

       

      Yes, so far we've been OK, relying on the next invocation of the sync being good enough as a 'retry'. Call-by-call retrying is annoying but I guess fine for reading but what about writing? E.g. you can't tell whether MYOB has created an invoice or not for a given request if the API simply crashes. I noticed of the 12 crashes writing invoices last night that in one case MYOB had actually created the invoice - so it got duplicated on the next invocation.

       

      Out of interest, how do you handle that situation? Send some id in a hidden field on the invoice header and always look for that in existing invoices before potentially writing a new one? (give the API even more things to do - lol.) And what if MYOB only writes half the invoice lines? Have you found you need to check for that?

Looking for something else?

Search the Community Forum for answers or find your topic and get the conversation started!

Community home

Dig into MYOB Academy for free courses, learning paths and live events to help build your business with MYOB.