5

We have built an extensive middleware system around Magento's XML-RPC API. We've wrapped the endpoint with Python and are doing a lot of multicalls.

At a seemingly random interval, the API responds with

ProtocolError for www.mydomain.com/api/xmlrpc/: -1

Is this Apache's funny way of saying "503 Service Unavailable" and if so, why might that be?

What's the ideal way of handling this exception? A retry on exception seems like it'd make the problem worse.

The web server is Ubuntu 10.04.1 PHP 5.3.2-1ubuntu4.5 with Suhosin-Patch & Zend Engine v2.3.0 The API is being called with Python's xmlrpclib.

1
  • 1
    You may want to explain the entire stack your using, i.e. OS/web server, etc.
    – B00MER
    Commented Jan 28, 2011 at 18:08

1 Answer 1

0

In general you should ALWAYS try/catch errors with XMLRPC/SOAP (to Magento) as you cannot guarantee the internet connection between A and B is working.

I think your error may be Python's way of saying '50x blah' or '404 blah' IF you have not fully looked at the error object:

http://docs.python.org/library/xmlrpclib.html#protocolerror-objects

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.