Gary Shea wrote:
On Tue, 19 Nov 2002, at 20:10 [+0100], Stephen McConnell ([EMAIL PROTECTED]:Don't worry!
Patch applied to the docs - but not the logging stuff because I've justI agree that having the exceptions emerge in the light of day is
been though (last night) and stripped out the logging from the builders
and verifiers. In effect the focus should be on detailed and useful
excxeptions - not on logging. In the case of the verifiers the logging
statements just reflected errors so this was simply an unnecessary
duplication because the details come out with the same messages when
handling the result of a verification.
I've applied the patch from the rest you sent though yesterday on the
pool etc.
I'll commit this in a couple of minutes.
Cheers, Steve.
better than having to dig through the log for 'em.
Please don't strip out too much logging... this thing is still alpha and
the logging is useful. Developing good error-handling channels is clearly
a great place to put energy... and it does eliminate the long term need
for some of the logging... but right now logging is useful so go easy!
The logging I've removed is completely parrallel with the exception reporting so in effect all this does is removed duplicate log messages (one in which an error is logged, and the second when the exception is logged). This is also isolutated to the factory and verifier classes - which is very restricted. End result is that the log is cleaner and loss of error related information.
p.s. re commits - make sure you sync. your CVS with both meta and assembly.
Cheers, Steve.
Gary
Gary Shea wrote:
On Tue, 19 Nov 2002, at 19:36 [+0100], Stephen McConnell ([EMAIL PROTECTED]:--
Gary Shea wrote:Ah-ha! I should have waited. After a small struggle the code yielded
Just a heads up while I try to track this one down... I've got a classThe the .xinfo file you are declaring a criteria:
which is Contextualizable, looks for the key "options-document-name".
The associatied xinfo has the corresponding <entry/> element. In the
kernel.xml profile, a non-empty value is specified in yet another <entry/>
element.
<entry key="message"/>
<entry key="whatever" type="java.io.File"/>
This is saying to the container that this component *must* be supplied
with to context entried, one entry shall have a key of "message"and a
type of String (the default type if not specificed), and the other entry
shall be a File instance supplied under the key "whatever".
The defintions in the kernal.xml (or packaged profiles) and entry
directives. These statements are declarations to the container on how
to go about creating a context entry. Two possibilities exist (a)
importing an value from the container such as "avalon:home", or
programatically constructing something. For example, the following
entried in a <compoent> defintion declare context directives (refer
ContextDirective in excalibur/meta/model javadoc).
<compoent type="MyComponet">
<context>
<entry key="message">I'm busy applying your patch</entry>
<import name="avalon:home" key="whatever"/>
</context>
</component>
The above information tells the container to assign the string "I'm busy
applying your patch" as the value of the context entry for "message",
and to import the containers defintion of "avalon:home" and assign it
under the components key of "whatever".
the truth which is that contrary to the doc, the context value is set as
you show above, not as 'value="..."'. Of course I figured that out
about 30 seconds before your mail ;). Attached find a few meta patches,
one of which I believe fixes that doc error.
Thanks for the detailed response though!
Gary
When the class is contextualized, an "options-document-name"Is there is context directive in the kernel.xml file?
value is provided, but it is the empty string.
If this reminds you of something let me know please.Getting to that - apply you patch at the moment.
Oh, the pooling stuff still isn't quite working but this problem is
earlier in the output ;)
Cheers, Steve.
:-)
------------------------------------------------------------------------
? src/java/org/apache/excalibur/meta/info/.nbattrs
? src/java/org/apache/excalibur/meta/info/builder/.nbattrs
Index: src/java/org/apache/excalibur/meta/info/builder/TypeBuilder.java
===================================================================
RCS file: /home/cvspublic/jakarta-avalon-excalibur/meta/src/java/org/apache/excalibur/meta/info/builder/TypeBuilder.java,v
retrieving revision 1.6
diff -u -r1.6 TypeBuilder.java
--- src/java/org/apache/excalibur/meta/info/builder/TypeBuilder.java 23 Oct 2002 16:34:47 -0000 1.6
+++ src/java/org/apache/excalibur/meta/info/builder/TypeBuilder.java 19 Nov 2002 18:42:08 -0000
@@ -176,6 +176,12 @@
final String xinfo =
classname.replace( '.', '/' ) + ".xinfo";
+ if ( getLogger().isDebugEnabled() )
+ {
+ getLogger().debug(
+ "build Type from XML descriptor: " + xinfo
+ + " resource found: " + (classLoader.getResource( xinfo ) != null) );
+ }
final InputStream inputStream =
classLoader.getResourceAsStream( xinfo );
Index: src/java/org/apache/excalibur/meta/info/builder/XMLTypeCreator.java
===================================================================
RCS file: /home/cvspublic/jakarta-avalon-excalibur/meta/src/java/org/apache/excalibur/meta/info/builder/XMLTypeCreator.java,v
retrieving revision 1.14
diff -u -r1.14 XMLTypeCreator.java
--- src/java/org/apache/excalibur/meta/info/builder/XMLTypeCreator.java 18 Nov 2002 11:23:46 -0000 1.14
+++ src/java/org/apache/excalibur/meta/info/builder/XMLTypeCreator.java 19 Nov 2002 18:42:09 -0000
@@ -106,6 +106,11 @@
InputStream inputStream )
throws Exception
{
+ if( getLogger().isDebugEnabled() )
+ {
+ getLogger().debug( "Reading Type XML for " + implementationKey );
+ }
+
if( inputStream == null )
{
throw new NullPointerException( "input" );
Index: src/xdocs/profile.xml
===================================================================
RCS file: /home/cvspublic/jakarta-avalon-excalibur/meta/src/xdocs/profile.xml,v
retrieving revision 1.1
diff -u -r1.1 profile.xml
--- src/xdocs/profile.xml 11 Nov 2002 11:58:47 -0000 1.1
+++ src/xdocs/profile.xml 19 Nov 2002 18:42:09 -0000
@@ -63,7 +63,7 @@
--></i></font>
<context>
- <entry name="<font color="darkred">location</font>" value="<font color="darkred">Paris</font>"/>
+ <entry name="<font color="darkred">location</font>"><font color="darkred">Paris</font></entry>
</context>
<font color="gray"><i><!--
------------------------------------------------------------------------
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
Stephen J. McConnell
OSM SARL
digital products for a global economy
mailto:[EMAIL PROTECTED]
http://www.osm.net
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
-- Stephen J. McConnell OSM SARL digital products for a global economy mailto:[EMAIL PROTECTED] http://www.osm.net -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>