You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@beehive.apache.org by "Carlin Rogers (JIRA)" <be...@incubator.apache.org> on 2005/06/25 02:39:06 UTC

[jira] Created: (BEEHIVE-835) Make improvements to the support for URL templating.

Make improvements to the support for URL templating.
----------------------------------------------------

         Key: BEEHIVE-835
         URL: http://issues.apache.org/jira/browse/BEEHIVE-835
     Project: Beehive
        Type: Improvement
  Components: NetUI  
    Versions: V1Alpha, V1Beta, v1m1    
    Reporter: Carlin Rogers
 Assigned to: Carlin Rogers 
     Fix For: V1


These changes are based on the discussions from email I posted 
to the beehive-dev@incubator.apache.org list. See...

http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
and
http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e


In summary...
- deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
to get a URLTemplate.
- create a hook via the ServletContainerAdapter  to support container 
specific implementations of URLTemplatesFactory (extending Factory) for 
reading/parsing the beehive-url-template-config.xml descriptor file. 
- after loading the URLTemplatesFactory  instance, set it as an 
attribute on the ServletContext so TemplatedURLFormatter 
implementations can get the desired URLTemplate when formatting a
rewritten URL.
- add an element to the beehive-netui-config schema to allow for a
class name of a per-webapp TemplatedURLFormatter to be used by the
URLRewriterService if there is not a per-request registered 
TemplatedURLFormatter.
- add this default TemplatedURLFormatter instance to the
ServletContext for the URLRewriterService.

And other minor modifications...
- change TemplateTokenizer to accept more general token (I.e. "url:"
is not required as part of the token string).
- when formatting the URL with a template, if there is now replacement
value for a token, use the empty string.
- go back to "jpf-url-templates" as the name of the default template 
ref group rather than "default-url-templates".


-- 
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


[jira] Resolved: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Rich Feit (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]
     
Rich Feit resolved BEEHIVE-835:
-------------------------------

    Resolution: Fixed

Thanks Carlin.  I submitted the patch with revision 219136.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Rich Feit
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt, j835-patch3.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Reopened: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]
     
Carlin Rogers reopened BEEHIVE-835:
-----------------------------------


I'm going to add a third patch to address the Eddie's suggestions in the 
discussion about the NetUI generic Factory in the core package. I think after
this last patch we can resolve this issue. Thanks.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Updated: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Rich Feit (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Rich Feit updated BEEHIVE-835:
------------------------------

    Assign To: Carlin Rogers  (was: Rich Feit)

Thanks Carlin -- these changes look good to me.  I committed them with revision 202040.  I'm leaving the bug open to discuss three things -- let me know what you think.

1) Could DefaultTemplatedURLFormatter and DefaultURLTemplatesFactory be implicit if you call their respective initServletContext methods with a null value?  Seems like the default implementations should be chosen down in the core layer, if those implementations live in the core layer.

2) I changed the implementation of DefaultServletContainerAdapter.getFactory() to assume that it's a programming error to call it with a Class that's not assignable to Factory.  But beyond that, does there really need to be an implementation of getFactory in DefaultServletContainerAdapter?  Seems like this could be omitted (replaced with an empty implementation), since we already infer DefaultURLTemplatesFactory.

3) In netui-config.xsd could there be a default value for templated-url-formatter-class?

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: V1Alpha, V1Beta, v1m1
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Updated: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers updated BEEHIVE-835:
----------------------------------

    Attachment: j835-patch3.txt

The following patch moves the Factory and FactoryConfig classes from
org.apache.beehive.netui.core down into org.apache.beehive.netui.core.factory.
I have also created a new FactoryUtils class with the static methods from Factory.
Finally, this patch has some minor clean up to the HtmlBaseTag to remove a
noop method, qualifyUrlToContext().

Note that this patch includes an svn move command for the Factory and FactoryConfig
classes, implying some file deletes and adds. Her'e the svn status summary to check
with the patch in case the patch does not work correctly. Let me know if there are any
issues.

M      netui\src\core\org\apache\beehive\netui\core\urltemplates\URLTemplatesFactory.java
D      netui\src\core\org\apache\beehive\netui\core\Factory.java
A      netui\src\core\org\apache\beehive\netui\core\factory
A  +   netui\src\core\org\apache\beehive\netui\core\factory\Factory.java
A      netui\src\core\org\apache\beehive\netui\core\factory\FactoryUtils.java
A  +   netui\src\core\org\apache\beehive\netui\core\factory\FactoryConfig.java
D      netui\src\core\org\apache\beehive\netui\core\FactoryConfig.java
M      netui\src\tags-html\org\apache\beehive\netui\tags\html\HtmlBaseTag.java
M      netui\src\tags-html\org\apache\beehive\netui\tags\html\ImageAnchor.java
M      netui\src\tags-html\org\apache\beehive\netui\tags\html\ImageButton.java
M      netui\src\pageflow\org\apache\beehive\netui\pageflow\ServletContainerAdapter.java
M      netui\src\pageflow\org\apache\beehive\netui\pageflow\DefaultServletContainerAdapter.java
M      netui\src\pageflow\org\apache\beehive\netui\pageflow\FlowControllerFactory.java
M      netui\src\pageflow\org\apache\beehive\netui\pageflow\FacesBackingBeanFactory.java

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt, j835-patch3.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Assigned: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers reassigned BEEHIVE-835:
-------------------------------------

    Assign To: Rich Feit  (was: Carlin Rogers)

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: V1Alpha, V1Beta, v1m1
>     Reporter: Carlin Rogers
>     Assignee: Rich Feit
>      Fix For: V1
>  Attachments: j835-patch.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Assigned: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers reassigned BEEHIVE-835:
-------------------------------------

    Assign To: Rich Feit  (was: Carlin Rogers)

Assigning to Rich to review the new, additional patch.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Rich Feit
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Assigned: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers reassigned BEEHIVE-835:
-------------------------------------

    Assign To: Rich Feit  (was: Carlin Rogers)

Rich, this should be the last patch for this bug. I think you can resolve
it after reviewing the changes and committing. Thanks.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Rich Feit
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt, j835-patch3.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Commented: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
    [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=comments#action_12314566 ] 

Carlin Rogers commented on BEEHIVE-835:
---------------------------------------

Hey Rich thanks for the time and help reviewing this as well as committing it.

1) Yes, I'd thought of that as well at one point and makes sense with DefaultTemplatedURLFormatter.
However, I didn't do it because I wasn't sure if I should implicitly use the collection of known and 
required tokens from the DefaultURLTemplatesFactory  or the collection of tokens of the 
URLTemplatesFactory  attribute on the ServletContext. I'd suppose we'd want the later.

2)  No, I put it in so that it explicitly showed the dependence for the support of URLTemplatesFactory
but  we could remove it and just leave the note in the javadoc.

3) Sure, easy enough.  I figured that since minoccurance attr was zero we didn't need a 
default string for the DefaultTemplatedURLFormatter  class.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: V1Alpha, V1Beta, v1m1
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Resolved: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Rich Feit (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]
     
Rich Feit resolved BEEHIVE-835:
-------------------------------

    Resolution: Fixed
     Assign To: Carlin Rogers  (was: Rich Feit)

Applied the patch with revision 208803.  Carlin, is this issue done then?

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Updated: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers updated BEEHIVE-835:
----------------------------------

    Attachment: j835-patch2.txt

This patch addresses the suggestions made by Rich, along with a couple other minor tweaks.
- Moved the default implementations of TemplatedURLFormatter and URLTemplatesFactory.
- Added a method to PageFlowUtils to create a new container specific URLTemplatesFactory
instance (or the default) since the Adaptermanager class is internal, not really exposed as public API.
- DefaultServletContainerAdapter.getFactory() just returns null.
- The "templated-url-formatter-class" schema element in netui-config.xsd now has a default value.
- Backed out the previous patch change to the value of the DEFAULT_TEMPLATE_REF constant.
It is set to "default-url-templates". Moved this constant into TemplatedURLFormatter.

Also to avoid a conflict with the patch for JIRA BEEHIVE-840, this patch includes the
changes in the 840 patch. Just apply this patch and then ignore the patch attached
to 840. Thanks.

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Assigned: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers reassigned BEEHIVE-835:
-------------------------------------

    Assign To: Nathan Jantz  (was: Rich Feit)

> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: v1m1, V1Beta, V1Alpha
>     Reporter: Carlin Rogers
>     Assignee: Nathan Jantz
>      Fix For: V1
>  Attachments: j835-patch.txt, j835-patch2.txt, j835-patch3.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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


[jira] Updated: (BEEHIVE-835) Make improvements to the support for URL templating.

Posted by "Carlin Rogers (JIRA)" <be...@incubator.apache.org>.
     [ http://issues.apache.org/jira/browse/BEEHIVE-835?page=all ]

Carlin Rogers updated BEEHIVE-835:
----------------------------------

    Attachment: j835-patch.txt

Attaching a patch with changes to address the improvements described in this bug.

Note that there have been a couple of files moved / deleted / added so there may be some manual
steps required to apply this patch.

- Deleted
D      netui\src\util\org\apache\beehive\netui\core\urltemplates\DefaultURLTemplateFileParser.java
D      netui\src\util\org\apache\beehive\netui\core\urltemplates\URLTemplateFileParser.java

- Moved 
netui\src\pageflow\org\apache\beehive\netui\pageflow\Factory.java
netui\src\pageflow\org\apache\beehive\netui\pageflow\FactoryConfig.java
to 
netui\src\util\org\apache\beehive\netui\core\Factory.java
netui\src\util\org\apache\beehive\netui\core\FactoryConfig.java
respectively.

- Added
A      netui\src\util\org\apache\beehive\netui\core\urltemplates\DefaultURLTemplatesFactory.java


> Make improvements to the support for URL templating.
> ----------------------------------------------------
>
>          Key: BEEHIVE-835
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-835
>      Project: Beehive
>         Type: Improvement
>   Components: NetUI
>     Versions: V1Alpha, V1Beta, v1m1
>     Reporter: Carlin Rogers
>     Assignee: Carlin Rogers
>      Fix For: V1
>  Attachments: j835-patch.txt
>
> These changes are based on the discussions from email I posted 
> to the beehive-dev@incubator.apache.org list. See...
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de050617080216c7f0d0@mail.gmail.com%3e
> and
> http://mail-archives.apache.org/mod_mbox/incubator-beehive-dev/200506.mbox/%3cba6911de0506240926ee7146b@mail.gmail.com%3e
> In summary...
> - deprecate URLTemplateDescriptor and just use the URLTemplatesFactory 
> to get a URLTemplate.
> - create a hook via the ServletContainerAdapter  to support container 
> specific implementations of URLTemplatesFactory (extending Factory) for 
> reading/parsing the beehive-url-template-config.xml descriptor file. 
> - after loading the URLTemplatesFactory  instance, set it as an 
> attribute on the ServletContext so TemplatedURLFormatter 
> implementations can get the desired URLTemplate when formatting a
> rewritten URL.
> - add an element to the beehive-netui-config schema to allow for a
> class name of a per-webapp TemplatedURLFormatter to be used by the
> URLRewriterService if there is not a per-request registered 
> TemplatedURLFormatter.
> - add this default TemplatedURLFormatter instance to the
> ServletContext for the URLRewriterService.
> And other minor modifications...
> - change TemplateTokenizer to accept more general token (I.e. "url:"
> is not required as part of the token string).
> - when formatting the URL with a template, if there is now replacement
> value for a token, use the empty string.
> - go back to "jpf-url-templates" as the name of the default template 
> ref group rather than "default-url-templates".

-- 
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