Hi Kay,

I don't think it would be bad form to only do the copy/save in the first and last fuses of the fuseaction.  Just amend your Fusedocs so it's all well-documented.  Why not create special fuses just for the copy/save parts?:

<cfcase value="blah">
  <cfinclude template="act_copysession.cfm">
  <cfinclude template="act_dosomestuff.cfm">
  <cfinclude template="act_savesession.cfm">
</cfcase>

But it's more usual to do the initial copy from the session scope in your fbx_settings.

WHatcha reckon?

LeeBB

 

----- Original Message -----

 

Hi all,

Here's a philosophical question for you all :)

I have a batch credit card decryption/payment processing circuit. The
various stages all happen over a few fuseactions. I've tried to make
each fuse do just one thing as much as possible, it makes it easier to
debug. The payment data is stored in a session struct. 

I would judge the re-usability of these fuses as quite low. Perhaps they
could be recycled quite well. But this is a fairly specific system.

At the beginning of each fuse that requires it, I copy the session
struct to the local scope, and back again at the end if required. Now
that I look at it (it's at the testing stage) there are a few places
where the two or more fuses which make up a fuseaction are each copying
the session struct to the local scope and then copying it back again
when they have finished, when in reality these actions only need to
happen once per fuseaction. Is it bad style to only copy them over in
the first fuse, and back in the last? It feels like it would be breaking
some kind of modularity rules. Or should I put the copy over/back into
the switch? Or (and I just thought of this while I was typing) should I
create a separate fuse to copy the struct over, and another to copy it
back, and resuse these? Maybe this could be done in a UDF? I guess what
I'm really trying to decide is, what's more important: minimizing the
cflock/session overhead, or maximizing the reusability of the fuses?
==^================================================================
This email was sent to: [email protected]

EASY UNSUBSCRIBE click here: http://topica.com/u/?bUrFMa.bV0Kx9
Or send an email to: [EMAIL PROTECTED]

T O P I C A -- Register now to manage your mail!
http://www.topica.com/partner/tag02/register
==^================================================================

Reply via email to