I found a previous post about this same topic and Sean Corfield answered:

 

Metadata is generated by the first load of a type. Types are

only loaded when they change. You chanegd a parent CFC and saw its

metadata change because it was recompiled. You didn't change the child

so its metadata didn't change (because it wasn't recompiled).

 

So it’s a question of when and how the child CFC gets compiled.  Is there a way to programmatically recompile a CFC? 

 

All of my testing is with actual source code.

 

Thanks

 

Tom Schreck

972-361-9943


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Nando
Sent: Tuesday, May 03, 2005 1:39 PM
To: [email protected]
Subject: RE: [CFCDev] CFC and inheritance problem

 

Perhaps it's a compile issue? Sometimes i forget that the server doesn't actually run what i write.

 

I've noticed something even a little more tricky. Use cfcompile to compile your source code. Upload to the production server. Client asks for small a change and you just want to verify it with them first. Overwrite your compiled version on the production server with a source version and let CFAS compile it.

 

Client asks for one more change, but it's clear that will be all. Make the change on the dev server, compile, upload ... And CF will use its compiled version over yours ... perhaps. At least it does if the production server is in a time zone west of the one i'm in. I still don't know for sure what was going on.

 

I assume you're not mixing compiled and source code, but it really illustrated to me that the server runs compiled code, and i that i know very little about (ok, nothing) about the underlying mechanisims at work there.

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]On Behalf Of Schreck, Tom
Sent: Tuesday, May 03, 2005 7:20 PM
To: [email protected]
Subject: [CFCDev] CFC and inheritance problem

I’ve noticed that if you modify the properties of a parent CFC (in my case I added a new property) that the child CFC does not pick up the new property automatically.  Why is this and how do you overcome it?

 

I created a very simple test where I had parent and child CFCs where child extends parent.  I placed a property in parent then instantiated child CFC.  I then called getMetaData(oChild) to see the makeup of child and its inheritance.  I saw the parent property.  I then modified parent CFC by adding a new property.  I then refreshed my child instantiation and the new parent property does not show up.  No matter how many times I refreshed page, the parent property does not show.  I finally got the parent property to show by simply saving the child CFC (note: I made no changed to child).  After saving child and refreshing instantiation, the new parent property appears.

 

This seems like a major flaw.  This also seems like a caching issue.  Am I missing something?

 

Thanks

 

Tom Schreck

Applications Developer

Dresser, Inc.

15455 Dallas Parkway, Suite 1100

Addison, TX  75001-4690

972-361-9943

[EMAIL PROTECTED]

 

 

 

 

----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).

An archive of the CFCDev list is available at
www.mail-archive.com/[email protected]

<<attachment: image001.jpg>>

Reply via email to