Hi Matthew, this looks good to me.  I'll give your changes a go and
let you know how I get on.

The proposed caching approach looks nice and simple.  I guess care
must be taken to make sure keys don't collide (perhaps some
recommended best practices on  creating good keys would help).

One *real* comment: I think we should be getting into the habit of
using "magic method"-style things whichappear on the SDO interface
(and also our proxy interfaces) to reduce the risk of clashes with the
business interfaces (in this case the properties of an SDO, and in the
case of our proxies it would be the service methods).

Regards, Graham.

On 1 Jun, 16:38, Matthew Peters <[EMAIL PROTECTED]>
wrote:
> I just checked in to DUNLIN a temporary change so that the ebaysoap
> binding uses the caching of the data factory. Specifically, what I did
> was:
> 1. enable the caching in the sdo extension when the special two-
> argument version of SDO_DAS_XML::create is used
> 2. make the table of cached data factories only one deep ie only allow
> one cached data factory
> 3. make the ebaysoap binding the only place in SCA where we use the
> two-argument create
>
> This is a temporary state of affairs but probably how it will go out
> in the next release.
>
> What I want to do long-term is to expose the table of cached das's as
> a proper PHP associative array which is a static member of the SDO
> class, then anyone can use it any way they see fit. The logic to use
> it would then look something like:
>
> $key = // calculate this in some way based on the xsd or xsds to be
> used.
> if (array_key_exists(SDO::cache($key)) {
>   $das = SDO::cache[$key];} else {
>
>   $das = SDO_DAS_XML::create(<path to the xsd>);
>   SDO::cache[$key] = $das;
>
> }
>
> Once the table of cached das's is in user space then people can decide
> about what to cache when, and when to invalidate entries and so on.
> Which is more or less what Ben suggested in the first place...
>
> Matthew


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"phpsoa" group.
To post to this group, send email to phpsoa@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.co.uk/group/phpsoa?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to