RE: SERVER scope

2006-02-20 Thread cf
Hi,

 Why is it frowned upon by the way? I've heard 
 such talk before, that's why I
 ask, but I'm not sure of the reasons.

one reason was the shared variables issue on CF 5 and before (concurrent 
requests).

But, another point is that on a shared server you have no way to make sure 
another programmer is not using the same variable name, thus overwriting your 
var.

Finally, in OO architectures, shared scope variables (plus request variables) 
are frowned upon, because they violate encapsulation. I think I remember a 
thread where somebody said that using request variables in a OO  architecture 
should be avoided at all costs... (which in my personal opinion is not true, 
because at all costs _never_ makes sense in programming... ;-))

If you have your own CF instance and can make sure that a variable of the same 
is not created anywhere else, you should not have a problem with server 
variables as long as you don't do OO that is. ;-)

Best,

Chris



~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232897
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=89.70.4
Donations  Support: http://www.houseoffusion.com/tiny.cfm/54


RE: SERVER scope

2006-02-20 Thread Mark A Kruger
Baz,

Mainly, the server scope needs to contain things that are germane to the
entire server. It's probably frowned on because folks would put things in
the server scope that belong in the application scope - like DSN names or
settings for example.

-Mark


-Original Message-
From: Baz [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 19, 2006 8:52 PM
To: CF-Talk
Subject: RE: SERVER scope


Thanks guys,

Why is it frowned upon by the way? I've heard such talk before, that's why I
ask, but I'm not sure of the reasons.

Baz


-Original Message-
From: Mark A Kruger [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 19, 2006 5:41 PM
To: CF-Talk
Subject: RE: SERVER scope

If as you say this library is server wide then I say go for it :) But make
sure and check to see if it already exists and only instantiate it once -
othewise whats' the point?

-mark


-Original Message-
From: Baz [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 19, 2006 4:25 PM
To: CF-Talk
Subject: SERVER scope


Hi,

I have a CFC that I use across all applications. It's basically a global UDF
library that stores no data.

Is it ok to store this CFC in the SERVER scope rather than the application
scope? Is using a named lock for this ok:

cflock name=ServerUtils type=exclusive
   cfset Server.Utils=createObject('Component','SystemUtils') /
/cflock

Cheers,
Baz










~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232922
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=89.70.4
Donations  Support: http://www.houseoffusion.com/tiny.cfm/54


Re: SERVER scope

2006-02-19 Thread Michael Dinowitz
I do, but it's usually frowned upon (for no logical reason). Just make sure 
you check if the var exists first before adding it to avoid unnecessary 
writing to the server scope, but even that is nothing to worry about as 
there is no 'real' storage difference between the server, application and 
session scopes (or any scope for that matter) other than how it's accessed.

 Hi,

 I have a CFC that I use across all applications. It's basically a global 
 UDF
 library that stores no data.

 Is it ok to store this CFC in the SERVER scope rather than the application
 scope? Is using a named lock for this ok:

 cflock name=ServerUtils type=exclusive
   cfset Server.Utils=createObject('Component','SystemUtils') /
 /cflock

 Cheers,
 Baz




 

~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232877
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


RE: SERVER scope

2006-02-19 Thread Mark A Kruger
If as you say this library is server wide then I say go for it :) But make
sure and check to see if it already exists and only instantiate it once -
othewise whats' the point?

-mark


-Original Message-
From: Baz [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 19, 2006 4:25 PM
To: CF-Talk
Subject: SERVER scope


Hi,

I have a CFC that I use across all applications. It's basically a global UDF
library that stores no data.

Is it ok to store this CFC in the SERVER scope rather than the application
scope? Is using a named lock for this ok:

cflock name=ServerUtils type=exclusive
   cfset Server.Utils=createObject('Component','SystemUtils') /
/cflock

Cheers,
Baz






~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232878
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=89.70.4
Donations  Support: http://www.houseoffusion.com/tiny.cfm/54


RE: SERVER scope

2006-02-19 Thread Baz
Thanks guys,

Why is it frowned upon by the way? I've heard such talk before, that's why I
ask, but I'm not sure of the reasons.

Baz


-Original Message-
From: Mark A Kruger [mailto:[EMAIL PROTECTED] 
Sent: Sunday, February 19, 2006 5:41 PM
To: CF-Talk
Subject: RE: SERVER scope

If as you say this library is server wide then I say go for it :) But make
sure and check to see if it already exists and only instantiate it once -
othewise whats' the point?

-mark


-Original Message-
From: Baz [mailto:[EMAIL PROTECTED]
Sent: Sunday, February 19, 2006 4:25 PM
To: CF-Talk
Subject: SERVER scope


Hi,

I have a CFC that I use across all applications. It's basically a global UDF
library that stores no data.

Is it ok to store this CFC in the SERVER scope rather than the application
scope? Is using a named lock for this ok:

cflock name=ServerUtils type=exclusive
   cfset Server.Utils=createObject('Component','SystemUtils') /
/cflock

Cheers,
Baz








~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232884
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


Re: SERVER scope

2006-02-19 Thread Michael Dinowitz
I'd bet money that the issue was a pre-mx one. If you remember in CF 5, 
there was the issue of locking of memory variables and corruption of them if 
not done. This is not a case in MX so it should not be a problem. Actually, 
this is a plug for CFObjective and CFUnited where there will be people 
talking about creating CFC factories to control CFCs that will be used 
across applications. I'd use something like that in this case.


 Thanks guys,

 Why is it frowned upon by the way? I've heard such talk before, that's why 
 I
 ask, but I'm not sure of the reasons.

 Baz


 -Original Message-
 From: Mark A Kruger [mailto:[EMAIL PROTECTED]
 Sent: Sunday, February 19, 2006 5:41 PM
 To: CF-Talk
 Subject: RE: SERVER scope

 If as you say this library is server wide then I say go for it :) But 
 make
 sure and check to see if it already exists and only instantiate it once -
 othewise whats' the point?

 -mark


 -Original Message-
 From: Baz [mailto:[EMAIL PROTECTED]
 Sent: Sunday, February 19, 2006 4:25 PM
 To: CF-Talk
 Subject: SERVER scope


 Hi,

 I have a CFC that I use across all applications. It's basically a global 
 UDF
 library that stores no data.

 Is it ok to store this CFC in the SERVER scope rather than the application
 scope? Is using a named lock for this ok:

 cflock name=ServerUtils type=exclusive
   cfset Server.Utils=createObject('Component','SystemUtils') /
 /cflock

 Cheers,
 Baz








 

~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:232888
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


RE: SERVER scope in CF Enterprise

2006-01-02 Thread Dave Watts
 If you're running CF Enterprise with sandboxes, does the 
 SERVER scope still apply to the entire server or dos each 
 sandbox have its own SERVER scope?

I'm pretty sure that you still only have one Server scope with sandboxes.
You would have separate Server scopes if you used separate CFMX instances.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized 
instruction at our training centers in Washington DC, Atlanta, 
Chicago, Baltimore, Northern Virginia, or on-site at your location. 
Visit http://training.figleaf.com/ for more information!


~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:228151
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


Re: SERVER scope in CF Enterprise

2006-01-01 Thread James Holmes
Sandboxes don't change the way scopes apply - they only introduce
security checking via the java security methods; there remains a
single SERVER scope common across all sandboxes.

However, multiple instances of CF on the one machine will each have
their own SERVER scope, because each instance runs in its own JVM.

On 1/2/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
 Hi,

 If you're running CF Enterprise with sandboxes, does the SERVER scope still
 apply to the entire server or dos each sandbox have its own SERVER scope?

--
CFAJAX docs and other useful articles:
http://jr-holmes.coldfusionjournal.com/

~|
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:228117
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


Re: Server Scope

2005-05-11 Thread Jared Rypka-Hauer - CMG, LLC
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


RE: Server Scope

2005-05-10 Thread Jim Davis
 -Original Message-
 From: David Brown [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, May 10, 2005 11:41 PM
 To: CF-Talk
 Subject: Server Scope
 
 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.

Generally it's only wise to use the server scope on servers (or instances)
you control completely - never trust it on shared servers.  This doesn't
just mean hosting but also internal shared servers (consolidated corporate
application servers for example).  It's just not worth it.

 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

Depending on the need for this you may not need the lock - or you may need a
better check.

Your first CFIF checks to see if something exists: but multiple requests may
hit that at the same time.  This means that multiple templates will be
sitting on that lock - waiting for it to free up.

So if you start your server under load your cfobject call may occur
multiple times.  To prevent this you'll need to do your check twice (but
only do the URL check the first time):

cfif (not structKeyExists(server, MyPalAuth)) or isdefined(url.Flush) 
cflock name=Lock_MyPalAuth timeout=5 type=EXCLUSIVE
cfif (not structKeyExists(server, MyPalAuth))

cfobject name=Server.MyPalAuth component=mycoms.MyPalAuth

/cfif
/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.

It sound like a perfect use for the Server Scope.

Jim Davis






~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble 
Ticket application

http://www.houseoffusion.com/banners/view.cfm?bannerid=48

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:206306
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


Re: Server Scope

2005-05-10 Thread David Brown
Jim,
Thank you sir for the answer.  Do you know how long the time to live is? 
Where do you set the time?
- Original Message - 
From: Jim Davis [EMAIL PROTECTED]
To: CF-Talk cf-talk@houseoffusion.com
Sent: Wednesday, May 11, 2005 12:01 AM
Subject: RE: Server Scope


 -Original Message-
 From: David Brown [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, May 10, 2005 11:41 PM
 To: CF-Talk
 Subject: Server Scope

 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.

 Generally it's only wise to use the server scope on servers (or instances)
 you control completely - never trust it on shared servers.  This doesn't
 just mean hosting but also internal shared servers (consolidated corporate
 application servers for example).  It's just not worth it.

 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

 Depending on the need for this you may not need the lock - or you may need 
 a
 better check.

 Your first CFIF checks to see if something exists: but multiple requests 
 may
 hit that at the same time.  This means that multiple templates will be
 sitting on that lock - waiting for it to free up.

 So if you start your server under load your cfobject call may occur
 multiple times.  To prevent this you'll need to do your check twice (but
 only do the URL check the first time):

 cfif (not structKeyExists(server, MyPalAuth)) or isdefined(url.Flush) 
  
 cflock name=Lock_MyPalAuth timeout=5 type=EXCLUSIVE
 cfif (not structKeyExists(server, MyPalAuth))

 cfobject name=Server.MyPalAuth component=mycoms.MyPalAuth

 /cfif
 /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.

 It sound like a perfect use for the Server Scope.

 Jim Davis






 

~|
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:206307
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


RE: Server Scope

2005-05-10 Thread Jim Davis
 -Original Message-
 From: David Brown [mailto:[EMAIL PROTECTED]
 Sent: Wednesday, May 11, 2005 12:10 AM
 To: CF-Talk
 Subject: Re: Server Scope
 
 Jim,
 Thank you sir for the answer.  Do you know how long the time to live is?
 Where do you set the time?

Oops - missed that one.

Anything put in the server scope will live as long as the server is up and
running - barring recycling it's effectively permanent.  Of course it can be
deleted manually by any template on the server (a StructClear(Server) would
do it) - but the ColdFusion engine won't ever time out the material.

That being said you still need code like you have to do the initialization
the first time, but once that's done you don't have to worry about it.

Jim Davis





~|
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:206308
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


RE: Server Scope / UDFs

2002-11-19 Thread Raymond Camden
 Is there a way to force CFMX to load some vars into server scope when 
 the service is started?

No. Unless you have all your code under an Application.cfm that does it.
FYI, 'events' like this has been on the enhancement list for sometime.
:)

 Also, has anyone had any negative reaction to loading a CFC 
 into server 
 scope? I basically have a library of UDFs I want globally available 
 that I thought I would throw into a CFC and load into server scope. 
 This way the UDF's would be available to all code, including 
 typically 
 blackboxed code like other CFCs and Custom tags, etc.

Well, it is not recommends for CF5 because you would need to lock every
use of it. However in MX you wouldn't need to worry about it. 

===
Raymond Camden, ColdFusion Jedi Master for Hire

Email: [EMAIL PROTECTED]
WWW  : www.camdenfamily.com/morpheus
Yahoo IM : morpheus

My ally is the Force, and a powerful ally it is. - Yoda 



~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm



Re: Server Scope / UDFs

2002-11-19 Thread Sean A Corfield
On Tuesday, Nov 19, 2002, at 08:35 US/Pacific, Sean Daniels wrote:
 Is there a way to force CFMX to load some vars into server scope when
 the service is started?

As Raymond says, put code in Application.cfm to load it once.

 Also, has anyone had any negative reaction to loading a CFC into server
 scope?

Note that you cannot output HTML from methods of CFCs that are stored 
in shared scopes (but, hey, you wouldn't be outputting HTML from CFCs 
anyway, would you?).

 Lastly, if someone has figured out a way to load UDFs in such a way
 that they behave like native functions, I would love to hear about it.

Nope, you need to scope them. Sure, you could create a 'local' alias 
via Application.cfm (cfset formatphone = server.udfs.formatphone/) 
but that won't be available inside custom tags for example.

Sean A Corfield -- Director, Architecture
Web Technology Group -- Macromedia, Inc.
tel: (415) 252-2287 -- cell: (415) 717-8473
aim: seancorfield -- http://www.macromedia.com
An Architect's View -- http://www.corfield.org/blog/

Introducing Macromedia Contribute. Web publishing for everyone.
Learn more at http://www.macromedia.com/contribute

~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm



Re: Server Scope / UDFs

2002-11-19 Thread Sean Daniels
On Tuesday, November 19, 2002, at 11:51  AM, Raymond Camden wrote:

 No. Unless you have all your code under an Application.cfm that does 
 it.
 FYI, 'events' like this has been on the enhancement list for sometime.
 :)

Thanks for the responses Sean  Ray. I hope the events thing happens 
someday. As easy as it would be to add cfif not 
isdefined(server.udfs) to every application.cfm on the server it 
would be far cooler to not have to. :)

 Well, it is not recommends for CF5 because you would need to lock every
 use of it. However in MX you wouldn't need to worry about it.

Yeah, this is MX, so not as much of an issue.

On Tuesday, November 19, 2002, at 01:58  PM, Sean A Corfield wrote:

 Note that you cannot output HTML from methods of CFCs that are stored
 in shared scopes (but, hey, you wouldn't be outputting HTML from CFCs
 anyway, would you?).

Absolutely not! :)

 Nope, you need to scope them. Sure, you could create a 'local' alias
 via Application.cfm (cfset formatphone = server.udfs.formatphone/)
 but that won't be available inside custom tags for example.

Right. I was more looking for a hack ala putting custom tags into the 
cf-root\wwwroot\WEB-INF\cftags directory so they be called like 
native tags. Oh well. Only a little additional typing.

~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.



RE: Server Scope / UDFs

2002-11-19 Thread Dave Watts
 As easy as it would be to add cfif not 
 isdefined(server.udfs) to every application.cfm 
 on the server it would be far cooler to not have 
 to. :)

Well, personally, I'm not much of a fan of the idea of loading UDFs into
memory anyway - memory is good for storing data, but is wasted on code.
However, if you really want to do this, there's no reason why you can't
write a batch file to start CF, then request a CF file using an HTTP
command-line client, like wget, to initialize your data.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444

~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm



Re: Server Scope / UDFs

2002-11-19 Thread Sean A Corfield
On Tuesday, Nov 19, 2002, at 12:05 US/Pacific, Dave Watts wrote:
 Well, personally, I'm not much of a fan of the idea of loading UDFs 
 into
 memory anyway - memory is good for storing data, but is wasted on code.

Well, functions are just data. The benefit is that you don't have to 
include the file that defines the function...

Sean A Corfield -- Director, Architecture
Web Technology Group -- Macromedia, Inc.
tel: (415) 252-2287 -- cell: (415) 717-8473
aim: seancorfield -- http://www.macromedia.com
An Architect's View -- http://www.corfield.org/blog/

Introducing Macromedia Contribute. Web publishing for everyone.
Learn more at http://www.macromedia.com/contribute

~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. http://www.fusionauthority.com/ads.cfm



Re: Server Scope / UDFs

2002-11-19 Thread S . Isaac Dealey
 On Tuesday, Nov 19, 2002, at 12:05 US/Pacific, Dave Watts
 wrote:
 Well, personally, I'm not much of a fan of the idea of
 loading UDFs
 into
 memory anyway - memory is good for storing data, but is
 wasted on code.

 Well, functions are just data. The benefit is that you
 don't have to
 include the file that defines the function...

I have a sneaky suspicion that cfset myudf = application.udf.myudf is
faster than cffunction name=myudf ... /cffunction or the cfscript
equivalent... I've never load tested it, but i would expect that the CF
processing engine, whether it's CF 5 pcode or CF MX Java has to take more
time to read in and create the function than to assign a pointer to it.

The pointer is after all only a byte or two of volatile memory lookup vs.
the function definition which is invariably larger, plus time to actually
parse and validate the code and make sure it's not missing a double-quote or
a close-parenthesis somewhere, etc.

Does anybody know for sure? Has anyone done any load testing to compare
them?

s. isaac dealey954-776-0046

new epoch  http://www.turnkey.to

lead architect, tapestry cms   http://products.turnkey.to

certified advanced coldfusion 5 developer
http://www.macromedia.com/v1/handlers/index.cfm?ID=21816


~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribeforumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Get the mailserver that powers this list at http://www.coolfusion.com