You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by "Henning Schmiedehausen (JIRA)" <ji...@apache.org> on 2008/05/08 02:27:55 UTC

[jira] Created: (SHINDIG-247) Refactor AbstractContentCache

Refactor AbstractContentCache
-----------------------------

                 Key: SHINDIG-247
                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
             Project: Shindig
          Issue Type: Improvement
          Components: Gadget Rendering Server (Java)
            Reporter: Henning Schmiedehausen


The attached patch refactors the code from the AbstractContentCache class a bit:

- add javadocs to AbstractContentCache and ContentCache
- turn checkContent() into RemoteContent methods:
      - isExpired() whether this RemoteContent object is expired
      - isCacheable() whether this RemoteContent object can be cached
      - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header

- This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
   turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code



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


[jira] Commented: (SHINDIG-247) Refactor AbstractContentCache

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12595101#action_12595101 ] 

Kevin Brown commented on SHINDIG-247:
-------------------------------------

I'm actually working in this area right now, and, incidentally, I've already implemented the exact same methods in pretty much the same way as you've proposed. 

Nobody apply this patch though, because doing so will just create some merge conflicts as I take the necessary steps to get the http stuff into common where it belongs.

> Refactor AbstractContentCache
> -----------------------------
>
>                 Key: SHINDIG-247
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>            Reporter: Henning Schmiedehausen
>         Attachments: contentcache.patch
>
>
> The attached patch refactors the code from the AbstractContentCache class a bit:
> - add javadocs to AbstractContentCache and ContentCache
> - turn checkContent() into RemoteContent methods:
>       - isExpired() whether this RemoteContent object is expired
>       - isCacheable() whether this RemoteContent object can be cached
>       - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header
> - This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
>    turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code

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


[jira] Updated: (SHINDIG-247) Refactor AbstractContentCache

Posted by "Henning Schmiedehausen (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-247?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Henning Schmiedehausen updated SHINDIG-247:
-------------------------------------------

    Attachment: contentcache.patch

> Refactor AbstractContentCache
> -----------------------------
>
>                 Key: SHINDIG-247
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>            Reporter: Henning Schmiedehausen
>         Attachments: contentcache.patch
>
>
> The attached patch refactors the code from the AbstractContentCache class a bit:
> - add javadocs to AbstractContentCache and ContentCache
> - turn checkContent() into RemoteContent methods:
>       - isExpired() whether this RemoteContent object is expired
>       - isCacheable() whether this RemoteContent object can be cached
>       - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header
> - This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
>    turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code

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


[jira] Commented: (SHINDIG-247) Refactor AbstractContentCache

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12595147#action_12595147 ] 

Kevin Brown commented on SHINDIG-247:
-------------------------------------

I should have the patch by tomorrow. The breakdown is as outlined on shindig-dev a few weeks ago:

- shared stuff goes in org.apache.shindig.common. This includes http retrieval, caching, oauth, security token handling, and most utility classes.
- gadget-specific stuff stays in org.apache.shindig.gadgets

The org.apache.shindig.common package will be a part of the "common" artifact, whereas gadget rendering related stuff will be in "gadgets" and social data (friends, activities, and app data) will be in the social-api artifact.

There is a lot of cruft kicking around. We've been applying patches gradually to improve it, but it seems like for every two steps forward we take another one back on this front as more pressing feature requirements creep back in.

> Refactor AbstractContentCache
> -----------------------------
>
>                 Key: SHINDIG-247
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>            Reporter: Henning Schmiedehausen
>         Attachments: contentcache.patch
>
>
> The attached patch refactors the code from the AbstractContentCache class a bit:
> - add javadocs to AbstractContentCache and ContentCache
> - turn checkContent() into RemoteContent methods:
>       - isExpired() whether this RemoteContent object is expired
>       - isCacheable() whether this RemoteContent object can be cached
>       - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header
> - This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
>    turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code

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


[jira] Commented: (SHINDIG-247) Refactor AbstractContentCache

Posted by "Henning Schmiedehausen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SHINDIG-247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12595142#action_12595142 ] 

Henning Schmiedehausen commented on SHINDIG-247:
------------------------------------------------

do you have a road map of what should go where? There is a lot more stuff that I have been looking at in the org.apache.shindig.gadgets, org.apache.shindig.gadgets.http and org.apache.shindig.util package that is in dire need of refactoring.

> Refactor AbstractContentCache
> -----------------------------
>
>                 Key: SHINDIG-247
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>            Reporter: Henning Schmiedehausen
>         Attachments: contentcache.patch
>
>
> The attached patch refactors the code from the AbstractContentCache class a bit:
> - add javadocs to AbstractContentCache and ContentCache
> - turn checkContent() into RemoteContent methods:
>       - isExpired() whether this RemoteContent object is expired
>       - isCacheable() whether this RemoteContent object can be cached
>       - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header
> - This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
>    turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code

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


[jira] Closed: (SHINDIG-247) Refactor AbstractContentCache

Posted by "Kevin Brown (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SHINDIG-247?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kevin Brown closed SHINDIG-247.
-------------------------------

    Resolution: Fixed

It looks like everything here has been applied in one form or another.

> Refactor AbstractContentCache
> -----------------------------
>
>                 Key: SHINDIG-247
>                 URL: https://issues.apache.org/jira/browse/SHINDIG-247
>             Project: Shindig
>          Issue Type: Improvement
>          Components: Gadget Rendering Server (Java)
>            Reporter: Henning Schmiedehausen
>         Attachments: contentcache.patch
>
>
> The attached patch refactors the code from the AbstractContentCache class a bit:
> - add javadocs to AbstractContentCache and ContentCache
> - turn checkContent() into RemoteContent methods:
>       - isExpired() whether this RemoteContent object is expired
>       - isCacheable() whether this RemoteContent object can be cached
>       - updateExpires() modify the headers of the RemoteContent object to contain a valid expires header
> - This removes lots of functionality that is not really part of the ContentCache from AbstractContentCache and
>    turns canCache(RemoteContentRequest rcr) and canCache(RemoteContent rc) into very readable code

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