[MediaWiki-CodeReview] [MediaWiki r114081]: New comment added, and revision status changed

2012-03-19 Thread MediaWiki Mail
Krinkle changed the status of MediaWiki.r114081 to fixme and commented it.
URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/114081#c32331

Old Status: new
New Status: fixme

Commit summary for MediaWiki.r114081:

adding special page with scaffolding for caching chunks of HTML

Krinkle's comment:

pre
+   if ( $this-cacheExpiry  10 ) {
..
+   wfGetCache( CACHE_ANYTHING )-set( 
$this-getCacheKey(), $this-cachedChunks, $this-cacheExpiry );
/pre
The codeBagOStuff/code class (of which an instance is returned via 
ObjectCache via wfGetCache) uses 86400 * 3650 (10 years) which doesn't match 
10 (32 years).

This should match the codeBagOStuff::convertExpiry/code 
([https://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/includes/objectcache/BagOStuff.php?revision=02view=markuppathrev=114081#l155
 source code]) of 86400 * 3650,  else weird edge cases will occur.

Marking FIXME for the above.


pre
+'cachedspecial-viewing-cached-ttl' = 'You are viewing a cached version of 
this page, which can be up to $1 old.',
+'cachedspecial-viewing-cached-ts' = 'You are viewing a cached version of this 
page, which might not be completely actual.',
 ...
+   if ( $this-cacheExpiry  10 ) {
+   $message = $this-msg(
+   'cachedspecial-viewing-cached-ttl',
+   $this-getLanguage()-duration( 
$this-cacheExpiry )
+   )-escaped();
+   }
+   else {
+   $message = $this-msg(
+   'cachedspecial-viewing-cached-ts'
+   )-escaped();
+   }
/pre

The UI can do than this. I think the user wants to know in both cases:
* how old it is (store last modified, should be simple)
And maybe: 
* how long until the next refresh (computable in both cases I think)
* or: how often it will be refreshed
So that it says something like cached on date X, refreshed every 30 days and 
not cache can be up to 30 days old. Basically matching the QueryPage type 
special pages.


Right now it is showing how it it could be (in ttl case), and nothing useful at 
all (in the ts case).

___
MediaWiki-CodeReview mailing list
mediawiki-coderev...@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview


[MediaWiki-CodeReview] [MediaWiki r114081]: New comment added, and revision status changed

2012-03-19 Thread MediaWiki Mail
Jeroen De Dauw changed the status of MediaWiki.r114081 to new and commented 
it.
URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/114081#c32340

Old Status: fixme
New Status: new

Commit summary for MediaWiki.r114081:

adding special page with scaffolding for caching chunks of HTML

Jeroen De Dauw's comment:

Ok, changed to the value you suggested in r114147. However do note that I got 
the value that I used by looking through the code as well, which was in 
MWMemcached, line 984.

The main purpose of this message is to notify the user that what they are 
seeing might not be the most recent. Note how this is already more info then 
you get on actual article pages. In case of the ttl, showing the max age is a 
nice addition since it can easily be done. Unless for some good reason you want 
to provide the user with more info, storing the date somewhere and doing a 
query for it is way to much work. If you have some use case for it, then I 
suggest adding it as new feature, which is off unless enabled in the deriving 
class.

___
MediaWiki-CodeReview mailing list
mediawiki-coderev...@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview


[MediaWiki-CodeReview] [MediaWiki r114081]: New comment added, and revision status changed

2012-03-18 Thread MediaWiki Mail
Raymond changed the status of MediaWiki.r114081 to fixme and commented it.
URL: http://www.mediawiki.org/wiki/Special:Code/MediaWiki/114081#c32286

Old Status: new
New Status: fixme

Commit summary for MediaWiki.r114081:

adding special page with scaffolding for caching chunks of HTML

Raymond's comment:

Especially for the content of $1:
{{messagedocumentation}}

___
MediaWiki-CodeReview mailing list
mediawiki-coderev...@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-codereview