<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On 4 Nov 2009, at 14:04, Navin Surtani wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On 3 Nov 2009, at 18:24, Vladimir Blagojevic wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>On 09-11-03 12:59 PM, Galder Zamarreno wrote:<br><blockquote type="cite"><br></blockquote><blockquote type="cite">On 11/03/2009 04:52 PM, Vladimir Blagojevic wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">Hey guys,<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">I completed module configuration proposal Manik and I agreed upon. It is<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">very important to get this one right so I want to run it by you before<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">proceeding further!<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Have a look at [1] and follow proposed module configuration example below:<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><infinispan xmlns:xsi="<a href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</a>"<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">xmlns="urn:infinispan:config:4.0"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><global><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><transport clusterName="demoCluster"/><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></global><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><default><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><clustering mode="replication"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></clustering><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><modules><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><module name="query"<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">configClassName="org.infinispan.query.config.QueryConfigurationBean"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><indexing enabled="true" indexLocalOnly="true"/><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></module><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></modules><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></default><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"></infinispan><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">A few things to notice:<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">a) Any configuration (including default and namedCache) can have a<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">module definition<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">b) Instance of configClassName is a rich object structure filled from<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">module's child XML content<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite">I think configClassName should simply be 'class' as per the rest of<br></blockquote><blockquote type="cite">situations where we're configuring FQCNs.<br></blockquote><blockquote type="cite"><br></blockquote><br>Ok, makes sense!<br><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">c) Module's XML content can be arbitrary<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite">So,<indexing enabled="true" indexLocalOnly="true"/> is the XML from the<br></blockquote><blockquote type="cite">query module that the query module can read itself?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote>Yes, exactly. And it is read into object graph rooted in class specified <br>by configClassName.<br>XML unmarshalling into object graph is done by JAXB, just as we do it <br>elsewhere!<br></div></blockquote><div><br></div><div>I disagree. I could be wrong, but I think it's easiest if the QueryConfigurationBean does the work of setting up stuff kind of like how the QueryHelper [1] currently does. This way, if the query module is to be used, once these configurations are registered the appropriate interceptor can be added to the chain.</div></div></div></blockquote><div><br></div><div>Actually, ISPN-245 will take care of this. So you would write a hook into the lifecycle of the cache to take care of what the QueryHelper currently does (once ISPN-245 is complete and these hooks are available).</div><br><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>Just a quick question on general Cache setup. Currently the QueryInterceptor is added to chain <i>after</i> the locking interceptor. Just wondering that if things are done this way, i.e. we create and add the QueryInterceptor to the chain when a new instance of the QueryConfigurationBean is created, is that going to cause problems about where on the chain the QueryInterceptor sits? [Just thinking out loud]</div></div></div></blockquote><div><br></div><div>Irrelevant. Configuration parsing happens before any interceptors or components are created. Only after the entire cfg is parsed and the necessary cfg beans are available, the ComponentRegistry starts the process of creating components and wiring them together. And at this point, the ComponentRegistry will call in to any available module hooks.</div><div><br></div><blockquote type="cite"><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><blockquote type="cite"><div><span class="Apple-style-span" style="color: rgb(84, 0, 0); ">d) Custom module configuration bean is accessed by module name:</span><br><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> Configuration def = c.parseDefaultConfiguration();<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> ModuleConfigurationBean extensionConfig =<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">def.getModuleConfigurationBean("query");<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> QueryConfigurationBean bean = (QueryConfigurationBean)<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">extensionConfig.getConfigurationBean();<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> assert bean.isEnabled();<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"> assert bean.isIndexLocalOnly();<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></div></blockquote></div><div><br></div></SNIP><br><div><br class="webkit-block-placeholder"></div><div>[1] <a href="http://fisheye.jboss.org/browse/Infinispan/trunk/query/src/main/java/org/infinispan/query/backend/QueryHelper.java?r=trunk">http://fisheye.jboss.org/browse/Infinispan/trunk/query/src/main/java/org/infinispan/query/backend/QueryHelper.java?r=trunk</a></div><div><br class="webkit-block-placeholder"></div><div>
<span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div>Navin Surtani</div><div><br></div><div>Intern Infinispan</div><div>Intern JBoss Cache Searchable</div></span>
</div>
<br></div>_______________________________________________<br>infinispan-dev mailing list<br><a href="mailto:infinispan-dev@lists.jboss.org">infinispan-dev@lists.jboss.org</a><br>https://lists.jboss.org/mailman/listinfo/infinispan-dev</blockquote></div><br><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>--</div><div>Manik Surtani</div><div><a href="mailto:manik@jboss.org">manik@jboss.org</a></div><div>Lead, Infinispan</div><div>Lead, JBoss Cache</div><div><a href="http://www.infinispan.org">http://www.infinispan.org</a></div><div><a href="http://www.jbosscache.org">http://www.jbosscache.org</a></div><div><br></div></div></span><br class="Apple-interchange-newline"></span><br class="Apple-interchange-newline">
</div>
<br></body></html>