# in a table class definition
__PACKAGE__->load_components(qw/Serialize::Storable/);
# meanwhile, in a nearby piece of code
my $cd = $schema->resultset('CD')->find(12);
# if the cache uses Storable, this will work automatically
$cache->set($cd->ID, $cd);