Isn't that because the bean factory is, in essence, gone?

While we have a feature intended to not reload the bean factory, and just
reload MG Configs, I do not believe we have a feature to make the bean
factory disappear in the middle of a request. Isn't this what you are
doing?

In short, I think what you may need to try, is reload your parent bean
factory, then reload MG through the built in mechanism provided. It is
locked and handles the reloading in a specific order.

If I'm not understanding correctly,maybe try explaining again.

DW
On Nov 5, 2012 7:09 PM, "Brian G" <[email protected]> wrote:

>
> I don't know exactly...  I believe the issue is that in one request, I'm
> calling ?reinit=true.   Let's say it takes a total of 30-60s to redo
> everything (I'm on CF8 FWIW but other than performance I don't think that's
> relevant).
>
> While it's reiniting in my request, other people are hitting the site.  I
> *think* what's happening is that any request from another user that has
> already begun before the new BeanFactory is in place but keeps running
> AFTER it's assigned is getting indeterminate state.
>
> Basically, if an MG request starts off and somewhere through the process
> the BeanFactory changes in the middle of code executing a request, things
> get "weird".
>
>
> Brian
>
>
> On Monday, November 5, 2012 12:59:49 PM UTC-8, Dan Wilson -
> [email protected] wrote:
>>
>> I wonder if you might be best served creating the parent bean factory in
>> it's own process, then hooking back up to it when it's created?
>>
>> Am I right in rephrasing the problem you are having, is the portion of
>> time when the parent bean factory is gone, and current requests are trying
>> to access objects in the bean factory?
>>
>> 100 objects isn't that many to create, especially on CF9 and above. The
>> better question is what is required internally to instantiate all of those
>> objects? Do you have complex init() depenencies?
>>
>>
>> DW
>>
>>
>> On Mon, Nov 5, 2012 at 3:33 PM, Brian G <[email protected]> wrote:
>>
>>> Quick Q - if I have a parent bean factory, will reloadBeanFactory set to
>>> false really do much for me?
>>>
>>> My read of the code is that, reloadBeanFactory=false will save the full
>>> instantiation of ModelGlue.gesture.loading.**ColdSpringBootstrapper and
>>> instead call application[modelglue_app_key]**.reset() but I'm not clear
>>> how different that is.  Just recreating the bean factory for Model Glue
>>> happens pretty quickly; it's my parent bean factory (application.cs) that
>>> has 100 singletons in it which takes a long time.
>>>
>>> .reset() runs:
>>>
>>>     <cfset structClear(this.**messageListeners) />
>>>     <cfset structClear(this.controllers) />
>>>     <cfset structClear(this.**eventHandlers) />
>>>     <cfset structClear(this.eventTypes) />
>>>
>>> Does this force pretty much the same reinit process as in Unity if you
>>> are using a parent bean factory?
>>>
>>>
>>> Brian
>>>
>>> --
>>> Model-Glue Sites:
>>> Home Page: http://www.model-glue.com
>>> Documentation: http://docs.model-glue.com
>>> Bug Tracker: http://bugs.model-glue.com
>>> Blog: http://www.model-glue.com/blog
>>>
>>> You received this message because you are subscribed to the Google
>>> Groups "model-glue" group.
>>> To post to this group, send email to [email protected]
>>> To unsubscribe from this group, send email to
>>> model-glue+...@**googlegroups.com
>>> For more options, visit this group at
>>> http://groups.google.com/**group/model-glue?hl=en<http://groups.google.com/group/model-glue?hl=en>
>>
>>
>>
>>
>> --
>> Plutarch - "The mind is not a vessel to be filled but a fire to be
>> kindled."
>>
>  --
> Model-Glue Sites:
> Home Page: http://www.model-glue.com
> Documentation: http://docs.model-glue.com
> Bug Tracker: http://bugs.model-glue.com
> Blog: http://www.model-glue.com/blog
>
> You received this message because you are subscribed to the Google
> Groups "model-glue" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/model-glue?hl=en

-- 
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog

You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en

Reply via email to