(self, image_stream, metadata)
override cache_put to handle and set image streams
        Create a cached image
        For a given original sized image - cache it initially to speed up small size generation
override cache_put to handle and set image streams
        Create a cached image
        For a given original sized image - cache it initially to speed up small size generation
override cache_put to handle and set image streams Create a cached image For a given original sized image - cache it initially to speed up small size generation
def cache_put(self, image_stream, metadata):
        """
        override cache_put to handle and set image streams
        Create a cached image
        For a given original sized image - cache it initially to speed up small size generation
        """
        image_meta = CachedImageMeta.make_meta(image_stream, OBJECT_ORIGINAL, metadata)

        rcache = self.rcache
        image_stream.seek(0)

        rcache.set(self.stream_key(OBJECT_ORIGINAL), image_stream.read())
        rcache.set(self.meta_key(OBJECT_ORIGINAL), simplejson.dumps(image_meta.to_json()))
        self.get.reset_cache(self)
def cache_put ( self , image_stream , metadata ) : image_meta = CachedImageMeta . make_meta ( image_stream , OBJECT_ORIGINAL , metadata ) rcache = self . rcache image_stream . seek ( 0 ) rcache . set ( self . stream_key ( OBJECT_ORIGINAL ) , image_stream . read ( ) ) rcache . set ( self . meta_key ( OBJECT_ORIGINAL ) , simplejson . dumps ( image_meta . to_json ( ) ) ) self . get . reset_cache ( self )