2011年3月7日星期一

[fw-webservices] Using Http Auth with a class that extends Zend_Service_Abstract

Hi there,

I have some troubles with an home-made Url Shortener using Digest HTTP
Auth for authentication.

The problem is my shortener use a Zend_Rest_Client to forward his query,
and that Rest Client extends Zend_Service_Abstract. And
Zend_Service_Abstract share his Http Client with all of it's subclasses
(getter and setter are final static methods too...).

So, if I give credentials to the HTTP Client Adapter, I must reset them
after each call to the shorten method, or I could send them to another
Web Server which is clearly not what I want.

I see that the problem seems to be solved in the actual ZF2
AbstractService, so I think this behavior is no longer wanted.

Do you have any idea of how I could avoid this annoying credentials
reset after each request ? Without changing my Web Service
authentication, of course...

Thanks for help,
Lucas

没有评论: