Although I am intrigued by Dennis' comment (this would certainly be a very nice ColdSpring enhancement), this approach is not available to you at the present time, so the solution for now is to implement a parent bean factory as Doug suggested. As he mentioned, the key here is to reload the parent BF when the MG reloadKey/reloadPassword pair is passed on the URL.
To explain a little further as to why this is necessary, the issue is that the CS remote proxies will be keyed to a particular bean factory name (in the case of the supplied configuration, "beanFactory"), so the bean factory used for the proxies will be stored in the application scope using that name (e.g., application.beanFactory), and CS will create this bean factory if it does not exist. Therefore, reloading MG, and thereby the MG bean factory, will not trigger regeneration of the proxies. HTH, -- Ezra On Wed, Mar 24, 2010 at 9:33 AM, Dennis Clark <[email protected]> wrote: > What you want to do is not supported at this time. It requires a > RemoteFactoryBean implementation that knows how to use > ModelGlue.Util.ModelGlueFrameworkLocator to find MG's bean factory. > I've looked into this last year (along with some other enhancements to > RemoteFactoryBean) but since I didn't have a pressing need for it myself I > didn't get to writing an implementation. > If anyone here is interested in helping me out with such an implementation, > I could use some volunteers to provide test code (remote beans and > corresponding MG test harnesses). > Cheers, > -- Dennis > On Wed, Mar 24, 2010 at 9:19 AM, Sir Rawlins > <[email protected]> wrote: >> >> Hello Guys, >> >> I'm trying to configure a remote proxy in ColdSpring within an MG >> application. The bean definition looks like so: >> >> <bean id="remoteOrderService" >> class="coldspring.aop.framework.RemoteFactoryBean" lazy- >> init="false"> >> <property name="target"> >> <ref bean="orderService" /> >> </property> >> <property name="serviceName"> >> <value>OrderService</value> >> </property> >> <property name="relativePath"> >> <value>/api</value> >> </property> >> <property name="remoteMethodNames"> >> <value>createOrder</value> >> </property> >> <property name="beanFactoryName"> >> <value>beanFactory</value> >> </property> >> </bean> >> >> Now, it appears that the issue with this is that the target service >> object is cached in the application scope outside of the model glue >> bean factory, so when I make a change to the code on the CFC and >> reinit the MG application the changes are not propagated to my remote >> proxies and I have to restart the server every time *rolls eyes* >> >> Can anyone explain how I can configure this remote proxy to work with >> the same bean factory as model glue? >> >> Thanks, >> >> Rob >> >> -- >> 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 >> >> To unsubscribe from this group, send email to >> model-glue+unsubscribegooglegroups.com or reply to this email with the words >> "REMOVE ME" as the subject. > > -- > 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 > > To unsubscribe from this group, send email to > model-glue+unsubscribegooglegroups.com or reply to this email with the words > "REMOVE ME" as the subject. > -- 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 To unsubscribe from this group, send email to model-glue+unsubscribegooglegroups.com or reply to this email with the words "REMOVE ME" as the subject.
