click-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Md. Jahid Shohel (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CLK-661) Add Java based configuration
Date Tue, 22 Jun 2010 17:54:57 GMT

    [ https://issues.apache.org/jira/browse/CLK-661?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12881264#action_12881264
] 

Md. Jahid Shohel commented on CLK-661:
--------------------------------------

I think I could not make my self clear totally. We need the base class, and I agree with that.
So that sub classes can override that.

And about the matter I was talking. How you will mix up two config service to work together.
Say as an example, xmlconfigservice and annotationconfigservice. Say a user defined his autobinding
configuration using annotation, and rest of the configuration using xml configuration. On
this situation, before xmlconfigservice loads up the pages, the system need to process annotation
config service, and then letting xmlconfigservice to load pages. Sequence wise it will be
something like -

1) "xmlconfigservice.loadAutobinding" and then "annotationconfigservice.loadAutobinding" (where
annotation will check if autobinding is not set then initialize it)

2) "xmlconfigservice.loadPages" and then "annotationconfigservice.loadPages".


On this case, we mixing two config service working side by side. Because there will be no
point of loading autobinding configuration declared on annotation after xmlconfigservice loads
up the pages.

I am not sure if I was able to make the case clear. But this is the case I faced to integrating
annotation.

> Add Java based configuration
> ----------------------------
>
>                 Key: CLK-661
>                 URL: https://issues.apache.org/jira/browse/CLK-661
>             Project: Click
>          Issue Type: Improvement
>            Reporter: Bob Schellink
>            Assignee: Finn Bock
>             Fix For: 2.3.0-M1
>
>         Attachments: defaultconfigservice.patch
>
>
> click.xml has grown over the years especially since we introduced the service based architecture.
Some of the problems with xml based configurations is:
> - no compile time checking
> - no JavaDoc help in IDE
> I propose we add a new DefaultConfigService class that is Java based which XmlConfigService
extends from.
> Its advantages is the polar opposite of xml disadvantage:
> - compile time checking
> - JavaDoc help in IDE
> - More powerful configuration options, e.g. its possible to configure FileUpload in ways
not exposed by xml config. Also possible to create more powerful algorithms e.g. which templates
to include/exclude.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message