commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ceki Gülcü <c...@qos.ch>
Subject Re: cvs commit: jakarta-commons-sandbox/jelly/src/test/org/apache/commons/jelly suite.jelly
Date Wed, 16 Oct 2002 19:10:30 GMT
Couple of hours ago, I committed changes to DOMConfigurator that
enable it to deal with any nested tag that is specific to a given
appender type. It was easier than I initially thought. The code is not
trivial but not that complicated either.

While the new DOMConfigurator can deal with arbitrary nested tags, it
cannot deal with new top level tags. At this stage, that does not seem
to be a severe limitation. With the capability to handle arbitrary
nested tags, 80+ percent of log4j's needs are met.

Adding support for arbitrary tags *anywhere* within the document will
entail radical changes which do not seem warranted at this stage.

Your recent commit increases my interest in jelly, but since the
aforementioned DOMConfigurator changes let us avoid hitting the brick
wall, we'll stay the course.

Given its stringent reliability requirements, log4j is a special
case. However, in most other projects it is hard to justify
an XML processing tool other than jelly. In my humble opinion, the
missing ingredient is a tutorial consisting of 3 or 4 really simple
examples and some handholding. Is it possible that such a tutorial
exists but I've missed it?

At 18:17 16.10.2002 +0000, jstrachan@apache.org wrote:
>jstrachan    2002/10/16 11:17:59
>
>   Modified:    jelly/src/test/org/apache/commons/jelly/define
>                         beanSample.jelly
>                jelly/src/test/org/apache/commons/jelly suite.jelly
>   Added:       jelly/src/java/org/apache/commons/jelly/tags/bean
>                         package.html BeanPropertyTag.java BeandefTag.java
>                         BeanTagLibrary.java
>                jelly/src/test/org/apache/commons/jelly/bean Order.java
>                         TestJelly.java MyTagLibrary.java suite.jelly
>                         Product.java Customer.java
>   Removed:     jelly/src/test/org/apache/commons/jelly/define Customer.java
>   Log:
>   Added a simple little Jelly library which binds beans to tags. It works 
> similarly to Ant with nested properties so provides a simple way to turn 
> XML into beans.
>   While on the surface this may seem over the top when Digester and 
> Betwixt (which is layered on top of Digester) do this perfectly well, 
> using Jelly allows more complex directives like
>
>   * including other files
>   * using configurable properties or dynamic values in configuration 
> files. So dynamic expressions can be used to hook-up objects or 
> dynamically turn bits of the config on or off based on runtime properrties
>   * the same mechanism can be used inside things like workflow, unit 
> testing, JellySwing etc
>
>   This library could be used to hack together an implementation of Ceki's 
> Joran example for log4j
>
>   http://marc.theaimsgroup.com/?l=jakarta-commons-dev&m=103462608122650&w=2
>
>   Though it'd need 1 or to extra little tags to implement the appender 
> ref and to collect the appenders together into a Map etc.
>
>   Hopefully some of the similar code in the define:bean and 
> define:jellybean libraries could maybe be rationalised a little.
>
>
>   Revision  Changes    Path
>   1.1 
> jakarta-commons-sandbox/jelly/src/java/org/apache/commons/jelly/tags/bean/package.html
>
>   Index: package.html
>   ===================================================================
>   <html>
>   <head>
>   </head>
>   <body>
>
>     <p>
>         A tag library for mapping tags to beans using a similar approach 
> to Ant.
>     </p>
>
>   </body>
>   </html>
>
>

--
Ceki

TCP implementations will follow a general principle of robustness: be
conservative in what you do, be liberal in what you accept from
others. -- Jon Postel, RFC 793



--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message