The way Flex calls remote services is that it calls them "directly" and passes the necessary parameters in over the remote call. The default Sculptor services have the ServiceContext as the first parameter - but for me to specify that inside the client and have the client tell the server who it is and what it's session ID is seems wrong.
When the methods get invoked on the server, I have access to the request and I can get the necessary information to inject a ServiceContext object into an instance of my remote service that gets used in processing that request. So if I can create a remote service that doesn't require the ServiceContext parameter, I can expose that service to my remote clients. In my implentation of that, I can delegate all of my service calls to other services which DO take a ServiceContext parameter to handle the auditing / logging etc. There is the property to turn off the serviceContext all together, but in my case I want it on all but a few of my services - so I think this is a case where I could write a specialCases.xpt to use AOP to wrap the generation and have it turn off the ServiceContext generation for those methods only. I'm new to the XPT templates, so I'm not quite sure where to start. It looks like things that are defined inside of <<DEFINE>> blocks you can wrap around fairly easily. I was hoping that I would get lucky and there would be some magic code in there that already handles the parameter generation based on that property that indicates whether or not to use ServiceContexts - and that I could just work on the syntax to map my specific class (say... any service with the name "Remote" in it has the ServiceContexts turned off for its generation) - but I can't quite figure out how to do that. Any ideas on where I should start looking for that? Ryan ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Fornax-developer mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/fornax-developer
