Till the server reboots... it doesn't have a lifespan setting other than
"I'll be here till the server reboots."
You could use any number of mechanisms to refresh it...
As far as whether or not to create a CFC instance in the server scope
there's no reason not to. You need to be aware of various conflicts that
might occur... so I'd recommend named locks around any code that alters the
data if there's a chance that more than one actor will try to alter the
data. Basically, all the scopes are there to be used... my philosophy is to
use them (except client... outside very specific circumstances.)
Laterz,
J
On 5/10/05, David Brown <[EMAIL PROTECTED]> wrote:
>
> A few questions:
>
> Is it good practice or wise to create an object in the server scope? And
> if
> so how long does it live? I see in the administrator Memory Variables you
> can set the application and Session time to live, but not server scope.
>
> What I want to do.
> <cfif (not structKeyExists(server, "MyPalAuth")) or isdefined("url.Flush
> ")>
> <cflock name="Lock_MyPalAuth" timeout="5" type="EXCLUSIVE">
> <cfobject name="Server.MyPalAuth"
> component="mycoms.MyPalAuth">
> </cflock>
> </cfif>
> I read this from Ben's new Advanced Macromedia ColdFusion MX 7 Application
> Development book. But he used Application scope. I want the object to be
> created once on our intranet and then invoke it when needed in more then
> one
> application. I could place it in the application scope, but then that
> would
> mean for each application I would have to recreate the object.
>
--
---------------
-------------------------------------
Buy SQLSurveyor!
http://www.web-relevant.com/sqlsurveyor
Never make your developers open Enterprise Manager again.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking
application. Start tracking and documenting hours spent on a project or with a
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:206317
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54