Persistance

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ok, first, I do understand that, as of 0.7.5, PEAR::SOAP does not have persistance. I got to thinking why this hasn't been implemented (and how I might go about implementing it), when I came across this question:

What would necessitate the use of persistent server-side objects?

More specifically, is there something that session-based persistence can achieve that one cannot accomplish using SOAP headers and manually serializing the object at the end of the request?

About 3 months ago, someone posted to the list that they wanted their client to do something like:

$c->setKey( 'abc123' );
$key = $c->getKey();

Could this not just as easily be accomplished by sending the key in a SOAP header, having the SOAP server handle that header by setting it as an instance variable of the server-side object, then answering the request in the SOAP body?

Seems to me if you needed to truly persist the object across requests, you could have the server's response include a Unique ID for the object. If you needed access to that specific object on subsequent requests, you could send the Object ID as a header, and then the server could handle de-serializing the object before handling the body of your request.

So, persistence seems to be something that should be handled by the application developer, rather than the PEAR::SOAP library.

I am wide open to feedback on this matter!

==
Will Green

--
PHP Soap Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Kernel Newbies]     [PHP Database]     [Yosemite]

  Powered by Linux