Opened 13 years ago

Last modified 8 years ago

#212 review defect

Use beaker as a caching abstraction layer — at Version 10

Reported by: Caleb Davis Owned by: Christopher Webber
Priority: major Milestone:
Component: programming Keywords:
Cc: Parent Tickets:

Description (last modified by Christopher Allan Webber)

There are a few bugs circulating around that block on actually
having an interface to a formal cache. This bug is to build this
cache interface. Then we can use it to do stuff!



Change History (13)

comment:1 by Christopher Allan Webber, 13 years ago

Component: Programming
Owner: set to Christopher Webber
Assigning to me.



comment:2 by Christopher Allan Webber, 13 years ago

[https://gitorious.org/\ :sub:`cwebber/mediagoblin/cwebbers-mediagoblin/commits/i507\_beaker\_cache](https://gitorious.org/`\ cwebber/mediagoblin/cwebbers-mediagoblin/commits/i507\_beaker\_cache)

Added basic functionality. No use and no tests yet, though.



comment:3 by Christopher Allan Webber, 13 years ago

I'm also curious what Elrond thinks about me using [beaker.cache]
as the config section, considering he used [storage:foo] pattern
for storage stuff...



comment:4 by Elrond, 13 years ago

Status: NewIn Progress
1. I already put that on irc a while back: I think, I like
   "``beaker.cache``". dot for fixed things. "``beaker``" and
   "``cache``" are fixed strings, no variations needed. While the
   colon in "``storage:FOO``" splits a fixed "``storage``" from a not
   so fixed string. storage\_from\_config() can be called with "FOO"
   and will happily create a StorageInterface. So the part after the
   colon is dynamic.
2. Instead of ``(u'cache.%s' % key, value)`` I would have used
   ``(u'cache.' + key, value)`` (it's shorter and stops a confusion
   where the right argument to ``%`` ends). Do we even need the ``u``?
   Does parse\_cache\_config\_options expect unicode strings and
   converts them to non unicode keyword-args?
3. If this does not break anything, I'd vote for merging it now
   (despite missing tests)
4. Leave this bug open for writing tests!



comment:5 by Christopher Allan Webber, 13 years ago

Milestone: 0.0.50.1.0

comment:5 by Christopher Allan Webber, 13 years ago

Status: In ProgressClosed
Added a test and merged. We might want a way to disable during
tests though? Not sure. If we do want that, not too hard to add.

Closing this though.



comment:6 by Christopher Allan Webber, 13 years ago

Status: ClosedIn Progress
Re-opening. At least one user (Larissa) has reported errors with
Beaker initializing on OS X. I'd like to figure out why that is. I
think I generally know.



comment:7 by Christopher Allan Webber, 13 years ago

Milestone: 0.1.00.2.0

comment:8 by Christopher Allan Webber, 13 years ago

Milestone: 0.2.00.2.1

comment:7 by Will Kahn-Greene, 13 years ago

The original url for this bug was http://bugs.foocorp.net/issues/507 .
Relations:
#126: related, #110: related, #183: related, #164: blocks

comment:8 by Christopher Allan Webber, 13 years ago

Unless anyone says what's up on OSX, we should just turn this on and start using it.

I guess the main thing to ask is two things:

  • Beaker does caching in a sort of "bucket" system, where you have entire sections of stuff dedicated to being cached.
  • I guess a good question is, "what could really use some caching right now?" Possibly the homepage would be a good first place?

Otherwise, I'm not sure why we would need to delay putting this to use and closing it out.

comment:9 by Elrond, 13 years ago

Milestone: 0.2.10.2.2

We should start to use beaker (or whatever) to cache the markdown conversion.
This is relevant, as we're now converting markdown on the fly.

comment:10 by Christopher Allan Webber, 13 years ago

Description: modified (diff)
Milestone: 0.3.0

We're not going to get this done for 0.3.0 but we need to finish it soon. It's pretty close as-is?

Note: See TracTickets for help on using tickets.