(And I didn't even bring up the wisdom of updating a running system by
applying partial code changes!)

I was going to say.  The first thing that ran though my head when I
got to your code example was, "my dear god, Sean is off his [EMAIL PROTECTED]&$
rocker."

cheers,
barneyb

On 3/1/07, Sean Corfield <[EMAIL PROTECTED]> wrote:
On 3/1/07, Tom Chiverton <[EMAIL PROTECTED]> wrote:
> The use case that brought this up was we had a new version of an app to
> deploy, and the only change was that some of the constants in a bean had
> changed. These are stored as static bean properties to keep performance up.

Write a script that gets hold of the bean from ColdSpring and updates
it, for example:

oldBean = csFactory.getBean("constantsBean");
newBean = createObject("component","constantsBean");
for (x in oldBean) oldBean[x] = newBean[x];

That would replace all of the public data and methods in the
ColdSpring-managed bean with the matching public data and methods from
the newly updated bean.

If stuff's in variables scope inside the bean, just inject a method to
let you rewrite the data (and remove the method afterward).

(And I didn't even bring up the wisdom of updating a running system by
applying partial code changes!)
--
Sean A Corfield -- (904) 302-SEAN
An Architect's View -- http://corfield.org/

--
Barney Boisvert
[EMAIL PROTECTED]
http://www.barneyb.com/

Got Gmail? I have 100 invites.

Reply via email to