[ 
http://issues.apache.org/jira/browse/COCOON-1857?page=comments#action_12415044 
] 

Brian Vargas commented on COCOON-1857:
--------------------------------------

I have done some pretty thorough investigation of this.  Tracing through some 
code, it seems that the proximate cause of this is that the 
CocoonComponentManager, extending ExcaliburComponentManager, never has its 
m_instrumentManager member set to the m_instrumentManager value of its parent 
ComponentManager instance.  

It appears that the Excalibur Instrumentation interfaces make it really 
difficult to get an InstrumentManager from a ComponentManager, thus making it 
really hard to initialize the concrete child ComponentManager's 
instrumentation.  I have a custom patch right now fixes the problem in a rather 
ugly way by:

1) Modifying ExcaliburComponentManager to expose a public 
getInstrumentManager() method.

2) Modifying SitemapLanguage's override of createComponentManager() to check 
whether the parent ComponentManager is a CocoonComponentManager (which extends 
ExcaliburComponentManager), and if so calling newly created 
CocoonComponentManager's setInstrumentManager() method with the result from the 
previously added getInstrumentManager().

This was done on Cocoon 2.1.7, but I can port the patch up if necessary.

> Sitemap Components Do Not Appear in Instrumentation
> ---------------------------------------------------
>
>          Key: COCOON-1857
>          URL: http://issues.apache.org/jira/browse/COCOON-1857
>      Project: Cocoon
>         Type: Bug

>   Components: - Components: Sitemap
>     Versions: 2.1.9
>     Reporter: Brian Vargas

>
> Although I have correctly added Excalibur instrumentation code to custom 
> sitemap components, those components never show up when connecting with the 
> instrumentation client.
> Specifically, the behavior we are seeing is that setInstrumentableName() gets 
> called on our custom reader, as expected, but then neither getInstruments() 
> nor getChildInstrumentables() ever gets called.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to